Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Display some messages in SYSOUT and SYSPRINT

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

New User


Joined: 27 Jul 2005
Posts: 35
Location: Chennai

PostPosted: Tue Nov 29, 2005 5:24 pm    Post subject: Display some messages in SYSOUT and SYSPRINT
Reply with quote

Hi,
I want some messages to be displayed in SYSPRINT & Some in SYSOUT...Is that possible... if yes ...then how ?

This was asked in an interview. icon_rolleyes.gif
Back to top
View user's profile Send private message

jon_s_rice

Active User


Joined: 24 Mar 2005
Posts: 102
Location: Douglasville, GA USA

PostPosted: Tue Nov 29, 2005 5:49 pm    Post subject:
Reply with quote

Assuming you are using COBOL. A message will go to SYSOUT as a result of a DISPLAY statement. This can be changed in a compile option. To display to SYSPRINT it would have to be defined as a file.
Back to top
View user's profile Send private message
karthik1680
Warnings : 2

New User


Joined: 14 May 2005
Posts: 64
Location: chennai

PostPosted: Wed Nov 30, 2005 7:26 am    Post subject: Re: Display some messages in SYSOUT and SYSPRINT
Reply with quote

hi jon_s_rice,
could explain detaily plz?
Back to top
View user's profile Send private message
jon_s_rice

Active User


Joined: 24 Mar 2005
Posts: 102
Location: Douglasville, GA USA

PostPosted: Wed Nov 30, 2005 8:41 am    Post subject:
Reply with quote

In your COBOL program.
Code:


     SELECT PRINTER-FILE
         ASSIGN TO S-SYSPRINT.

....
 FD  PRINTER-FILE
     RECORD CONTAINS 133 CHARACTERS.

 01  PRINTER-FILE-RECORD         PIC X(133)     JUSTIFIED RIGHT.

in the procedure division
for SYSPRINT
     WRITE PRINTER-FILE-RECORD AFTER ADVANCING 1 LINE.

for SYSOUT
             DISPLAY 'GREATER THAN KEY    ',
Back to top
View user's profile Send private message
Abi

New User


Joined: 27 Jul 2005
Posts: 35
Location: Chennai

PostPosted: Thu Dec 01, 2005 12:17 pm    Post subject:
Reply with quote

Hi jon_s_rice,
Thanks for the info
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 How to display offset thru cobol prog... tvinodkumar7 CICS 2 Sun Apr 22, 2018 8:42 pm
No new posts Default attributes for undeclared SYS... Alan Playford PL/I & Assembler 3 Wed Apr 11, 2018 5:18 pm
No new posts how to display APL characters? Pedro TSO/ISPF 7 Wed Mar 14, 2018 5:07 am
No new posts Web Service VS MQ Messages Ashishpanpaliya All Other Mainframe Topics 1 Wed Feb 28, 2018 10:48 pm
No new posts display the sign only if the value is... useit DFSORT/ICETOOL 3 Wed Oct 04, 2017 5:53 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us