<?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: ODS OUTPUT &amp;amp; ODS WORD in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733371#M228526</link>
    <description>&lt;A href="https://communities.sas.com/t5/SAS-Communities-Library/Spanning-Headers-in-PROC-REPORT/ta-p/476002" target="_blank"&gt;https://communities.sas.com/t5/SAS-Communities-Library/Spanning-Headers-in-PROC-REPORT/ta-p/476002&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://support.sas.com/resources/papers/proceedings12/242-2012.pdf" target="_blank"&gt;https://support.sas.com/resources/papers/proceedings12/242-2012.pdf&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I highly recommend Art Carpenters book on PROC REPORT as a reference. It'll save you a lot of time in programming/googling.</description>
    <pubDate>Tue, 13 Apr 2021 16:02:53 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2021-04-13T16:02:53Z</dc:date>
    <item>
      <title>ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733360#M228521</link>
      <description>&lt;P&gt;I am exporting the results from PROC SURVEYFREQ by ODS OUTPUT and clean my data for a report. I copied the example tables below. I have 2 questions please:&lt;/P&gt;
&lt;P&gt;1- How may I merge the headings for the 95% CI in the ODS OUTPUT data?&lt;/P&gt;
&lt;P&gt;2- Using ODS WORD to create the report, each table appears on a separate page. How may I make a continuous report without breaking the page after each table?&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The output from PROC SURVEYFREQ:&lt;/P&gt;
&lt;TABLE width="461px"&gt;
&lt;THEAD&gt;
&lt;TR&gt;
&lt;TD colspan="5" width="460px"&gt;
&lt;P&gt;Table of AGE_GROUP&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="164px"&gt;
&lt;P&gt;AGE_GROUP&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="86.4px"&gt;
&lt;P&gt;Weighted&lt;BR /&gt;Frequency&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="66.4px"&gt;
&lt;P&gt;Percent&lt;/P&gt;
&lt;/TD&gt;
&lt;TD colspan="2" width="143.2px"&gt;
&lt;P&gt;&lt;FONT color="#339966"&gt;95% Confidence Limits&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;for Percent&lt;/FONT&gt;&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/THEAD&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="164px"&gt;
&lt;P&gt;10-15 years&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="86.4px"&gt;
&lt;P&gt;1260&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="66.4px"&gt;
&lt;P&gt;50.9&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="60.8px"&gt;
&lt;P&gt;48.3&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="82.4px"&gt;
&lt;P&gt;53.5&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="164px"&gt;
&lt;P&gt;16-20 years&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="86.4px"&gt;
&lt;P&gt;1216&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="66.4px"&gt;
&lt;P&gt;49.1&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="60.8px"&gt;
&lt;P&gt;46.5&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="82.4px"&gt;
&lt;P&gt;51.7&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="164px"&gt;
&lt;P&gt;Total&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="86.4px"&gt;
&lt;P&gt;2476&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="66.4px"&gt;
&lt;P&gt;100.0&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="60.8px"&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="82.4px"&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ODS OUTPUT sorted:&lt;/P&gt;
&lt;TABLE width="486"&gt;
&lt;THEAD&gt;
&lt;TR&gt;
&lt;TD width="54"&gt;Age group&lt;/TD&gt;
&lt;TD width="77"&gt;
&lt;P&gt;Frequency&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="61"&gt;
&lt;P&gt;Percent&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;&lt;FONT color="#339966"&gt;Lower_95_percent_CI&lt;/FONT&gt;&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;&lt;FONT color="#339966"&gt;Upper_95_percent_CI&lt;/FONT&gt;&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/THEAD&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="54"&gt;
&lt;P&gt;10-15 years&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="77"&gt;
&lt;P&gt;1260&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="61"&gt;
&lt;P&gt;50.9&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;48.3&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;53.5&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="54"&gt;
&lt;P&gt;16-20 years&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="77"&gt;
&lt;P&gt;1216&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="61"&gt;
&lt;P&gt;49.1&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;46.5&lt;/P&gt;
&lt;/TD&gt;
&lt;TD width="147"&gt;
&lt;P&gt;51.7&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Tue, 13 Apr 2021 15:25:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733360#M228521</guid>
      <dc:creator>Emma_at_SAS</dc:creator>
      <dc:date>2021-04-13T15:25:07Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733361#M228522</link>
      <description>Look at the STARTPAGE options in ODS WORD to control when a new page starts. &lt;BR /&gt;&lt;BR /&gt;Are you using PROC REPORT to print the first table? That would be the easiest way to have that span, though I'd consider pre-processing the field so your confidence interval shows as below and then use a single column via PROC PRINT. &lt;BR /&gt;&lt;BR /&gt;(48.3, 53.5)&lt;BR /&gt;&lt;BR /&gt;Or consider selectively piping the output directly to word rather than using the intermediary tables. Which doesn't work if you're re-ordering data and/or changing things massively. Rough example below:&lt;BR /&gt;&lt;BR /&gt;ods excel file='.....';&lt;BR /&gt;ods select summarytable;&lt;BR /&gt;proc surveyFREQ data=....;&lt;BR /&gt;&lt;BR /&gt;run;&lt;BR /&gt;ods excel close;</description>
      <pubDate>Tue, 13 Apr 2021 15:48:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733361#M228522</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-04-13T15:48:50Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733367#M228523</link>
      <description>&lt;P&gt;Thank you, Reeza. I will check the&amp;nbsp;&lt;SPAN&gt;STARTPAGE option for page breaks.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I used PROC PRINT to print the data I saved with PROC OUTPUT. What is the advantage of&amp;nbsp;PROC REPORT over PROC PRINT?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I keep your suggested example in mind for future use. For this project, I need to reorder the columns and eliminate the total row. So, I think this example does not work.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 15:55:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733367#M228523</guid>
      <dc:creator>Emma_at_SAS</dc:creator>
      <dc:date>2021-04-13T15:55:20Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733368#M228524</link>
      <description>PROC REPORT has more options for formatting and styling your columns and can do more types of calculations. PRINT is primarily used to just display information as is, typically without manipulating the structure. &lt;BR /&gt;&lt;BR /&gt;REPORT is PRINT on steroids and is incredibly powerful for creating almost any type of customized tables. If the column headers are always the same then getting spanning headers via PROC REPORT is trivial. I think you could trick it in PRINT by modifying the template or style to remove the line but REPORT is worth learning if you're going to be creating automated reports.</description>
      <pubDate>Tue, 13 Apr 2021 15:57:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733368#M228524</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-04-13T15:57:42Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733369#M228525</link>
      <description>&lt;P&gt;Thank you, Reeza. Yes, I am creating&amp;nbsp;&lt;SPAN&gt;automated reports and based on your explanation it sounds PROC REPORT would be a better option for me. I will switch to PROC REPORT.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 16:00:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733369#M228525</guid>
      <dc:creator>Emma_at_SAS</dc:creator>
      <dc:date>2021-04-13T16:00:30Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733371#M228526</link>
      <description>&lt;A href="https://communities.sas.com/t5/SAS-Communities-Library/Spanning-Headers-in-PROC-REPORT/ta-p/476002" target="_blank"&gt;https://communities.sas.com/t5/SAS-Communities-Library/Spanning-Headers-in-PROC-REPORT/ta-p/476002&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://support.sas.com/resources/papers/proceedings12/242-2012.pdf" target="_blank"&gt;https://support.sas.com/resources/papers/proceedings12/242-2012.pdf&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I highly recommend Art Carpenters book on PROC REPORT as a reference. It'll save you a lot of time in programming/googling.</description>
      <pubDate>Tue, 13 Apr 2021 16:02:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733371#M228526</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-04-13T16:02:53Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733372#M228527</link>
      <description>&lt;P&gt;Thanks for the resources, Reeza.&lt;/P&gt;
&lt;P&gt;I tried STARTPAGE="NO" but my small tables are still on separate pages. I think that controls columns of a table not separate tables! Any suggestions? Maybe I am doing that wrong!&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 16:06:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733372#M228527</guid>
      <dc:creator>Emma_at_SAS</dc:creator>
      <dc:date>2021-04-13T16:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733376#M228529</link>
      <description>Show your code please. It controls tables, definitely not columns on a table. &lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 13 Apr 2021 16:16:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733376#M228529</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-04-13T16:16:09Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT &amp; ODS WORD</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733377#M228530</link>
      <description>&lt;P&gt;Thanks, Reeza. Yes, you are right. I am not introducing the STARTPAGE option correctly.&amp;nbsp;STARTPAGE=NO asks for quotations and&amp;nbsp;STARTPAGE="NO" does not recognize the option.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ODS WORD FILE="C:\path\test.docx" options(STARTPAGE="NO");&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 13 Apr 2021 16:25:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ODS-OUTPUT-amp-ODS-WORD/m-p/733377#M228530</guid>
      <dc:creator>Emma_at_SAS</dc:creator>
      <dc:date>2021-04-13T16:25:04Z</dc:date>
    </item>
  </channel>
</rss>

