View previous topic :: View next topic
|
Author |
Message |
ksk
Active User
Joined: 08 Jun 2006 Posts: 355 Location: New York
|
|
|
|
Hi,
We have a sorted report in which we have to perfom two functions,
1) pick up the maximum timestamp
2) Get the total number of records
For this we used the OUTFIL and MAX in the following format
Code: |
SORT FIELDS=(1,10,CH,A)
OUTFIL REMOVECC,NODETAIL,
SECTIONS=(1,10,
TRAILER3=(1,10,
MAX=(1,10,CH,TO=CH,LENGTH=10)))
|
it is giving syntax error, anybody has previously used it or have idea about usong it.
Can any body suggest on this?
Thanks,
ksk |
|
Back to top |
|
|
sanjayis01 Warnings : 1 New User
Joined: 13 Jun 2007 Posts: 55 Location: banaglore
|
|
|
|
Hi
This will give you the count.
Code: |
OPTION COPY
OUTFIL REMOVECC,NODETAIL,
TRAILER1=(COUNT=(M11,LENGTH=12))
|
i m working on other , if got i will post it. |
|
Back to top |
|
|
krisprems
Active Member
Joined: 27 Nov 2006 Posts: 649 Location: India
|
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
ksk,
When I run your job with DFSORT, I get:
Code: |
MAX=(1,10,CH,TO=CH,LENGTH=10)))
$
ICE223A 0 REPORT FIELD ERROR
|
You can't use CH format in MAX. You need to use a numeric format like ZD. This works:
Code: |
MAX=(1,10,ZD,TO=ZD,LENGTH=10)))
|
|
|
Back to top |
|
|
|
|