<?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: dsd versus no dsd in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467638#M119389</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/183242"&gt;@riyaaora275&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&lt;SPAN&gt;In second line&amp;nbsp; you said the values are in this format&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;lt;empty&amp;gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;but isnt it in the below format because we have only one space before 4 and one space before 5.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;where did&amp;nbsp; &amp;lt;empty&amp;gt; come from?&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Because of the dsd option, the data step assumes that there &lt;U&gt;has to be&lt;/U&gt; a value before the first delimiter (blank). If there's nothing (consider it a string of length 0), then you have a missing value. Without dsd, leading delimiters are skipped until there's something.&lt;/P&gt;</description>
    <pubDate>Tue, 05 Jun 2018 12:26:40 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2018-06-05T12:26:40Z</dc:date>
    <item>
      <title>dsd versus no dsd</title>
      <link>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467578#M119361</link>
      <description>&lt;P&gt;If i have a code -&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
infile datalines ;
input a b c;
datalines;
1 2 3 
 4 5
6 7
;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I get two observations -&lt;/P&gt;&lt;P&gt;1 2 3&lt;/P&gt;&lt;P&gt;4 5 6&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But if i use the code&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
infile datalines dsd dlm=' ';
input a b c ;
datalines;
1 2 3
 4 5
6 7 
;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Here it identifies all the spaces as missing values.&lt;/P&gt;&lt;P&gt;result is&amp;nbsp;&lt;/P&gt;&lt;P&gt;1 2 3&lt;/P&gt;&lt;P&gt;.&amp;nbsp;4 5&lt;/P&gt;&lt;P&gt;6 7.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DSD identifies two delimiters as space where as in the code we have only one space before 4 and it is still identified as a delimiter and a missing value comes before 4.&amp;nbsp; Why?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2018 06:11:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467578#M119361</guid>
      <dc:creator>riyaaora275</dc:creator>
      <dc:date>2018-06-05T06:11:34Z</dc:date>
    </item>
    <item>
      <title>Re: dsd versus no dsd</title>
      <link>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467588#M119366</link>
      <description>&lt;P&gt;With dsd, each single delimiter character (blank since you did not specify another) is counted, so the second row in the datalines is considered as&lt;/P&gt;
&lt;P&gt;&amp;lt;empty&amp;gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/P&gt;
&lt;P&gt;and therefore supplies three values.&lt;/P&gt;
&lt;P&gt;The third row is&lt;/P&gt;
&lt;P&gt;6&amp;lt;blank&amp;gt;7&amp;lt;blank&amp;gt;&amp;lt;emtpy&amp;gt;&lt;/P&gt;
&lt;P&gt;and supplies another three values.&lt;/P&gt;
&lt;P&gt;Without dsd, the leading blank in the second row is simply discarded, and the data step skips to a new line (reading 4/5/6 instead of ./4/5). Since it automatically skips to a new line at the end of the data step iteration (and no more lines are present), value 7 is never read and only 2 observations are output.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2018 07:15:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467588#M119366</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-06-05T07:15:40Z</dc:date>
    </item>
    <item>
      <title>Re: dsd versus no dsd</title>
      <link>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467635#M119387</link>
      <description>&lt;P&gt;&lt;SPAN&gt;In second line&amp;nbsp; you said the values are in this format&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;lt;empty&amp;gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;but isnt it in the below format because we have only one space before 4 and one space before 5.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;where did&amp;nbsp; &amp;lt;empty&amp;gt; come from?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2018 12:06:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467635#M119387</guid>
      <dc:creator>riyaaora275</dc:creator>
      <dc:date>2018-06-05T12:06:28Z</dc:date>
    </item>
    <item>
      <title>Re: dsd versus no dsd</title>
      <link>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467638#M119389</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/183242"&gt;@riyaaora275&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&lt;SPAN&gt;In second line&amp;nbsp; you said the values are in this format&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;lt;empty&amp;gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;but isnt it in the below format because we have only one space before 4 and one space before 5.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;lt;blank&amp;gt;4&amp;lt;blank&amp;gt;5&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;where did&amp;nbsp; &amp;lt;empty&amp;gt; come from?&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Because of the dsd option, the data step assumes that there &lt;U&gt;has to be&lt;/U&gt; a value before the first delimiter (blank). If there's nothing (consider it a string of length 0), then you have a missing value. Without dsd, leading delimiters are skipped until there's something.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2018 12:26:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/dsd-versus-no-dsd/m-p/467638#M119389</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-06-05T12:26:40Z</dc:date>
    </item>
  </channel>
</rss>

