BookmarkSubscribeRSS Feed
ThomasH
Calcite | Level 5
Hi all,

why would this piece of code

---
data _null_;

format a b 31.15;

a = 12345678912345.123456789123456;

b = a + 1;

run;
---

result in

b = 12345678912346.100000000000000?

OS is AIX.

Thanks,
Thomas
1 REPLY 1
Doc_Duke
Rhodochrosite | Level 12
Roundoff.

SAS stores all numbers in floating point. The largest is 8 bytes. Your OS companion can tell you how big a number can be stored with what level of precision.

Doc Muhlbaier
Duke

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 751 views
  • 0 likes
  • 2 in conversation