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

Count the number of rows updated or deleted or inserted.


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Tue Jul 14, 2015 7:57 pm
Reply with quote

Hi All,

Is there a provision in DB2 tables that one of the column acts as a automatic counter. So that it counts the number of rows inserted, updated or deleted in a particular table. I don't want to check SQLCA copybook field.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Tue Jul 14, 2015 8:26 pm
Reply with quote

This may be you are interested in..

ibmmainframes.com/about55499.html
Back to top
View user's profile Send private message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Wed Jul 15, 2015 3:29 pm
Reply with quote

Thanks for the link. But I didn't find it useful nor get any clarity on the stuff I'm looking.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Wed Jul 15, 2015 5:06 pm
Reply with quote

Chetan Kumar wrote:
I don't want to check SQLCA copybook field.


Chetan,
I stopped posting negtive responses several years ago,
but the above comment really put my resolve to the test.

please, tell me why you do not want to use a field that is allready
definined
and
populated
upon return from db2?
And why you would want to incur another CALL to DB2 to determine something that is already at hand.
Back to top
View user's profile Send private message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Wed Jul 15, 2015 7:55 pm
Reply with quote

Hi Dick,

The counter is already associated with the DB2 Table. There is no need for any coding or additions to DB2 table. Basically I wanted to know how to figure out or how to locate the auto counter that is already associated with the table.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Wed Jul 15, 2015 8:34 pm
Reply with quote

Quote:
Thanks for the link. But I didn't find it useful nor get any clarity on the stuff I'm looking.


What is that now you looking for? Why do you not want to look for IC?

Quote:
I don't want to check SQLCA copybook field


Why? What is it that restricts you to use?

Quote:
The counter is already associated with the DB2 Table. There is no need for any coding or additions to DB2 table. Basically I wanted to know how to figure out or how to locate the auto counter that is already associated with the table.


What counter? what is auto counter?

Have you talked to DBA yet ?
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Thu Jul 16, 2015 4:43 pm
Reply with quote

Chetan Kumar wrote:
The counter is already associated with the DB2 Table.

Except that there isn't one, and if you thought about the matter for two seconds you'd realize why there isn't. You're just going to have to do some actual work.
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 Pulling a fixed number of records fro... DB2 2
No new posts Substring number between 2 characters... DFSORT/ICETOOL 2
No new posts To find whether record count are true... DFSORT/ICETOOL 6
No new posts Generate random number from range of ... COBOL Programming 3
Search our Forums:

Back to Top