<?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 want to create a loop or run a data step that reproduces all observations repetitively in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541415#M149472</link>
    <description>&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Good evening.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on a code in which I have to reproduce all observations in loop (max iteration of loop will be decided by number of observations) in such a way that each variable value is reproduced against all values and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;have&lt;/STRONG&gt;&lt;BR /&gt;Apple&lt;BR /&gt;Orange&lt;BR /&gt;Banana&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Want&lt;/STRONG&gt;&lt;BR /&gt;Apple, Apple&lt;BR /&gt;Apple, Orange&lt;BR /&gt;Apple, Banana&lt;BR /&gt;Orange, Apple&lt;BR /&gt;Orange, Orange&lt;BR /&gt;Orange, Banana&lt;BR /&gt;Banana,Apple&lt;BR /&gt;Banana, Orange&lt;BR /&gt;Banana, Banana&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The number of observations in "have" list can change each time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please help!&lt;/P&gt;</description>
    <pubDate>Fri, 08 Mar 2019 14:53:20 GMT</pubDate>
    <dc:creator>tolapa</dc:creator>
    <dc:date>2019-03-08T14:53:20Z</dc:date>
    <item>
      <title>want to create a loop or run a data step that reproduces all observations repetitively</title>
      <link>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541415#M149472</link>
      <description>&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Good evening.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on a code in which I have to reproduce all observations in loop (max iteration of loop will be decided by number of observations) in such a way that each variable value is reproduced against all values and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;have&lt;/STRONG&gt;&lt;BR /&gt;Apple&lt;BR /&gt;Orange&lt;BR /&gt;Banana&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Want&lt;/STRONG&gt;&lt;BR /&gt;Apple, Apple&lt;BR /&gt;Apple, Orange&lt;BR /&gt;Apple, Banana&lt;BR /&gt;Orange, Apple&lt;BR /&gt;Orange, Orange&lt;BR /&gt;Orange, Banana&lt;BR /&gt;Banana,Apple&lt;BR /&gt;Banana, Orange&lt;BR /&gt;Banana, Banana&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The number of observations in "have" list can change each time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please help!&lt;/P&gt;</description>
      <pubDate>Fri, 08 Mar 2019 14:53:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541415#M149472</guid>
      <dc:creator>tolapa</dc:creator>
      <dc:date>2019-03-08T14:53:20Z</dc:date>
    </item>
    <item>
      <title>Re: want to create a loop or run a data step that reproduces all observations repetitively</title>
      <link>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541420#M149473</link>
      <description>&lt;P&gt;This is an easy task for SQL:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql;&lt;/P&gt;
&lt;P&gt;create table want as select a.fruit as v1, b.fruit as v2&lt;/P&gt;
&lt;P&gt;from have a, have b;&lt;/P&gt;
&lt;P&gt;quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm guessing at the variable names to use, since you didn't supply any in your question.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think I got the syntax right, but it might need a little tweak.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 08 Mar 2019 15:01:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541420#M149473</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2019-03-08T15:01:24Z</dc:date>
    </item>
    <item>
      <title>Re: want to create a loop or run a data step that reproduces all observations repetitively</title>
      <link>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541421#M149474</link>
      <description>&lt;P&gt;You approach was also what came to mind for me. I can see DBA's having a huge issue with a Cartesian join, but for small tables that certainty works!&lt;/P&gt;</description>
      <pubDate>Fri, 08 Mar 2019 15:06:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/want-to-create-a-loop-or-run-a-data-step-that-reproduces-all/m-p/541421#M149474</guid>
      <dc:creator>noling</dc:creator>
      <dc:date>2019-03-08T15:06:09Z</dc:date>
    </item>
  </channel>
</rss>

