IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Want to recreate a old table with new name to make NOT NULL


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sureshbabu.jv

New User


Joined: 11 Apr 2006
Posts: 41
Location: Chennai

PostPosted: Fri Sep 26, 2008 12:19 pm
Reply with quote

Hi,

I have created table like below and inserted the data.. It's allowed the NULL values...

create table forums(newpost varchar(20),oldpost varchar(20),views int,hits int);

I want to recreate a old table with new name, has to give the NOT NULL command for all the columns..

Here my q's is.. Already null values are stored in old table.. If I recrate a new table is the NULL values will over ride or not??

As per the above requirement could you suggest if is there any other way to full fill this..

Thanks,
Suresh
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Fri Sep 26, 2008 12:25 pm
Reply with quote

Hello Suresh,

While creating new table you can define the default value for not Null col.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Load new table with Old unload - DB2 DB2 6
No new posts Pulling a fixed number of records fro... DB2 2
No new posts Multiple table unload using INZUTILB DB2 2
No new posts Check data with Exception Table DB2 0
No new posts trying to make sense of keylists TSO/ISPF 11
Search our Forums:

Back to Top