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
 

 

Updated rows information

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

New User


Joined: 12 Jan 2010
Posts: 66
Location: US

PostPosted: Mon Aug 02, 2010 5:05 pm    Post subject: Updated rows information
Reply with quote

How to retrieve the updated rows from employee table? We can refer the variable SQLERRD(?) to know how many records got updated but how to check which records got updated recently.. (If the table does not have date and timestamp columns).... Is there any way to get the recent updated rows...........
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Aug 02, 2010 5:20 pm    Post subject:
Reply with quote

what version of db2?
Back to top
View user's profile Send private message
nareshdacha

New User


Joined: 12 Jan 2010
Posts: 66
Location: US

PostPosted: Mon Aug 02, 2010 5:26 pm    Post subject: Reply to: Updated rows information
Reply with quote

DB2 Version 9.1 .......
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Aug 02, 2010 6:04 pm    Post subject:
Reply with quote

Quote:
Is there any way to get the recent updated rows


what do you mean by that? very poorly worded. do you mean in the recent week?, by the last update statement? sqlerrcd(3) by the way provides the count.

Selecting values while updating data maybe what you are looking for.

Determining when a row was changed discusses generic time row changed,
but you need to read the documentation, as you must alter the table and add a column ROW CHANGE TIMESTAMP.

other than that, I am going to stop guessing what you mean/want.
Back to top
View user's profile Send private message
nareshdacha

New User


Joined: 12 Jan 2010
Posts: 66
Location: US

PostPosted: Mon Aug 02, 2010 6:17 pm    Post subject: Reply to: Updated rows information
Reply with quote

Sorry for the ambiguity in the statement.....
Thanks for the suggestion....
I got the solution by using ROW CHANGE TIMESTAMP....
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 To display values of multiple rows in... vinu78 DB2 2 Thu Mar 09, 2017 1:20 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
This topic is locked: you cannot edit posts or make replies. DB2 query Using Recursion, Converting... smilewithashu2 DB2 3 Tue Jan 03, 2017 12:50 pm
This topic is locked: you cannot edit posts or make replies. Db2 SQL query to convert rows into co... subratarec DB2 5 Thu Nov 17, 2016 4:51 pm
No new posts Row-Numbers of distinct rows? Auryn DB2 1 Thu Oct 20, 2016 4:38 pm


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