surya4ug
New User
Joined: 08 Jul 2008 Posts: 62 Location: chennai
|
|
|
|
Hello,
i have a file that looks like below. the constant 123456779 starts at 61st position.
Code: |
XXXXXXXXXXXXXXXXXXXXXXX 123456779 |
I'm using the following piece of code to fetch the constant from the file. the code is as shown below.
Code: |
INCLUDE COND=(1,23,CH,EQ,C'XXXXXXXXXXXXXXXXXXXXXXX)
INREC BUILD=(C'CONST2,+',61,10,UFF,ZD,LENGTH=10,80:X)
SORT FIELDS=COPY |
after this, i have another sort step to divide a column in another file with the constant i fetched above.
Code: |
INREC IFTHEN=(WHEN=INIT,
BUILD=(1,70,72:(61,10,ZD),MUL,+100,DIV,CONST2,M11,LENGTH=5,C'%'))
OPTION COPY
OUTFIL FNAMES=SORTOUT,REMOVECC,
HEADER1=(001:'**********ABCDEFGHIJKLMN',45:&DATE) |
my requirement here is to display the value that comes out of the division to the max possible extent of decimals.
so, if the value is 0.000008%, i want to display it the same way. just because i'm using M11 in the code above, i'm getting the value as 0%, which is not what i want.
i know that we can use TO=PD,CH etc to display the field the way we want, but i'm clueless about the floating point value ( i guess TO=FL doesn't work with syncsort ).
please help me out. |
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Why do you believe this is "floating point"? Suggest you do a bit of research on what floating point is.
Neither Syncsort, nor any other sort product that i'm aware of, is meant to be a scientific calculator. |
|