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
 

 

Unload with GDG template for partitioned TS

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
DonanferMaztho

New User


Joined: 06 Dec 2007
Posts: 9
Location: Brazil

PostPosted: Thu Aug 21, 2008 1:43 am    Post subject: Unload with GDG template for partitioned TS
Reply with quote

Hi MF masters!

I'm facing a problem with an unload utility. I have the following statements:

LISTDEF UNLDLIST INCLUDE TABLESPACE DBTEST.TEST PARTLEVEL(1)
INCLUDE TABLESPACE DBTEST.TEST PARTLEVEL(2)

TEMPLATE UNLDDS
DSN '&DB.&TS..UNLOAD.P&PA(4).'
UNIT SYSDA
DISP(NEW,CATLG,DELETE)

UNLOAD LIST UNLDLIST
PUNCHDDN PUNCHDS
UNLDDN UNLDDS
SHRLEVEL REFERENCE


The expected DSN produced by the unload above are:
'DBTEST.TEST.UNLOAD.P01'
'DBTEST.TEST.UNLOAD.P02'

Although, I'm getting the following:
'DBTEST.TEST.UNLOAD.P00'

I have already tried in the template use:

TEMPLATE UNLDDS
DSN '&DB.&TS..UNLOAD.P&PA(4,2).'
UNIT SYSDA
DISP(NEW,CATLG,DELETE)

But got the same DSN previously mentioned
'DBTEST.TEST.UNLOAD.P00'

If I run the unload without the (4) or (4,2) in the DSN name, I have the following result:
'DBTEST.TEST.UNLOAD.P00001'
'DBTEST.TEST.UNLOAD.P00002'

Any idea what should be the problem?

Thanks!!!
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: Thu Aug 21, 2008 2:00 am    Post subject:
Reply with quote

Hello,

Quote:
The expected DSN produced by the unload above are:
'DBTEST.TEST.UNLOAD.P01'
'DBTEST.TEST.UNLOAD.P02'
Where did this expectation originate?

Please show the part of the documentation that shows this. The examples i find all show the P00001 style dataset names.
Back to top
View user's profile Send private message
DonanferMaztho

New User


Joined: 06 Dec 2007
Posts: 9
Location: Brazil

PostPosted: Thu Aug 21, 2008 5:03 am    Post subject: Reply to: Unload with GDG template for partitioned TS
Reply with quote

Pls,
check "Utility Guide and Reference" manual for V8, page 579 where say about " &variable". More specificaly where says:
"To specify a substring, use the form &variable(start). or &variable(start,length)."

Based on this info was expected the result mentioned before.

Thanks for your reply!
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: Thu Aug 21, 2008 7:07 am    Post subject:
Reply with quote

Hello,

I can't find p579 in the v8 utility guide linked via "IBM Manuals" at the top of the page. I did find what i believe is the same info:
http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/handheld/Connected/BOOKS/dsnugj10/2.29.4?

which has:
Quote:
Example 2: Using variable substring notation to specify data set names. The following control statement defines template CP2. Variable substring notation is used in the DSN option to define the data set naming convention.
Assume that in the year 2003 you make a full image copy of partition 00004 of table space DSN8S81D. Assume that you specify the template CP2 for the data set for the local primary copy. DB2 gives the following name to the image copy data set: DH173001.DSN8S81D.Y03.COPYLP.P004

Notice that every variable in the DSN option begins with an ampersand (&) and ends with a period (.). These ampersands and periods are not included in the data set name. Only periods that do not signal the end of a variable are included in the data set name.

TEMPLATE CP2 DSN 'DH173001.&SN..Y&YEAR(3)..COPY&LR.&PB..P&PART(3,3).'
UNIT(SYSDA)

Example 3: Using COPY with TEMPLATE with variable substring notation. The following TEMPLATE utility control statement defines template SYSCOPY. Variable substring notation is used in the DSN option to define the data set naming convention. The subsequent COPY utility control statement specifies that DB2 is to make a local primary copy of the first partition of table space DSN8D81A.DSN8S81E. COPY is to write this image copy to a data set that is dynamically allocated according to the SYSCOPY template. In this case, the resulting data set name is DSN8D81A.DSN8S81E.P001

TEMPLATE SYSCOPY DSN '&DB..&TS..P&PA(3).'
COPY TABLESPACE DSN8D81A.DSN8S81E DSNUM 1 COPYDDN(SYSCOPY)

Notice that you can change the part variable in the DSN operand from P&PA(3). to P&PA(3,3). The resulting data set name is the same, because the length value of 3 is implied in the first specification.


These look more like the dsns you want to create. Notice, they used 3 rather than 4 or 4,2. You might give it a try with 2 and see if you get what you are looking for.
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 -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Best IMS DB Unload Utility jjabez10 IMS DB/DC 12 Thu Sep 22, 2016 11:15 pm
No new posts DB2 Unload format options Susanta DB2 2 Fri Aug 12, 2016 5:42 pm
No new posts DXT unload utility - DVRE0000 mistah kurtz DB2 1 Thu Jul 07, 2016 4:56 pm
No new posts How to suppress retun code of partil ... mkk157 DB2 9 Fri May 27, 2016 6:59 am
No new posts FAST UNLOAD and LOAD issue GaganGarg DB2 1 Mon Feb 15, 2016 2:30 pm


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