<?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: length of a variable is 100 I need to cut every variable with 20 length? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409360#M100004</link>
    <description>Post sample data and what you’ve tried so far.&amp;nbsp;
Your question is ambiguous. I’m not sure if that’s due to the forum being messed up, English or not taking the time to properly phrase and illustrate your issue.&amp;nbsp;

FYI - there are solutions to this problem on this site and lexjansen.com</description>
    <pubDate>Wed, 01 Nov 2017 06:00:00 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2017-11-01T06:00:00Z</dc:date>
    <item>
      <title>length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409352#M100000</link>
      <description>Example: I'm having a variable with this value I need to split every variable with 20 length for suppose no variable value split with like "bother" ------both in one variable and ther into other variable ("But I don't see why you need to bother won't the consumer of your XPORT file just glue the cut up text back together in one variable. You could even supply the program.") Required Output: every vairble with 20 length no split words col1 -----But I don't see why you need to bother col2------won't the consumer of your XPORT col3---------file just glue the cut up text back together in col4-----one variable. You could even supply the program.")</description>
      <pubDate>Wed, 01 Nov 2017 04:39:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409352#M100000</guid>
      <dc:creator>rajeshalwayswel</dc:creator>
      <dc:date>2017-11-01T04:39:52Z</dc:date>
    </item>
    <item>
      <title>Re: length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409360#M100004</link>
      <description>Post sample data and what you’ve tried so far.&amp;nbsp;
Your question is ambiguous. I’m not sure if that’s due to the forum being messed up, English or not taking the time to properly phrase and illustrate your issue.&amp;nbsp;

FYI - there are solutions to this problem on this site and lexjansen.com</description>
      <pubDate>Wed, 01 Nov 2017 06:00:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409360#M100004</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2017-11-01T06:00:00Z</dc:date>
    </item>
    <item>
      <title>Re: length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409391#M100024</link>
      <description>&lt;P&gt;Your post makes no sense.&amp;nbsp; Supply, per the guidance found when you post a question, test data in the form of a datastep, what the output should look like, any logic which may happen.&amp;nbsp; Also post any code you have tried as this is not a contract work forum but a Q&amp;amp;A.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Do also note that yesterday there was an issue with the forum, you should now be able to use RichText box with code windows - {i} above post area - and proper formatting to show clearly what you want.&lt;/P&gt;</description>
      <pubDate>Wed, 01 Nov 2017 09:48:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409391#M100024</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-11-01T09:48:54Z</dc:date>
    </item>
    <item>
      <title>Re: length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409530#M100052</link>
      <description>sorry for everything if make any make inconvenience to other...</description>
      <pubDate>Wed, 01 Nov 2017 16:13:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409530#M100052</guid>
      <dc:creator>rajeshalwayswel</dc:creator>
      <dc:date>2017-11-01T16:13:08Z</dc:date>
    </item>
    <item>
      <title>Re: length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409659#M100089</link>
      <description>&lt;P&gt;You really really need to&amp;nbsp;format your questions better. A big lump of text is just lazy.&lt;/P&gt;
&lt;P&gt;From what I understood:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data HAVE;
  length VAR $100 ;
  array COL [6]  $20;
  VAR='But I don''t see why you need to bother won''t the consumer of your XPORT file just glue the cut up ';
  START=1;
  do C=1 to 6;
    END=find(VAR,' ',-START-20);
    COL[C]=substr(VAR, START, END);
    START=END;
  end; 
run; &lt;/CODE&gt;&lt;/PRE&gt;
&lt;DIV class="branch"&gt;
&lt;DIV&gt;
&lt;DIV align="center"&gt;
&lt;TABLE class="table" summary="Procedure Print: Data Set WORK.HAVE" frame="box" rules="all" cellspacing="0" cellpadding="5"&gt;
&lt;THEAD&gt;
&lt;TR&gt;
&lt;TH class="l header" scope="col"&gt;COL1&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;COL2&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;COL3&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;COL4&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;COL5&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;COL6&lt;/TH&gt;
&lt;/TR&gt;
&lt;/THEAD&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;But I don't see why&lt;/TD&gt;
&lt;TD class="l data"&gt;you need to bother&lt;/TD&gt;
&lt;TD class="l data"&gt;won't the consumer&lt;/TD&gt;
&lt;TD class="l data"&gt;of your XPORT file&lt;/TD&gt;
&lt;TD class="l data"&gt;just glue the cut u&lt;/TD&gt;
&lt;TD class="l data"&gt;up&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I let you sort out the&amp;nbsp;behaviour when reaching the end of the string if&amp;nbsp; the above is too basic.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Nov 2017 22:00:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409659#M100089</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-11-01T22:00:15Z</dc:date>
    </item>
    <item>
      <title>Re: length of a variable is 100 I need to cut every variable with 20 length?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409702#M100114</link>
      <description>Thanks...One more thing is in col5 we don't split word we need full word that needs to come in column and while running in 9.4 we have some notes.... I'll explain clear in next time of my questions...</description>
      <pubDate>Thu, 02 Nov 2017 03:29:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/length-of-a-variable-is-100-I-need-to-cut-every-variable-with-20/m-p/409702#M100114</guid>
      <dc:creator>rajeshalwayswel</dc:creator>
      <dc:date>2017-11-02T03:29:53Z</dc:date>
    </item>
  </channel>
</rss>

