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
 

 

Update multiple rows in a table at a time

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
program developer

New User


Joined: 15 Nov 2005
Posts: 3

PostPosted: Tue Nov 15, 2005 1:09 pm    Post subject: Update multiple rows in a table at a time
Reply with quote

Hi,
I have the Table structure as :
emp table
eid ename
100 abc
200 def
101 cba

is it possible to update the "ename" column in single update query?
like say for Eid =100 "abc" i want to update as "cba" and
for Eid= 101 "cba" as "abc" in a single update.
How can i do that?


Thank you in advance.
Back to top
View user's profile Send private message

mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 238
Location: USA

PostPosted: Wed Nov 16, 2005 6:41 pm    Post subject:
Reply with quote

program developer,

what is the key of the table??
Back to top
View user's profile Send private message
program developer

New User


Joined: 15 Nov 2005
Posts: 3

PostPosted: Fri Nov 18, 2005 6:34 pm    Post subject: what is the key of the table??
Reply with quote

Eid is the key.
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 -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Fileaid Update Replace with null string descann Compuware & Other Tools 4 Mon May 15, 2017 3:00 pm
No new posts DSNACCOX (can it be run on 1 db/ts, t... SRICOBSAS DB2 3 Sat May 06, 2017 12:59 am
No new posts Unable to create multiple files using... mbattu COBOL Programming 3 Fri May 05, 2017 5:35 pm
This topic is locked: you cannot edit posts or make replies. Merge two files and update Trailer re... Yashashri JCL & VSAM 1 Thu May 04, 2017 12:54 pm
No new posts unload data from table with lob columns farhad_evan DB2 0 Sat Apr 22, 2017 1:32 pm


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