<?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: Dealing with carriage returns in a SAS string in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96657#M27262</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I should add that the closest I have got to a solution is &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;varname = COMPRESS(varname, ' ',"s")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;which does indeed get rid of the leading CR, but also unfortunately gets rid of all blanks in the text which is not quite what I want to do.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 01 Aug 2013 14:23:26 GMT</pubDate>
    <dc:creator>cb23_york</dc:creator>
    <dc:date>2013-08-01T14:23:26Z</dc:date>
    <item>
      <title>Dealing with carriage returns in a SAS string</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96656#M27261</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear all, would appreciate your help on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an excel imported data sheet which for the most part looks fine.&amp;nbsp; Within this imported data I have one character variable which for some cases shows ...&amp;nbsp; Now if I try and select variables on the basis that this variable contains ... it selects none.&amp;nbsp; Furthermore when I hover my cursor over the the relevant box on the data screen the pop-up shows a blank line followed by some meaningful text underneath the blank line.&amp;nbsp; I'm guessing then that the character variable in this case is a carriage return followed by text.&amp;nbsp; I want to get rid off the CR and just have the text but I can't seem to get compress or trim to do the trick.&amp;nbsp; Does anyone have any suggestions?&amp;nbsp; Hope my question is clear enough.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best wishes,&amp;nbsp;&amp;nbsp; Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Aug 2013 14:18:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96656#M27261</guid>
      <dc:creator>cb23_york</dc:creator>
      <dc:date>2013-08-01T14:18:41Z</dc:date>
    </item>
    <item>
      <title>Re: Dealing with carriage returns in a SAS string</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96657#M27262</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I should add that the closest I have got to a solution is &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;varname = COMPRESS(varname, ' ',"s")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;which does indeed get rid of the leading CR, but also unfortunately gets rid of all blanks in the text which is not quite what I want to do.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Aug 2013 14:23:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96657#M27262</guid>
      <dc:creator>cb23_york</dc:creator>
      <dc:date>2013-08-01T14:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: Dealing with carriage returns in a SAS string</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96658#M27263</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P class="yiv5082456845default" id="yui_3_7_2_1_1375358560898_19449" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19448" style="color: black; font-family: Calibri; font-size: 12pt;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19447" style="font-size: 12pt;"&gt;The syntax for taking out all carriage return ('OD'x) and line feed ('OA'x) characters&amp;nbsp; is&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" id="yui_3_7_2_1_1375358560898_19440" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19439" style="text-decoration: underline;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19438" style="color: blue; font-family: Calibri; font-size: 12pt;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19437" style="font-size: 12pt;"&gt;comment= Compress(comment,'0D0A'x);&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" id="yui_3_7_2_1_1375358560898_19434" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19433" style="text-decoration: underline;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19432" style="color: blue; font-family: Calibri; font-size: 12pt;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19431" style="font-size: 12pt;"&gt;comment= TRANWRD(comment,'0D0A'x,’’);&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" id="yui_3_7_2_1_1375358560898_19428" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19427" style="color: black; font-family: Calibri; font-size: 12pt;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19426" style="font-size: 12pt;"&gt;&lt;BR /&gt;If you just want to take out the Carriage Return, use this code:&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19445" style="text-decoration: underline;"&gt;&lt;SPAN id="yui_3_7_2_1_1375358560898_19444" style="color: blue; font-family: Calibri;"&gt;comment= TRANWRD(comment,'0D'x,'');&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; text-decoration: underline; font-family: Calibri;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; text-decoration: underline; font-family: Calibri;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; font-family: Calibri;"&gt;Sarath &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; text-decoration: underline; font-family: Calibri;"&gt;www.studysas.blogspot.com&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; text-decoration: underline; font-family: Calibri;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="yiv5082456845default" style="font-size: 12pt; font-family: Arial; color: black; background-color: #ffffff;"&gt;&lt;SPAN style="color: blue; text-decoration: underline; font-family: Calibri;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Aug 2013 14:36:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96658#M27263</guid>
      <dc:creator>sarathannapareddy</dc:creator>
      <dc:date>2013-08-01T14:36:56Z</dc:date>
    </item>
    <item>
      <title>Re: Dealing with carriage returns in a SAS string</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96659#M27264</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The compress statement has worked a treat, many thanks Sarath.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Aug 2013 14:46:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Dealing-with-carriage-returns-in-a-SAS-string/m-p/96659#M27264</guid>
      <dc:creator>cb23_york</dc:creator>
      <dc:date>2013-08-01T14:46:26Z</dc:date>
    </item>
  </channel>
</rss>

