If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Record Deleted/inserted.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-20-05, 10:26
dba_udb dba_udb is offline
Registered User
 
Join Date: Mar 2005
Posts: 73
Record Deleted/inserted.

Plese help me in determining This.

I have a job running. It is inseting few records into the database.
Is there any way that i can determine the no.of records it is
inserting per hour? This is actually a batch job from Applicatio side..


I am trying to schedule another job which deletes thousands of records using delete statements. At the end of job how do i find out how many rows got deleted?
Reply With Quote
  #2 (permalink)  
Old 10-20-05, 12:05
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Code:
$ db2 get snapshot for application agentid 17 | grep ^Rows
Rows deleted                               = 0
Rows inserted                              = 0
Rows updated                               = 0
Rows selected                              = 12
Rows read                                  = 18
Rows written                               = 0
Rows read                                  = 0
Rows written                               = 0
Rows deleted                               = 0
Rows updated                               = 0
Rows inserted                              = 0
Rows fetched                               = 0
Reply With Quote
  #3 (permalink)  
Old 10-21-05, 02:57
juliane26 juliane26 is offline
Registered User
 
Join Date: Oct 2005
Posts: 109
one option for your second question is the SQLCA.

after running your statements (I dunno what you are using, scripts, code or whatever), the SQLCA contains the value of how many rows have been affected in sqlerrd(5).

See also http://publib.boulder.ibm.com/infoce...n/r0002212.htm

In progamming C or Java you can get that using methods, on command line use db2 -a.
__________________
Juliane
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On