View previous topic :: View next topic
|
Author |
Message |
Anshuman_Hyd
New User
Joined: 13 Jan 2010 Posts: 15 Location: Hyd
|
|
|
|
If i have a file and using DFSORT i found out that the file is empty.And i want to pass "No Records found" in the empty file.Can we use ICETOOL or ICEMAN utility to achieve it. |
|
Back to top |
|
|
Escapa
Senior Member
Joined: 16 Feb 2007 Posts: 1399 Location: IL, USA
|
|
|
|
Quote: |
If i have a file and using DFSORT i found out that the file is empty |
Post your existing job with current sortcard being used. |
|
Back to top |
|
|
Anshuman_Hyd
New User
Joined: 13 Jan 2010 Posts: 15 Location: Hyd
|
|
|
|
SORT FIELD=COPY -
INREC IFTHEN=(WHEN=(1,1,CH,NE,C' '),
OVERLAY=(C'NO RCORDS IN HEADER :'26,1))
The sort card i hv used. |
|
Back to top |
|
|
Escapa
Senior Member
Joined: 16 Feb 2007 Posts: 1399 Location: IL, USA
|
|
Back to top |
|
|
Anshuman_Hyd
New User
Joined: 13 Jan 2010 Posts: 15 Location: Hyd
|
|
|
|
Hi can i get the structure of the JCL for step2 for which u have given the link.Coz till step 2 i hv already done it.But i m not getting how will i insert the line"Empty file" in th empty file.
Is there any other way of writting into the empty file other than Repro or Merging.
Please guide me !!!!1 |
|
Back to top |
|
|
Escapa
Senior Member
Joined: 16 Feb 2007 Posts: 1399 Location: IL, USA
|
|
|
|
Use this for step2.
Code: |
//STEP02 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD *
No Records found
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY
/*
|
Even you can use IEBGENER for the same. |
|
Back to top |
|
|
Anshuman_Hyd
New User
Joined: 13 Jan 2010 Posts: 15 Location: Hyd
|
|
|
|
Thnx a lot for the gr8 help |
|
Back to top |
|
|
Subhu_Chatterbox
New User
Joined: 25 Feb 2010 Posts: 12 Location: Hyd
|
|
|
|
yes do the first step with ICETOOL, then follow the step2 as mentioned above, if RC=12 |
|
Back to top |
|
|
Anshuman_Hyd
New User
Joined: 13 Jan 2010 Posts: 15 Location: Hyd
|
|
|
|
For getting recturn code 4 we can use the below sort card tooo
COUNT FROM(IN) EMPTY USING(HDTL) RC4
/*
//HDTLCNTL DD *
OMIT COND=(5,1,CH,EQ,C' ') |
|
Back to top |
|
|
|