Page 1 of 1

Need help setting a decimal point in Mainframe.

PostPosted: Wed Jan 15, 2014 7:11 pm
by PuddinPie
Hello

I'm kind of new to this and have been looking everywhere and can't seem to find an answer.

I have a numeric value that is divided by 12. Unfortunately sometimes this creates numbers with more than 2 places after the decimal (ie.23.342321). How do I tell it to stop at the second decimal place or tell it to truncate. I do not want it to round.

Any help is greatly appreciated.

Re: Need help setting a decimal point in Mainframe.

PostPosted: Wed Jan 15, 2014 7:19 pm
by BillyBoyo
Can you show your code please? We don't even know what language/utility you are talking about. Rexx?

Re: Need help setting a decimal point in Mainframe.

PostPosted: Wed Jan 15, 2014 8:15 pm
by PuddinPie
I actualy just figured it out. it was FORMAT x 26.2;

Re: Need help setting a decimal point in Mainframe.

PostPosted: Wed Jan 15, 2014 9:53 pm
by NicC
Still no clue as to what language! And it is probably in the wrong part of the forum.

Re: Need help setting a decimal point in Mainframe.

PostPosted: Wed Jan 15, 2014 10:06 pm
by dick scherrer
Hello,

Usually data with an "x" type does not support decimal places . . .

You may have found a way to get "something" but it may not work for all cases.

If you post a bit of the code, possibly we can offer some clarification. It is most likely NOT tso & ispf . . .

Re: Need help setting a decimal point in Mainframe.

PostPosted: Thu Jan 16, 2014 5:14 am
by Akatsukami
NicC wrote:Still no clue as to what language! And it is probably in the wrong part of the forum.

Sounds like it's probably SAS.