Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Adding a column (M) to table A using ALTER command

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Thu May 24, 2007 11:19 am    Post subject: Adding a column (M) to table A using ALTER command
Reply with quote

i have a Table A with 4 cols : X,Y,Z,B

Now i am adding a column (M) to table A using ALTER command.

Criteria for insertion:
Columun M should be inserted between Z and M.

How can this be acheived? icon_eek.gif

TIA,
Pingte
Back to top
View user's profile Send private message

muthuvel

Active User


Joined: 29 Nov 2005
Posts: 217
Location: Chennai

PostPosted: Thu May 24, 2007 11:37 am    Post subject: Re: DB2 question
Reply with quote

Quote:
Columun M should be inserted between Z and M.
icon_confused.gif

I think you want to say as M should be inserted between Z and B.

If that is the case,there is no point or no need of inserting between two columns.
Wherever you insert the column,it is going to be one row for a key record.Moreover you are going to use the column by it's dclgen .
Back to top
View user's profile Send private message
pingte

Active User


Joined: 03 Dec 2005
Posts: 120
Location: india

PostPosted: Thu May 24, 2007 11:41 am    Post subject:
Reply with quote

Quote:

Columun M should be inserted between Z and B.



I just want to know whether it is feasible or not?
Back to top
View user's profile Send private message
muthuvel

Active User


Joined: 29 Nov 2005
Posts: 217
Location: Chennai

PostPosted: Thu May 24, 2007 12:32 pm    Post subject: Re: Adding a column (M) to table A using ALTER command
Reply with quote

The answer is NO.
Back to top
View user's profile Send private message
deepak.vl

New User


Joined: 17 Feb 2007
Posts: 38
Location: Hyderabad

PostPosted: Sun May 27, 2007 7:16 pm    Post subject:
Reply with quote

Hi,
In this case you may have to take the back up of the table data into another table/tape drive, drop the table, create the table with the new column between Z & B, load the new table with the backed up data.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts TSO or command line utility to genera... kishpra JCL & VSAM 3 Thu Mar 09, 2017 1:11 am
No new posts Customizing the ISPF HILITE Command Pedro TSO/ISPF 3 Fri Mar 03, 2017 11:49 pm
No new posts how to send just 10 rows in a CICS sc... Megha Gupta CICS 5 Thu Feb 23, 2017 6:57 pm
No new posts Join of more than one table dibyendumandal11111 DB2 6 Mon Feb 13, 2017 11:36 pm
No new posts Fail to change physical VSAM filename... jacobdng CICS 7 Fri Jan 20, 2017 12:36 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us