<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic To convert 13 digit into string. in Programming 1 and 2</title>
    <link>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847219#M1249</link>
    <description>&lt;P&gt;Hi, I'm still new to sas programming. My question as per example below :-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In excel : 1.322E+22&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Need to change into this format : 1322000246674 (string)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyone can help me on this. I've tried change the format into string somehow it is still the same.&lt;/P&gt;&lt;P&gt;I've tried used functionPUT/INPUT but still the same.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 01 Dec 2022 10:04:45 GMT</pubDate>
    <dc:creator>aziq_az1304</dc:creator>
    <dc:date>2022-12-01T10:04:45Z</dc:date>
    <item>
      <title>To convert 13 digit into string.</title>
      <link>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847219#M1249</link>
      <description>&lt;P&gt;Hi, I'm still new to sas programming. My question as per example below :-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In excel : 1.322E+22&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Need to change into this format : 1322000246674 (string)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyone can help me on this. I've tried change the format into string somehow it is still the same.&lt;/P&gt;&lt;P&gt;I've tried used functionPUT/INPUT but still the same.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 10:04:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847219#M1249</guid>
      <dc:creator>aziq_az1304</dc:creator>
      <dc:date>2022-12-01T10:04:45Z</dc:date>
    </item>
    <item>
      <title>Re: To convert 13 digit into string.</title>
      <link>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847221#M1250</link>
      <description>&lt;P&gt;Do you want to do this in Excel or in SAS?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't think you can convert a number with E+22 exactly&lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 10:50:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847221#M1250</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2022-12-01T10:50:47Z</dc:date>
    </item>
    <item>
      <title>Re: To convert 13 digit into string.</title>
      <link>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847227#M1251</link>
      <description>&lt;P&gt;Were you able to successfully read the data from Excel into a numeric variable in a SAS data set? That is the first step.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The second step is to use the PUT statement and specify a format that is suitable for your purpose. In the following program, I show how to use the &lt;EM&gt;w.d&lt;/EM&gt; format 30.16, but you might prefer to use 30. if the number is always an integer.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* Assume that you have read the data into a SAS data set named "Have".
  Here, I create the data set with fake data. */
data Have;
input x;
datalines;
1.322E+22
1.23456789E16
;

data Want;
length str $30;
set Have;
str = put(x, 30.16);  /* apply a SAS format to convert the number to a string */
run;

proc print; run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;For more information, see &lt;A href="http://support.sas.com/kb/24/590.html" target="_self"&gt;"Convert numeric values to character."&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Dec 2022 11:05:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Programming-1-and-2/To-convert-13-digit-into-string/m-p/847227#M1251</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2022-12-01T11:05:37Z</dc:date>
    </item>
  </channel>
</rss>

