Need help setting a decimal point in Mainframe.



TSO Programming, ISPF, SDF, SDSF and PDF, FTP, TCP/IP Concepts, SNA & SNA/IP etc...

Need help setting a decimal point in Mainframe.

Postby PuddinPie » Wed Jan 15, 2014 7:11 pm

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.
PuddinPie
 
Posts: 20
Joined: Wed Sep 15, 2010 1:51 am
Has thanked: 0 time
Been thanked: 0 time

Re: Need help setting a decimal point in Mainframe.

Postby BillyBoyo » Wed Jan 15, 2014 7:19 pm

Can you show your code please? We don't even know what language/utility you are talking about. Rexx?
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Need help setting a decimal point in Mainframe.

Postby PuddinPie » Wed Jan 15, 2014 8:15 pm

I actualy just figured it out. it was FORMAT x 26.2;
PuddinPie
 
Posts: 20
Joined: Wed Sep 15, 2010 1:51 am
Has thanked: 0 time
Been thanked: 0 time

Re: Need help setting a decimal point in Mainframe.

Postby NicC » Wed Jan 15, 2014 9:53 pm

Still no clue as to what language! And it is probably in the wrong part of the forum.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: Need help setting a decimal point in Mainframe.

Postby dick scherrer » Wed Jan 15, 2014 10:06 pm

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 . . .
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Need help setting a decimal point in Mainframe.

Postby Akatsukami » Thu Jan 16, 2014 5:14 am

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.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times


Return to TSO & ISPF

 


  • Related topics
    Replies
    Views
    Last post