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

program for report generation


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rkr

New User


Joined: 19 Apr 2005
Posts: 12

PostPosted: Sat Sep 17, 2005 10:46 am
Reply with quote

hi all

i want a cobol program and the run jcl for report generation in which the data is retrieved from a table in database .
and i want the output in spool not in to be assigned to the printer.

if anybody has knows it, plz send it asap.
thanks in advance ..

regards
rkr
Back to top
View user's profile Send private message
Rama Nelluri

New User


Joined: 16 Sep 2005
Posts: 6

PostPosted: Mon Sep 19, 2005 4:29 pm
Reply with quote

Hi,
Unload the Table data to Flat file. Read this flat file until End of file ,write the record to sysout.

In File control,
Select Infile assign to XXXXX.
Select Outfile assign to SYSOUT.


and Other logic is: (We can do below logic also But this is not good way...)
Declare Cursor with select * from Table.
Put the Fetch Cursor loop Until end-of-table(or SQL code=100)
Move the Table values to output file variables, write the output file.

Regards,
Rama.N
Back to top
View user's profile Send private message
rkr

New User


Joined: 19 Apr 2005
Posts: 12

PostPosted: Tue Sep 20, 2005 7:30 pm
Reply with quote

hi rama,
thanks for ur reply.but can we generate report using qmf ?
there is also all the facilities for report generation.
thanks in advance.

regards
rkr
Back to top
View user's profile Send private message
Rama Nelluri

New User


Joined: 16 Sep 2005
Posts: 6

PostPosted: Tue Sep 20, 2005 7:51 pm
Reply with quote

Hi,

I have't worked in QMF.In my workshop we do not support QMF.

Regards,
Rama.
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 -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Using API Gateway from CICS program CICS 0
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 REXX code to expand copybook in a cob... CLIST & REXX 2
No new posts EZT program to build a flat file with... All Other Mainframe Topics 9
Search our Forums:

Back to Top