BookmarkSubscribeRSS Feed
ramonsi2
Calcite | Level 5
*Format number

How Can import a file whit 19 Digit number format field.

Ex: 7086754897126543865
2 REPLIES 2
Tom
Super User Tom
Super User

@ramonsi2 wrote:
*Format number

How Can import a file whit 19 Digit number format field.

Ex: 7086754897126543865

What do you mean by "IMPORT"?

If the value is in a text file then do not "import' it. Instead READ it from the text file with a data step.

 

If you have a 19 digit string in a text file then read it as a character variable.  If you try to read it as a number you will "lose" some of the digits.  SAS stores numbers as 64-bit binary floating point values.  You cannot represent 19 digits exactly without some possible values being rounded to a multiple of two because there are not enough bits used for representing the value (the rest of the bits are used to store the magnitude (power of 2).

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 794 views
  • 1 like
  • 3 in conversation