<?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: Multisheet excel export column width specification in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Multisheet-excel-export-column-width-specification/m-p/406199#M26087</link>
    <description>&lt;P&gt;PROC EXPORT doesn't allow you to control the column width or the presentation. For that you need to use either ODS Excel or ODS Tagsets.ExcelXP.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/sgf/2017/02/20/tips-for-using-the-ods-excel-destination/" target="_blank"&gt;https://blogs.sas.com/content/sgf/2017/02/20/tips-for-using-the-ods-excel-destination/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Most ODS TAGSETS things are relevant to ODS EXCEL as well. Unfortunately this isn't a straight forward as change a setting, but it's not super complicated either.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 21 Oct 2017 01:24:44 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2017-10-21T01:24:44Z</dc:date>
    <item>
      <title>Multisheet excel export column width specification</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Multisheet-excel-export-column-width-specification/m-p/406198#M26086</link>
      <description>&lt;P&gt;I am exporting a data set into their own separate multisheet excel file in SAS EG 6.1. I would like to have the columns in the sheets either auto width based on cell values or specify the width. From what I have found, I believe I need to use an ODS tagset.EXCELXP but I'm not entirely sure how to accomplish this.&amp;nbsp; Below is the program I have been using to export. What do I need to add to adjust the columns?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;PROC&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; TABLE_ONE &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;SELECT&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;ELEMENT_ONE,&lt;/P&gt;&lt;P&gt;ELEMENT_TWO,&lt;/P&gt;&lt;P&gt;ELEMENT_THREE,&lt;/P&gt;&lt;P&gt;IDENTIFIER&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; WORK.QUERY_FOR_APPEND_TABLE_01;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;QUIT&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;PROC&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; TABLE_TWO &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;SELECT&lt;/P&gt;&lt;P&gt;ELEMENT_FOUR,&lt;/P&gt;&lt;P&gt;ELEMENT_FIVE,&lt;/P&gt;&lt;P&gt;IDENTIFIER&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; WORK.QUERY_FOR_APPEND_TABLE_02;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;QUIT&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;PROC&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; TABLE_THREE &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;SELECT&lt;/P&gt;&lt;P&gt;ELEMENT_SIX,&lt;/P&gt;&lt;P&gt;ELEMENT_SEVEN,&lt;/P&gt;&lt;P&gt;ELEMENT_EIGHT,&lt;/P&gt;&lt;P&gt;ELEMENT_NINE,&lt;/P&gt;&lt;P&gt;IDENTIFIER&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; WORK.QUERY_FOR_APPEND_TABLE_03;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;QUIT&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;%macro&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &lt;STRONG&gt;&lt;I&gt;multisheet&lt;/I&gt;&lt;/STRONG&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;proc sql noprint;&lt;/P&gt;&lt;P&gt;select distinct IDENTIFIER&lt;/P&gt;&lt;P&gt;into :IDENTIFIER1 - :IDENTIFIER92&lt;/P&gt;&lt;P&gt;from TABLE_ONE;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; leacnt = &amp;amp;sqlobs;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; now1=&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%sysfunc&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(today(),yymmddn8.);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%do&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; i = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%to&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; &amp;amp;leacnt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;PROC EXPORT DATA = TABLE_ONE(where=(IDENTIFIER=&amp;amp;&amp;amp;IDENTIFIER&amp;amp;i))&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;OUTFILE=&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"OUTPUT_FILE_&amp;amp;IDENTIFIER&amp;amp;i.._&amp;amp;now1;.xls"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;DBMS= excelcs REPLACE; PORT=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0000&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; server=XXXX;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sheet = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"TABLE_ONE"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;RUN;&lt;/P&gt;&lt;P&gt;PROC EXPORT DATA = TABLE_TWO(where=(IDENTIFIER=&amp;amp;&amp;amp;IDENTIFIER&amp;amp;i))&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;OUTFILE=&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"OUTPUT_FILE_&amp;amp;IDENTIFIER&amp;amp;i.._&amp;amp;now1;.xls"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;DBMS= excelcs REPLACE; PORT=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0000&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; server=XXXX;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sheet = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"TABLE_TWO"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;RUN;&lt;/P&gt;&lt;P&gt;PROC EXPORT DATA = TABLE_THREE(where=(IDENTIFIER=&amp;amp;&amp;amp;IDENTIFIER&amp;amp;i))&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;OUTFILE=&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"OUTPUT_FILE_&amp;amp;IDENTIFIER&amp;amp;i.._&amp;amp;now1;.xls"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;DBMS= excelcs REPLACE; PORT=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0000&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; server=XXXX;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sheet = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"TABLE_THREE"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;RUN;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%END&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;%mend&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; multisheet;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;%&lt;STRONG&gt;&lt;I&gt;multisheet&lt;/I&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 01:20:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Multisheet-excel-export-column-width-specification/m-p/406198#M26086</guid>
      <dc:creator>User01</dc:creator>
      <dc:date>2017-10-21T01:20:10Z</dc:date>
    </item>
    <item>
      <title>Re: Multisheet excel export column width specification</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Multisheet-excel-export-column-width-specification/m-p/406199#M26087</link>
      <description>&lt;P&gt;PROC EXPORT doesn't allow you to control the column width or the presentation. For that you need to use either ODS Excel or ODS Tagsets.ExcelXP.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/sgf/2017/02/20/tips-for-using-the-ods-excel-destination/" target="_blank"&gt;https://blogs.sas.com/content/sgf/2017/02/20/tips-for-using-the-ods-excel-destination/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Most ODS TAGSETS things are relevant to ODS EXCEL as well. Unfortunately this isn't a straight forward as change a setting, but it's not super complicated either.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 01:24:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Multisheet-excel-export-column-width-specification/m-p/406199#M26087</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2017-10-21T01:24:44Z</dc:date>
    </item>
  </channel>
</rss>

