Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
How to use savepoints

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

Active User


Joined: 31 Jan 2008
Posts: 148
Location: Chennai, India

PostPosted: Fri Oct 10, 2008 2:14 pm    Post subject: How to use savepoints
Reply with quote

I have to read one table having more than 10000 rows and insert into 4 diffrent tables.
Here, for each and every insert I am commiting the database but it is not optimized.
How to use savepoint to get rid of this or else is there any other way?
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Fri Oct 10, 2008 8:42 pm    Post subject:
Reply with quote

Hello,

Quote:
for each and every insert I am commiting the database but it is not optimized.
Typically, SELECTs are optimized when possible. INSERTs are always expensive.

Quote:
How to use savepoint to get rid of this or else is there any other way
What exactly do you want to "get rid of"? What does the term "savepoint" mean to you? It is not a database term. . .

On alternative would be to create 4 qsam files and load them externally rather than within the code. For most situations, 10thousand is not very many rows - how often does this process run?
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:


Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us