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
 

 

can we pass /* or //* thru SYSIN DD *

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
sraghav

New User


Joined: 16 Sep 2009
Posts: 3
Location: hyderabad

PostPosted: Tue Dec 08, 2009 6:02 pm    Post subject: can we pass /* or //* thru SYSIN DD *
Reply with quote

Hi,

Can we pass //* or /* or // as data through SYSIN DD *.

I was asked the above question in an interview. I had answered that we cannot pass them as specifying them would mark the end of the instream data (or the job in case of //).
But then it occurred to me that /* or //* or // might not be considered as a delimiter unless specified in the first column in the JCL. So we can specify them in a column other than the first while passing them thru SYSIN.
So anyone please shed some light on the above as I do not have mainframe connection to try it out.
Thanking you in advance
Sandhya
Back to top
View user's profile Send private message

VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Tue Dec 08, 2009 6:11 pm    Post subject:
Reply with quote

Hi,

I don't really know with what intention the interviewer had asked this question and also, could you please let us know some more details like whether the calling step is a IDCAMS or IEBGENER.......
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7995
Location: Bellevue, IA

PostPosted: Tue Dec 08, 2009 6:20 pm    Post subject:
Reply with quote

Click on the manuals link at the top of the page, pull up the JCL Language Reference manual, and research the DLM parameter. It can be applied to any instream data set without regard to being part of program IDCAMS, IEBGENER, or whatever.
Back to top
View user's profile Send private message
sraghav

New User


Joined: 16 Sep 2009
Posts: 3
Location: hyderabad

PostPosted: Thu Dec 10, 2009 3:36 pm    Post subject: Reply to: can we pass /* or //* thru SYSIN DD *
Reply with quote

The interviewer specified about passing the // or /* or //* to a cobol program.

Found the below info from the manual:

In a JES2 system, when the DLM delimiter appears on a DD * statement, either the assigned delimiter or // ends the input data set. When the DLM delimiter appears on a DD DATA statement, only the assigned delimiter ends the input data set.

In a JES3 system, when the DLM delimiter appears on either a DD * or DD DATA statement, only the assigned delimiter ends the input data set.
Example:
//DD1 DD *,DLM=AA
.
.
data
.
AA

Thank u Robert..

Regards
Sandhya
Back to top
View user's profile Send private message
sraghav

New User


Joined: 16 Sep 2009
Posts: 3
Location: hyderabad

PostPosted: Thu Dec 10, 2009 3:40 pm    Post subject: Reply to: can we pass /* or //* thru SYSIN DD *
Reply with quote

Forgot to add the below info from the manual:

Purpose

Use the DLM parameter to specify a delimiter to terminate this in-stream data set. When the DLM parameter assigns a different delimiter, the in-stream data records can include standard delimiters, such as /* and //, in the data.

Regards
Sandhya
Back to top
View user's profile Send private message
Shriram Jogdand

New User


Joined: 14 Oct 2008
Posts: 65
Location: Pune

PostPosted: Thu Dec 10, 2009 4:32 pm    Post subject: Reply to: can we pass /* or //* thru SYSIN DD *
Reply with quote

We can Pass the data through SYSIN DD * parameter to the cobol program. In cobol program you have to define the structure of variable in Linkage section as follows

LINKAGE SECTION.
01 WS-SYSIN-VAR
05 WS-VAR-LN PIC S9(4) COMP.
05 WS-VARIABLE PIC X(10).

The first variable is length variable and scond is the variable that will be used to store the value passed from SYSIN DD *

You have to accept this value in procedure division with the verb ACCEPT as

ACCEPT WS-VARIABLE
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: Thu Dec 10, 2009 4:46 pm    Post subject:
Reply with quote

Shriram Jogdand

Not being a programmer so may well be wrong, but aren't you describing accepting input from PARM here, rather than from SYSIN.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7995
Location: Bellevue, IA

PostPosted: Thu Dec 10, 2009 6:11 pm    Post subject:
Reply with quote

Shriram: your post is completely irrelevant to the requested information -- PARM= is a parameter on the EXEC statement, not part of a SYSIN DD statement.
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 -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts JES2 JEC: Use UNIX Pipes to Pass Data... Virendra Shambharkar JCL & VSAM 21 Tue Dec 20, 2016 6:55 pm
This topic is locked: you cannot edit posts or make replies. How to pass the previous month date i... Suganya87 DFSORT/ICETOOL 5 Mon Oct 31, 2016 4:13 pm
No new posts Need to know what sysin for DFHTU690 ... pkmurali CICS 3 Mon Jul 25, 2016 1:36 pm
No new posts Symbolic Parameters in SYSIN DD state... madishpa DFSORT/ICETOOL 3 Mon Jun 27, 2016 6:23 pm
No new posts Is it possible to pass variables of s... Csongor CLIST & REXX 2 Fri Jun 10, 2016 7:33 pm


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