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
 

 

Performance issue when replacing Stored procedure call

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

New User


Joined: 26 May 2007
Posts: 45
Location: Chennai

PostPosted: Fri Aug 14, 2009 5:22 pm    Post subject: Performance issue when replacing Stored procedure call
Reply with quote

Hi Team ,

In one of my DB2 Cobol program I have replaced a Stored procedure call with the Sql query which is used in the called Stored Procedure. Simply to say Instead of calling Stored procedure to execute a query , I am directly executing that query in the same program itself.

This change is implemented in June 2009 and when we see the CPU consumption times of last 6 months(Jan - Jun) and July month, we observed there is lot of CPU consumption in July.

Can some one please let me know what may be the difference in CPU time replacing a stored procedure call with Sql Query.

Below are CPU consumptions for last 7 months.

Average of last six months CPU time : 140,356
July CPU Time : 12,018,046
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Fri Aug 14, 2009 5:32 pm    Post subject: Reply to: Performance issue when replacing Stored procedure
Reply with quote

it' s hard to believe that a change from stored procedure to inline has caused
a 8500% increase in the CPU consumption

a much better investigation is needed

the best and fastest thing to do would be to run just two test SP and inline for the same data,
it should give a not statistically sound proof but useful enough indicator for the initail performance evaluation review
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri Aug 14, 2009 5:38 pm    Post subject:
Reply with quote

Dare I ask the elapsed time differences

because if your stats are actual CPU seconds .....................................
12 million seconds works out at around 130 day icon_eek.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Fri Aug 14, 2009 5:43 pm    Post subject: Reply to: Performance issue when replacing Stored procedure
Reply with quote

icon_redface.gif
still my advice stands
Back to top
View user's profile Send private message
aryanpa1

New User


Joined: 26 May 2007
Posts: 45
Location: Chennai

PostPosted: Fri Aug 14, 2009 5:46 pm    Post subject:
Reply with quote

Thanks Expat /Enrico ,

This info I got from my junior. Now when I am going throgh the program I can see , there are some Inspect Commands , String Concatenations and a new join query are included in this as part of June changes.

So may be I need to do more analysis where it is going wrong, I guess the replacement Stored proc not alone causing the issue.
Back to top
View user's profile Send private message
ashimer

Active Member


Joined: 13 Feb 2004
Posts: 551
Location: Bangalore

PostPosted: Fri Aug 14, 2009 6:28 pm    Post subject:
Reply with quote

Before the changes the CPU consumption was divided between 2 programs.. your calling program and called program ; now its been consolidated into one package .. Did you check the CPU used by your SP before incorporating the SQL into the calling program ? Or is the numbers mentioned above is for the entire subsystem ?
Back to top
View user's profile Send private message
aryanpa1

New User


Joined: 26 May 2007
Posts: 45
Location: Chennai

PostPosted: Fri Aug 14, 2009 6:32 pm    Post subject:
Reply with quote

The numbers mentioned is for entire subsystem, not for individual programs
Back to top
View user's profile Send private message
ashimer

Active Member


Joined: 13 Feb 2004
Posts: 551
Location: Bangalore

PostPosted: Fri Aug 14, 2009 7:19 pm    Post subject:
Reply with quote

So then how do you conclude that your changes have caused a havoc ?
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 Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am
No new posts Need help in REXX CALL program Raje1002 CLIST & REXX 5 Wed Apr 19, 2017 11:18 pm
No new posts Need help in triggering a PL1 module ... Varungv99 IMS DB/DC 0 Fri Apr 07, 2017 10:01 am
No new posts Replacing same string with different ... vickey_dw DFSORT/ICETOOL 6 Wed Feb 22, 2017 10:44 pm
No new posts Query on DB2 WLM stored procedures ashek15 DB2 8 Sun Feb 12, 2017 11:13 pm


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