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
 

 

To read sql Query through Control card

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
Pavan101

New User


Joined: 09 Mar 2009
Posts: 13
Location: Bombay

PostPosted: Wed Jan 06, 2010 7:23 pm    Post subject: To read sql Query through Control card
Reply with quote

Hi,

I need to use SQL Query through the control card to execute the job, Plz help me on same, How can i use it.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10274
Location: italy

PostPosted: Wed Jan 06, 2010 7:26 pm    Post subject: Reply to: To read sql Query through Control card
Reply with quote

Quote:
I need to use SQL Query through the control card to execute the job, Plz help me on same, How can i use it.


Ok for the language barrier, but really it is impossible to parse the above sentence in any understandable fashion!

think carefully what You requirements are and post/reword them in a more understandable way

please help those willing to help You
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Wed Jan 06, 2010 9:00 pm    Post subject:
Reply with quote

Control-card is a very generic term - different individuals will anticipate it differently. I need to agree with enrico, however, being from a non-english back-ground I hear that jiberish every day so will try to answer...

If you are using DSNTIAUL with IKJEFT01 and because PROCs can not have in-stream data and some oen asked you to write the query in some member of PDS (control-card) then you can write your-query statements in a member of PDS (LRECL=80) and refer that to in sysin for a JCL of this nature.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Wed Jan 06, 2010 9:00 pm    Post subject:
Reply with quote

And if that is not what you are looking for - GO TO post from enrico.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Wed Jan 06, 2010 10:05 pm    Post subject:
Reply with quote

It is very possible to read a select statement from a file or sysin (no difference which you use), prepare it as a dynamic sql statement and execute it. I have a program that does just that to produce comma and tab delimited files for our use. It takes a very deep understanding of COBOL and data formats to do it. I wrote the program several years ago and we use it a hundred times a day in production and test. No i will not share it, my employer pays me for my knowledge and skills.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Need DB2 query to fetch previous row ! Chandan1993 DB2 10 Sat Jun 03, 2017 10:43 am
No new posts READ A PACKED "NEGATIVE" FI... jdesouza CA Products 3 Tue May 02, 2017 11:43 pm
No new posts PA02 - Programmtically control attent... dodithegreat IMS DB/DC 1 Thu Apr 06, 2017 8:33 pm
No new posts Read of TDQ fails in LENGERR Tracy Hansen CICS 10 Wed Apr 05, 2017 12:10 am
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm


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