<?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 missing letters in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851376#M336501</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am creating a new column called "group" in my dataset based on the value of another column. The real code I run has many more if conditions but the "group" column has only 3 values; indeterminate, not performance, performance.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;In the output, I have "not performan" rather than "not performance". Why do I have the last 2 letters dropped and how do I fix it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
set mydata;
	if reason = "asd asd asd" then group = "indeterminate";
	if reason = "abc abc abc" then group = "indeterminate";
	if reason=" xxx" then group="not performance"; &lt;BR /&gt;    if reason=" yy " then group="performance"; 
	 else cancellation_grouping = "other";
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Wed, 28 Dec 2022 17:08:30 GMT</pubDate>
    <dc:creator>znhnm</dc:creator>
    <dc:date>2022-12-28T17:08:30Z</dc:date>
    <item>
      <title>missing letters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851376#M336501</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am creating a new column called "group" in my dataset based on the value of another column. The real code I run has many more if conditions but the "group" column has only 3 values; indeterminate, not performance, performance.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;In the output, I have "not performan" rather than "not performance". Why do I have the last 2 letters dropped and how do I fix it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
set mydata;
	if reason = "asd asd asd" then group = "indeterminate";
	if reason = "abc abc abc" then group = "indeterminate";
	if reason=" xxx" then group="not performance"; &lt;BR /&gt;    if reason=" yy " then group="performance"; 
	 else cancellation_grouping = "other";
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 17:08:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851376#M336501</guid>
      <dc:creator>znhnm</dc:creator>
      <dc:date>2022-12-28T17:08:30Z</dc:date>
    </item>
    <item>
      <title>Re: missing letters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851378#M336502</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Length of GROUP variable is decided upon when GROUP gets its first value.&lt;/P&gt;
&lt;P&gt;If first value assigned is 'ABC' then length becomes 3 and all other values (assigned later) are truncated as from the 4th position.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can change the way length is determined by explicitly specifying the length yourselves for GROUP variable, like here :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
 LENGTH group $ 15;
 set mydata;
	if reason = "asd asd asd" then group = "indeterminate";
	if reason = "abc abc abc" then group = "indeterminate";
	if reason=" xxx" then group="not performance";     if reason=" yy " then group="performance"; 
	 else cancellation_grouping = "other";
run;
/* end of program */&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;Koen&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 17:13:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851378#M336502</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2022-12-28T17:13:54Z</dc:date>
    </item>
    <item>
      <title>Re: missing letters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851383#M336505</link>
      <description>Hello, thank you so much!&lt;BR /&gt;&lt;BR /&gt;When I try it, I have an error saying:&lt;BR /&gt;&lt;BR /&gt;Expecting an arithmetic operator.&lt;BR /&gt;&lt;BR /&gt;What could be the reason of it?</description>
      <pubDate>Wed, 28 Dec 2022 17:50:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851383#M336505</guid>
      <dc:creator>znhnm</dc:creator>
      <dc:date>2022-12-28T17:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: missing letters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851387#M336508</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can you post the LOG?&lt;/P&gt;
&lt;P&gt;Copy the LOG , click on the &amp;lt;/&amp;gt; icon in the toolbar on top when replying , then paste LOG in pop-up window!&lt;BR /&gt;&lt;BR /&gt;Also, you might want :&lt;/P&gt;
&lt;P&gt;if ; else if ; else if ; else if ; else ;&lt;/P&gt;
&lt;P&gt;instead of 4 times if + an else ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Koen&lt;/P&gt;
&lt;DIV id="ConnectiveDocSignExtentionInstalled" data-extension-version="1.0.4"&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Wed, 28 Dec 2022 18:01:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851387#M336508</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2022-12-28T18:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: missing letters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851389#M336509</link>
      <description>Hi Koen,&lt;BR /&gt;&lt;BR /&gt;I realized that I made a typo. Sorry about it. Your suggestion works perfectly. Appreciated your help!</description>
      <pubDate>Wed, 28 Dec 2022 18:11:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/missing-letters/m-p/851389#M336509</guid>
      <dc:creator>znhnm</dc:creator>
      <dc:date>2022-12-28T18:11:15Z</dc:date>
    </item>
  </channel>
</rss>

