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

Updated rows information


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
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
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
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
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
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
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 View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts To get the count of rows for every 1 ... DB2 3
No new posts Capturing Job Execution Information All Other Mainframe Topics 3
No new posts Exclude rows with > than x occurre... DFSORT/ICETOOL 6
No new posts Convert single row multi cols to sing... DFSORT/ICETOOL 6
No new posts Compare latest 2 rows of a table usin... DB2 1
Search our Forums:

Back to Top