<?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: Question how do I add leading zero to numbers under 10? in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151853#M39961</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Then naming is giving the impression it is about geo.&lt;/P&gt;&lt;P&gt;&lt;A class="active_link" href="http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a003113162.htm"&gt;http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a003113162.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;A nice paper &lt;A class="active_link" href="http://support.sas.com/resources/papers/proceedings11/299-2011.pdf"&gt;http://support.sas.com/resources/papers/proceedings11/299-2011.pdf&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 31 Oct 2014 13:14:33 GMT</pubDate>
    <dc:creator>jakarman</dc:creator>
    <dc:date>2014-10-31T13:14:33Z</dc:date>
    <item>
      <title>Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151848#M39956</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;I need to add leading zero to any number under 10.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;data lat;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;set clovis_data;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;&amp;nbsp; latdeg1=int(latitude);&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;&amp;nbsp; latdeg2=int((latitude-latdeg1)*60);&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif'; font-size: 12pt;"&gt;&amp;nbsp; latdeg3=round((((latitude-latdeg1)*60)-latdeg2)*60);&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;SPAN style="font-family: 'Tahoma','sans-serif';"&gt;&lt;SPAN style="font-size: 12pt;"&gt;run&lt;/SPAN&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="Normal"&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="text-indent: 0in;"&gt;&lt;SPAN style="font-size: 12pt;"&gt;I need to add leading zero to any number under 10 for Latdeg2 and Latdeg3.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="text-indent: 0in;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt; font-family: Courier New;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 12:22:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151848#M39956</guid>
      <dc:creator>GregINGov</dc:creator>
      <dc:date>2014-10-31T12:22:58Z</dc:date>
    </item>
    <item>
      <title>Re: Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151849#M39957</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use the format Z2. to make the values appear with a leading zero (or some version of the Zw.d format)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or you can turn them into character variables and concatenate a zero before the actual value if it is less than 10.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Of the two choices, I prefer the first in most cases, which leaves the number as a numeric variable&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 12:39:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151849#M39957</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2014-10-31T12:39:13Z</dc:date>
    </item>
    <item>
      <title>Re: Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151850#M39958</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;so in format Z2 I&amp;nbsp; can make just the number under 10 with a leading zero?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 12:46:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151850#M39958</guid>
      <dc:creator>GregINGov</dc:creator>
      <dc:date>2014-10-31T12:46:19Z</dc:date>
    </item>
    <item>
      <title>Re: Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151851#M39959</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That is the explicit purpose of the z2. format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2 -&amp;gt; 02&lt;/P&gt;&lt;P&gt;9 -&amp;gt; 09&lt;/P&gt;&lt;P&gt;10 -&amp;gt; 10&lt;/P&gt;&lt;P&gt;100 and up will yield ** and generate a NOTE in the log that the format was too small.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 12:54:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151851#M39959</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2014-10-31T12:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151852#M39960</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, if you have a 0 preceding a number like: 02, its not really a number as such.&amp;nbsp; So the number there is 2.&amp;nbsp; If you want to display that with a preceding 0 then you have two options - apply a format Z2. to that variable - or put the number into Z2 and store it in a character variable.&amp;nbsp; There are plusses and minus to each approach.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 12:55:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151852#M39960</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2014-10-31T12:55:36Z</dc:date>
    </item>
    <item>
      <title>Re: Question how do I add leading zero to numbers under 10?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151853#M39961</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Then naming is giving the impression it is about geo.&lt;/P&gt;&lt;P&gt;&lt;A class="active_link" href="http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a003113162.htm"&gt;http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a003113162.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;A nice paper &lt;A class="active_link" href="http://support.sas.com/resources/papers/proceedings11/299-2011.pdf"&gt;http://support.sas.com/resources/papers/proceedings11/299-2011.pdf&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 31 Oct 2014 13:14:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Question-how-do-I-add-leading-zero-to-numbers-under-10/m-p/151853#M39961</guid>
      <dc:creator>jakarman</dc:creator>
      <dc:date>2014-10-31T13:14:33Z</dc:date>
    </item>
  </channel>
</rss>

