<?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: Can any one help me below issue either macro or datastep should be fine in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454130#M114787</link>
    <description>&lt;P&gt;1.actuvally the count is 3 only by mistake it's edited to 2&lt;/P&gt;&lt;P&gt;2.please consider dataset a and b are same order&lt;/P&gt;&lt;P&gt;3.yes i want the numbered&amp;nbsp; quantity/date pairs go to the respective to input dataset order&lt;/P&gt;</description>
    <pubDate>Sat, 14 Apr 2018 09:06:20 GMT</pubDate>
    <dc:creator>Bhargavi221</dc:creator>
    <dc:date>2018-04-14T09:06:20Z</dc:date>
    <item>
      <title>Can any one help me below issue either macro or datastep should be fine</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454126#M114784</link>
      <description>&lt;OL&gt;&lt;LI&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Table A" style="width: 214px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19803iF958B1DC2EED0C9B/image-size/large?v=v2&amp;amp;px=999" role="button" title="Table A.png" alt="Table A" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Table A&lt;/span&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Table B" style="width: 268px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19804i2C7BD52D74CB1B1A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Table B.png" alt="Table B" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Table B&lt;/span&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Table c" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/19805i2F515A2827E28CAF/image-size/large?v=v2&amp;amp;px=999" role="button" title="Table C.png" alt="Table c" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Table c&lt;/span&gt;&lt;/span&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;I have Table A and Table B , I want desired output should be like Table C&lt;/P&gt;&lt;P&gt;Either Macro or datastep should be fine&lt;/P&gt;&lt;P&gt;thanks in advance&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 14 Apr 2018 06:27:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454126#M114784</guid>
      <dc:creator>Bhargavi221</dc:creator>
      <dc:date>2018-04-14T06:27:26Z</dc:date>
    </item>
    <item>
      <title>Re: Can any one help me below issue either macro or datastep should be fine</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454128#M114786</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It can be solved, but I&amp;nbsp;have a couple of questions.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;I do not understand why the COUNT field in data set C is changes from 3 to 2 in the first two rows with ID 650.&amp;nbsp;&lt;/LI&gt;
&lt;LI&gt;As there is no Unique ID, we must presume that the data sets A and B are in the same order.&amp;nbsp;Otherwise&amp;nbsp;is is not possible to pair dates and quantities within the same ID group,&amp;nbsp; eg. the quantity 50 to the date 31may2018.&lt;/LI&gt;
&lt;LI&gt;Do you really want the numbered quantity/date pairs in C to respect the input data order,&amp;nbsp;so 20mar2018 goes in pair&amp;nbsp;3, after the dates in May?&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Sat, 14 Apr 2018 08:34:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454128#M114786</guid>
      <dc:creator>ErikLund_Jensen</dc:creator>
      <dc:date>2018-04-14T08:34:38Z</dc:date>
    </item>
    <item>
      <title>Re: Can any one help me below issue either macro or datastep should be fine</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454130#M114787</link>
      <description>&lt;P&gt;1.actuvally the count is 3 only by mistake it's edited to 2&lt;/P&gt;&lt;P&gt;2.please consider dataset a and b are same order&lt;/P&gt;&lt;P&gt;3.yes i want the numbered&amp;nbsp; quantity/date pairs go to the respective to input dataset order&lt;/P&gt;</description>
      <pubDate>Sat, 14 Apr 2018 09:06:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454130#M114787</guid>
      <dc:creator>Bhargavi221</dc:creator>
      <dc:date>2018-04-14T09:06:20Z</dc:date>
    </item>
    <item>
      <title>Re: Can any one help me below issue either macro or datastep should be fine</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454141#M114792</link>
      <description>&lt;P&gt;Post the sas code, NOT picture, nobody would like to type it for you if want help from others.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data a;
input id count dty;
cards;
1022 2 200
1022 2 600
6500  3  3
6500  3 50
6500  3 12
;
data b;
input id dt : date9.;
format dt date9.;
cards;
1022 25apr2018
1022 11jul2018
6500  08may2018
6500  31may2018
6500  20mar2018
;
data have;
 merge a b;
 by id;
run;
proc sql noprint;
select max(count) into : n
 from (select count(*) as count from have group by id);
quit;
data want;
 set have;
 by id;
 array dty_{&amp;amp;n};
 array dt_{&amp;amp;n};
 if first.id then n=0;
 n+1;dty_{n}=dty;dt_{n}=dt;
drop dt n;
format dt_: date9.;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 14 Apr 2018 11:59:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Can-any-one-help-me-below-issue-either-macro-or-datastep-should/m-p/454141#M114792</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-04-14T11:59:00Z</dc:date>
    </item>
  </channel>
</rss>

