<?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 Re: read a numerical value &amp;quot;111&amp;quot; in a format as &amp;quot;0111&amp;quot; in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627110#M185032</link>
    <description>&lt;P&gt;When leading zeroes need to be kept, it's usually not a number, but some kind of code. Read as character.&lt;/P&gt;</description>
    <pubDate>Tue, 25 Feb 2020 06:43:38 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2020-02-25T06:43:38Z</dc:date>
    <item>
      <title>read a numerical value "111" in a format as "0111"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627061#M185014</link>
      <description>&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to read a numerical value (i.g., SIC)&amp;nbsp; "111" in a format as "0111" by the following code.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;DATA SIC_code_list;
	infile "G:\PATSTAT_control_variable\CSV\SIC_Code_List.csv"
	DLM = ";"
	DSD
	missover
	lrecl=32767
	firstobs = 2;
	input
	SIC : 4.
	Description :$1000.
	;
	format
	SIC 4.
	;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;however, I only get 111, is there any method to change the format and shown as 0111?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks in advance.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Feb 2020 00:09:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627061#M185014</guid>
      <dc:creator>Alexxxxxxx</dc:creator>
      <dc:date>2020-02-25T00:09:10Z</dc:date>
    </item>
    <item>
      <title>Re: read a numerical value "111" in a format as "0111"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627062#M185015</link>
      <description>&lt;P&gt;Use Z format&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;format	SIC z4.;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
DATA SIC_code_list;
	infile "G:\PATSTAT_control_variable\CSV\SIC_Code_List.csv"
	DLM = ";"
	DSD
	missover
	lrecl=32767
	firstobs = 2;
	input
	SIC : 4.
	Description :$1000.
	;
	format	SIC Z4.	;/*Notice here*/
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Feb 2020 00:53:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627062#M185015</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2020-02-25T00:53:46Z</dc:date>
    </item>
    <item>
      <title>Re: read a numerical value "111" in a format as "0111"</title>
      <link>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627110#M185032</link>
      <description>&lt;P&gt;When leading zeroes need to be kept, it's usually not a number, but some kind of code. Read as character.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Feb 2020 06:43:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/read-a-numerical-value-quot-111-quot-in-a-format-as-quot-0111/m-p/627110#M185032</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2020-02-25T06:43:38Z</dc:date>
    </item>
  </channel>
</rss>

