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

How do you generate daily,weekly,monthly reports using GDG


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
kndeepthi

New User


Joined: 20 Jan 2006
Posts: 4

PostPosted: Wed Jan 25, 2006 3:50 pm
Reply with quote

hello,

i wanted to know how do you generate daily,weekly,monthly reports using gdg in real environment?

want to know how to create current generations?

want coding for daily,weekly,monthly reports?
Back to top
View user's profile Send private message
Rupesh.Kothari

Member of the Month


Joined: 27 Apr 2005
Posts: 463

PostPosted: Wed Jan 25, 2006 4:20 pm
Reply with quote

HI kndeepthi,


Quote:
want to know how to create current generations?


Create one GDG base and code (+1) which will create current generation of GDG


Quote:
i wanted to know how do u generate daily,weekly,monthly reports using gdg in real environment?

Schedule 3 jobs of which
1 runs daily which creat daily generation and report
2nd job runs weekly which copy all the data from daily GDG(6 GDGs) and creat one GDG. This contains data for weekly. and delete all the daily generation
3rd job runs on monthly, which copy weekly data into Monthly file and delete all weekly generation.

Hope this clear now....

Regards
Rupesh
Back to top
View user's profile Send private message
kndeepthi

New User


Joined: 20 Jan 2006
Posts: 4

PostPosted: Thu Jan 26, 2006 8:16 pm
Reply with quote

1 runs daily which creat daily generation and report
2nd job runs weekly which copy all the data from daily GDG(6 GDGs) and creat one GDG. This contains data for weekly. and delete all the daily generation
3rd job runs on monthly, which copy weekly data into Monthly file and delete all weekly generation.


how to do this?
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sat Jan 28, 2006 11:18 pm
Reply with quote

Create a GDG w/6 entries for daily.
Create a GDG w/4 entries for wkly.
Create a GDG w/12 entries for moly.

When the wkly runs include a step (IEFBR14) to delete all the daily gens, e.g. dsn=p.dly.data,disp=(old,delete). Do similar w/wkly gens.

The problem w/wkly, moly is that the # of wks in a mo vary. If you can convince TPTB to go to 4 wks instead of moly, you've got something workable.
Back to top
View user's profile Send private message
sarojini

New User


Joined: 08 Dec 2005
Posts: 10
Location: India

PostPosted: Sun Jan 29, 2006 9:57 am
Reply with quote

how to copy 6 daily gdgs into a single gdg
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Sun Jan 29, 2006 11:10 pm
Reply with quote

If you have GDG entries like A.B.C.G000nV00, use DSN=A.B.C to read ALL the generations of A.B.C
Back to top
View user's profile Send private message
DavidatK

Active Member


Joined: 22 Nov 2005
Posts: 700
Location: Troy, Michigan USA

PostPosted: Mon Jan 30, 2006 8:44 am
Reply with quote

Hi kndeepthi,

Here a solution that may work for you.

1 - Create 3 GDGs with a depth of 2. One for Daily, Weekly, and Monthly reports.

2 - Create an empty GDG for each.

3 - Daily job runs creating (+1) Daily GDG.

4 ? On the daily reporting run.
a. Use the most currently daily GDG (0) for the daily reports.
b. Copy the Daily GDG (0), appending it to the weekly GDG (0) creating weekly GDG (+1).
c. Copy the Daily GDG (0), appending it to the monthly GDG (0) creating weekly GDG (+1).

5 ? On the Weekly reporting run.
a. Use the most current weekly GDG (0) for the weekly reports. This assumes that the daily reports, and copies, have completed before the weekly reports start.
b. Delete all weekly GDGs
c. Create empty weekly GDG

6 ? On the Monthly reporting Run.
a. Use the most current Monthly GDG (0) for the monthly reports. This assumes that the daily reports, and copies, have completed before the monthly reports start.
b. Delete all monthly GDGs
c. Create empty monthly GDG

You can use several IBM utilities to copy the gens.

Happy reporting, icon_smile.gif

Dave
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 -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Generate random number from range of ... COBOL Programming 3
No new posts Generate output lines (SYSIN card for... DFSORT/ICETOOL 4
No new posts JPM Reports for each DB2 V12 Function... DB2 0
No new posts JSON Generate COBOL Programming 2
No new posts XML-GENERATE to render edited numeric COBOL Programming 0
Search our Forums:

Back to Top