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
 

 

Efficient method for fetching data from a table

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
vampire

New User


Joined: 12 Oct 2009
Posts: 15
Location: Pune

PostPosted: Wed Oct 14, 2009 7:34 pm    Post subject: Efficient method for fetching data from a table
Reply with quote

Wat is the efficient method of fetching data?
From JCL or From Cobol.

Requirement is of fetching only one value at a time.
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8057
Location: East Dubuque, Illinois, USA

PostPosted: Wed Oct 14, 2009 7:38 pm    Post subject:
Reply with quote

Quote:
Wat is the efficient method of fetching data?
From JCL or From Cobol.
I have no idea what this means -- JCL does absolutely nothing except execute programs, so how you can fetch data from JCL? How would you fetch data from COBOL?

What are you using the fetch the data? Is the data coming from a sequential file, an indexed file, a relative file, or a data base of some sort?

You've left a lot more questions in your post than were answered.
Back to top
View user's profile Send private message
vampire

New User


Joined: 12 Oct 2009
Posts: 15
Location: Pune

PostPosted: Wed Oct 14, 2009 7:53 pm    Post subject: Reply to: Efficient method for fetching data from a table
Reply with quote

sorry,

But I am using the below query

Code:
,//UNLOAD01 EXEC DB2CPROC,
,//             DB2SYS=DATG,
,//             COND=(4,LT)
,//SYSTSIN  DD  *
, RUN PROG(DSNTIAUL) PLAN(DSNTIAUL) -
, PARM('SQL')
, END
,//SYSIN    DD  *
, SELECT MAX(EMP_KEY)
,   FROM TDWPEMP
, WITH UR


So my question is ...

Running this query from a JCL and using the same in a cobol make any change in performance of my JOB??
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: Wed Oct 14, 2009 8:46 pm    Post subject:
Reply with quote

Hello,

Before you do anything else, suggest you gain an understanding of what you are currently running. . .

You are NOT "Running this query from a JCL". . . You are executing a Procedure (DB2CPROC), which in turn executes a program (most likely the Terminal Monitor Program (IKJEFT1B or similar) which is tso in batch).

JCL does not and has never run a query. . . Maybe someday, but not yet.
Back to top
View user's profile Send private message
dejunzhu

Active User


Joined: 08 May 2008
Posts: 390
Location: China

PostPosted: Wed Oct 14, 2009 9:01 pm    Post subject:
Reply with quote

I found so many people do not know the answer to the question:

What is JCL?

icon_biggrin.gif
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


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

PostPosted: Wed Oct 14, 2009 11:18 pm    Post subject:
Reply with quote

dick scherrer wrote:
You are NOT "Running this query from a JCL". . . You are executing a Procedure (DB2CPROC), which in turn executes a program (most likely the Terminal Monitor Program (IKJEFT1B or similar) which is tso in batch).

And which is, let it be noted for the record, running the assembler program DSNTIAUL to process the query.

Incidentially, DSNTIAUL does not produce output that easily read programmatically. If that output is not to be read by a human being and typed into a spreadsheet, DMS panel, etc., any efficiency gained by using DSNTIAUL is likely to be lost in running a program or script to parse it.

On the gripping hand, as "Requirement is of fetching only one value at a time.", anything short of etching the disk platter and examing the crystal patterns with a microscope is likely to provide acceptable throughput.
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: Wed Oct 14, 2009 11:34 pm    Post subject:
Reply with quote

Hello and welcome to the forum,

Quote:
And which is, let it be noted for the record, running the assembler program DSNTIAUL to process the query.
Yup, eventually. . .

Before DSNTIAUL can be invoked, something else is invoked (i.e. the terminal monitor program). . . Which then invokes DSNTIAUL. . .
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Replace values in the input data Vikas Maharnawar DFSORT/ICETOOL 10 Thu May 11, 2017 2:18 pm
No new posts Group Data based on a key Arun Raj DFSORT/ICETOOL 7 Thu Apr 27, 2017 11:29 pm
No new posts unload data from table with lob columns farhad_evan DB2 0 Sat Apr 22, 2017 1:32 pm
No new posts SORT JSON type of data maxsubrat DFSORT/ICETOOL 8 Wed Apr 19, 2017 6:01 pm
No new posts Data replication from multiple Db2 ta... kishpra DB2 9 Mon Mar 27, 2017 9:58 pm


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