<?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: Adding tables count to another table in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805370#M33481</link>
    <description>&lt;P&gt;So you want to make a REPORT that has three observations and one variable?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You could use PROC SQL.&lt;/P&gt;
&lt;P&gt;Let's assume your three datasets are named&amp;nbsp; A, B and C.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
select 1 as order,catx(' - ',count(*),'total purchases done.') as message from A
union
select 2 as order,catx(' - ',count(*),'total new products.') as message from B
union
select 3 as order,catx(' - ',count(*),'total old products using barcode.') as message from C
order by order
;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 31 Mar 2022 17:20:25 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2022-03-31T17:20:25Z</dc:date>
    <item>
      <title>Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805256#M33465</link>
      <description>Hi All,&lt;BR /&gt;I hope you're all doing Good.&lt;BR /&gt;I require some assistance from you all on achieving. Any help would be appreciated. Thankyou.&lt;BR /&gt;I've 3 tables data which has some count individually. I would like to take all these 3 tables count and put them into a new table. And the values in that new table should like&lt;BR /&gt;Without any headers. For an instance. The 1st table has 123 rows so it should be placed in new table like this.&lt;BR /&gt;&lt;BR /&gt;123 - total purchases done.&lt;BR /&gt;And the 2nd table has 530 rows so it should be placed in new table like this.&lt;BR /&gt;&lt;BR /&gt;530 - total new products.&lt;BR /&gt;&lt;BR /&gt;And the 3rd table has 90 rows so it should be placed in new table like this.&lt;BR /&gt;&lt;BR /&gt;90 - total old products using barcode.&lt;BR /&gt;Finally, the final table should have 3 tables rows count and some comments which I mentioned above seperated with hiphen (-). And the also in final table each value should have atleast 2 rows gap which is like this.&lt;BR /&gt;&lt;BR /&gt;123 - total purchases done&lt;BR /&gt;&lt;BR /&gt;530 - total new products&lt;BR /&gt;&lt;BR /&gt;90 - total old products using barcode.&lt;BR /&gt;&lt;BR /&gt;For your information, those 3 tables rows count will be changed daily wise as they gonna be updated daily and the rows in them aren't permanent they keep on changing on daily run.</description>
      <pubDate>Thu, 31 Mar 2022 13:39:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805256#M33465</guid>
      <dc:creator>Pandu2</dc:creator>
      <dc:date>2022-03-31T13:39:17Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805308#M33470</link>
      <description>&lt;P&gt;Example data should be in the form of data step code.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Instructions here: &lt;A href="https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-data-AKA-generate/ta-p/258712" target="_blank"&gt;https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-data-AKA-generate/ta-p/258712&lt;/A&gt; will show how to turn an existing SAS data set into data step code that can be pasted into a forum code box using the &amp;lt;&amp;gt; icon or attached as text to show exactly what you have and that we can test code against.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;By table do you mean a data set or a report that people read?&lt;/P&gt;</description>
      <pubDate>Thu, 31 Mar 2022 14:42:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805308#M33470</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2022-03-31T14:42:27Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805336#M33477</link>
      <description>&lt;P&gt;So you basically want to append the observation counts of three datasets with the dataset labels?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The strings that you posted are not valid as dataset names.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Mar 2022 15:30:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805336#M33477</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2022-03-31T15:30:31Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805350#M33478</link>
      <description>Yes the observations count of three datasets into a new dataset but not with dataset labels. In that new dataset the values format should be mentioned above &lt;BR /&gt;1st dataset obs count - mentioned text &lt;BR /&gt;Likewise 2nd and 3rd datasets obs count alongside mentioned text separated with hiphen - &lt;BR /&gt;Thankyou.&lt;BR /&gt;</description>
      <pubDate>Thu, 31 Mar 2022 16:20:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805350#M33478</guid>
      <dc:creator>Pandu2</dc:creator>
      <dc:date>2022-03-31T16:20:02Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805370#M33481</link>
      <description>&lt;P&gt;So you want to make a REPORT that has three observations and one variable?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You could use PROC SQL.&lt;/P&gt;
&lt;P&gt;Let's assume your three datasets are named&amp;nbsp; A, B and C.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
select 1 as order,catx(' - ',count(*),'total purchases done.') as message from A
union
select 2 as order,catx(' - ',count(*),'total new products.') as message from B
union
select 3 as order,catx(' - ',count(*),'total old products using barcode.') as message from C
order by order
;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 31 Mar 2022 17:20:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805370#M33481</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2022-03-31T17:20:25Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805373#M33482</link>
      <description>&lt;P&gt;How do you relate the texts to dataset names?&lt;/P&gt;</description>
      <pubDate>Thu, 31 Mar 2022 18:01:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805373#M33482</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2022-03-31T18:01:32Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805401#M33483</link>
      <description>Yes, it's quite similar to report but I would like to put that info in an already existing excel file named purchases in a new sheet. That's my main motto.</description>
      <pubDate>Thu, 31 Mar 2022 22:16:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805401#M33483</guid>
      <dc:creator>Pandu2</dc:creator>
      <dc:date>2022-03-31T22:16:34Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805403#M33484</link>
      <description>&lt;P&gt;Stuffing dynamic data into an existing EXCEL file is not really a workable idea.&lt;/P&gt;
&lt;P&gt;You could update a data sheet in the EXCEL file and then have the pretty reporting sheet populate the values from that data sheet.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or produce the full report using your SAS program.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Mar 2022 22:26:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805403#M33484</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2022-03-31T22:26:26Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables count to another table</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805428#M33486</link>
      <description>In your code, does the count changes whenever the 3 tables are updated?. Please let me know. Thankyou.</description>
      <pubDate>Fri, 01 Apr 2022 04:22:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-count-to-another-table/m-p/805428#M33486</guid>
      <dc:creator>Pandu2</dc:creator>
      <dc:date>2022-04-01T04:22:47Z</dc:date>
    </item>
  </channel>
</rss>

