<?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 Converting Oracle Integer to SAS Numeric in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18836#M2872</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is all explained here:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/lrcon/62955/HTML/default/viewer.htm#a000695157.htm"&gt;http://support.sas.com/documentation/cdl/en/lrcon/62955/HTML/default/viewer.htm#a000695157.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sascommunity.org/wiki/Numeric_representation_issues_in_SAS"&gt;http://www.sascommunity.org/wiki/Numeric_representation_issues_in_SAS&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The larger integer sas can accurately represent with 8 bytes is 9,007,199,254,740,990 under Windows and 72,057,594,037,927,900 on mainframes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your number 12,345,678,912,345,445 is too large for the Windows platform.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 10 Aug 2011 05:59:16 GMT</pubDate>
    <dc:creator>ChrisNZ</dc:creator>
    <dc:date>2011-08-10T05:59:16Z</dc:date>
    <item>
      <title>Converting Oracle Integer to SAS Numeric</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18833#M2869</link>
      <description>Hi ,&lt;BR /&gt;
&lt;BR /&gt;
While reading a table from Oracle which has a column containing an Oracle Integer value of 17 digits from sas  and converting to a dataset , is displayed in SAS as Exponentinal no. &lt;BR /&gt;
&lt;BR /&gt;
ex  REGNO(ORACLE)                                         12345678912345445   &lt;BR /&gt;
&lt;BR /&gt;
VAR(SAS)&lt;BR /&gt;
1.26E16&lt;BR /&gt;
&lt;BR /&gt;
However if  I convert it again into numeric using Input function while reading , the value would be rounded   123456789123454&lt;B&gt;50&lt;/B&gt; . &lt;BR /&gt;
&lt;BR /&gt;
Please could someone suggest an alternative to  display the full digits .&lt;BR /&gt;
&lt;BR /&gt;
Message was edited by: tommy81&lt;BR /&gt;
&lt;BR /&gt;
Message was edited by: tommy81

Message was edited by: tommy81</description>
      <pubDate>Tue, 01 Mar 2011 08:05:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18833#M2869</guid>
      <dc:creator>tommy81</dc:creator>
      <dc:date>2011-03-01T08:05:06Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Oracle Integer to SAS Numeric</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18834#M2870</link>
      <description>Unfortunately,I guess your SAS only has exact int about 16 digit.You can test it by yourself &lt;BR /&gt;
with the following my code,that mean you can not use it to mathematical ,But you can&lt;BR /&gt;
display it by transforming it into character type or make length longer.(only suited for 17 digit)&lt;BR /&gt;
p.s 8 is the max bytes for numeric data in my computer. So only can exact to 16 digit.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
[pre]&lt;BR /&gt;
data _null_;&lt;BR /&gt;
 exactint=constant('exactint',8);&lt;BR /&gt;
 put 'exactint=' exactint ;&lt;BR /&gt;
 length test 8;&lt;BR /&gt;
 input test best20.;&lt;BR /&gt;
 put 'test=' test best20.;&lt;BR /&gt;
 char_test=put(test,best20.);&lt;BR /&gt;
 put 'char_test=' char_test;&lt;BR /&gt;
stop;&lt;BR /&gt;
cards;&lt;BR /&gt;
12345678912345678&lt;BR /&gt;
;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
[/pre]&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ksharp</description>
      <pubDate>Tue, 01 Mar 2011 09:34:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18834#M2870</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-03-01T09:34:04Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Oracle Integer to SAS Numeric</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18835#M2871</link>
      <description>You could convert the oracle integer to character during pull.&lt;BR /&gt;
&lt;BR /&gt;
proc sql;&lt;BR /&gt;
 connect to oracle(user=blah orapw=blah path=blah connection=global);&lt;BR /&gt;
&lt;BR /&gt;
 create table blah as select * from connection to oracle&lt;BR /&gt;
 ( select to_char(integer,9999999999999999) as char from table );&lt;BR /&gt;
&lt;BR /&gt;
 disconnect fro oracle;&lt;BR /&gt;
quit;</description>
      <pubDate>Thu, 03 Mar 2011 23:15:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18835#M2871</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2011-03-03T23:15:42Z</dc:date>
    </item>
    <item>
      <title>Converting Oracle Integer to SAS Numeric</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18836#M2872</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is all explained here:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/lrcon/62955/HTML/default/viewer.htm#a000695157.htm"&gt;http://support.sas.com/documentation/cdl/en/lrcon/62955/HTML/default/viewer.htm#a000695157.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sascommunity.org/wiki/Numeric_representation_issues_in_SAS"&gt;http://www.sascommunity.org/wiki/Numeric_representation_issues_in_SAS&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The larger integer sas can accurately represent with 8 bytes is 9,007,199,254,740,990 under Windows and 72,057,594,037,927,900 on mainframes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your number 12,345,678,912,345,445 is too large for the Windows platform.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Aug 2011 05:59:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Converting-Oracle-Integer-to-SAS-Numeric/m-p/18836#M2872</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2011-08-10T05:59:16Z</dc:date>
    </item>
  </channel>
</rss>

