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

Run DB2 Query without bind the program


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

New User


Joined: 23 Oct 2012
Posts: 4
Location: Arizona

PostPosted: Tue Oct 30, 2012 5:29 am
Reply with quote

Hi All,

I have requirement where I have to pull the data from multiple table using one key value. We used to get close to 100000 Key vlaues which we are unable to run in spufi to get the data. So we have written a JCL to pull the data from table using the key value. We are unable to give the whole key value at one time(100,000) because job is not accepting everything at one time. So we are have created a many steps using the same query but where clause will have 400 key values. Is there any way to execute the query with all 100000 keys in one query and run the job. We are not suppose to bind the Cobol program in Production for this Adhoc request. We have tried Easytreive as well but I am getting a below error
"A system abend 0C4 reason code X'4' occurred in module EZTCOM program *EZSQLFU at offset X'6458'."

Could anyone please help me on this.

Thank you.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Tue Oct 30, 2012 2:42 pm
Reply with quote

With what you've posted - you're getting S0C4, which means 'protection exception' occurred. In other words, your program attempted to access a storage location that is protected (by storage keys) against the type of reference, and the PSW access key does not match the storage key -- i.e. you're trying to access a storage not defined to your program. So possibly, check why this happens.

Having said all that, have you tried executing your queries using DSNTIAUL?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Tue Oct 30, 2012 2:51 pm
Reply with quote

Quote:
We are not suppose to bind the Cobol program in Production for this Adhoc request.

icon_eek.gif

Write the program, test it in the <available> environment
after that tell the idiot who set the constraint to run it himself icon_cool.gif
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Tue Oct 30, 2012 3:24 pm
Reply with quote

Try Anuj's suggestion.

Do you mean "a Cobol program" rather than "the Cobol program" as in "we are not able to write a new Cobol program for this as we will not be able to implement an ad-hoc Cobol program which can access the production data"? However, it would be silly if you are not "allowed" to do it in Cobol, but you are "allowed" in Easytrieve.

Does your Easytrieve work with small amounts of data, or not at all?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Tue Oct 30, 2012 4:11 pm
Reply with quote

a much quicker execution would be achieved by dumping the table
and using a sort product to JOINKEYS.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Tue Oct 30, 2012 9:41 pm
Reply with quote

Hello,

Or maybe loading the 100,000+ keys into another table and JOIN them?

Peresonally, i'd go for the unload and use the sort to JOINKEYS to do what you need.
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 Using API Gateway from CICS program CICS 0
No new posts RC query -Time column CA Products 3
No new posts DB2 Event passed to the Application P... DB2 1
No new posts How to pass the PARM value to my targ... COBOL Programming 8
No new posts Dynamically pass table name to a sele... DB2 2
Search our Forums:

Back to Top