<?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: macro to export dataset into excel file : a blank at end in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452534#M114227</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/147725"&gt;@Nasser_DRMCP&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  format REF_CTR_EXI $15. DAT_DBL_ANCIEN date10. ;
  RUN ;
ODS TAGSETS.EXCELXP CLOSE ;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not shure to use a really recent version 7.1 (7.100.0.1966) (64-bit)&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;by doing that it takes also a long time&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Tagsets.excelxp writes uncompressed xml, so the resulting file can become&amp;nbsp;&lt;EM&gt;very&lt;/EM&gt; large. How many observations do you have in your dataset?&lt;/P&gt;
&lt;P&gt;If you just need to export &lt;EM&gt;values&lt;/EM&gt;&amp;nbsp;to Excel, a csv file is a much better means.&lt;/P&gt;</description>
    <pubDate>Mon, 09 Apr 2018 15:51:05 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2018-04-09T15:51:05Z</dc:date>
    <item>
      <title>macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452457#M114190</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%macro export_sas_v2(folder_out=,fichier=,version=);

PROC CONTENTS DATA = &amp;amp;fichier.
OUT = work.dictionnaire
NOPRINT ;
RUN ;

PROC SQL noprint ;
	SELECT COMPBL(name!!
		CASE
			WHEN (type=1 AND
			format IS MISSING)
			THEN " NUMX15.2 "
		WHEN (type=1) THEN " "!!
		COMPRESS(cats(format,formatL,".",formatD," "))
		ELSE ""
		END)
		,
	QUOTE(LEFT(TRIM(COALESCE(label,name)))),
		COUNT(*),
		MAX(nobs)+1
	INTO : variables SEPARATED BY " '09'x ",
		: en_tete SEPARATED BY " '09'x ",
		: nbVar ,
		: nbObs
	FROM work.dictionnaire
		ORDER BY varnum
	;
Quit;

FILENAME xlData "&amp;amp;folder_out.&amp;amp;fichier.&amp;amp;version..xls";

DATA _NULL_ ;
FILE xlData DROPOVER lrecl=50000  encoding= 'WE8MSWIN1252' ;
SET &amp;amp;fichier. ;

IF _N_ = 1 THEN PUT &amp;amp;en_tete ;
PUT &amp;amp;variables ;

RUN ;


%mend export_sas_v2 ;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Apr 2018 10:22:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452457#M114190</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T10:22:15Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452461#M114192</link>
      <description>&lt;P&gt;Why?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What do you hope to achieve that:&lt;BR /&gt;proc export&lt;/P&gt;
&lt;P&gt;tagsets.excelxp / tagsets.excel&lt;/P&gt;
&lt;P&gt;ods csv&lt;/P&gt;
&lt;P&gt;html output&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does not cover?&amp;nbsp; Your just creating work for yourself as at a guess your actually creating a tab delimited file.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 10:47:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452461#M114192</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-04-09T10:47:52Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452464#M114195</link>
      <description>&lt;P&gt;You are of course aware that you are lying by naming your file .xls. It is in fact a tab-separated &lt;EM&gt;text&lt;/EM&gt; file and should be named .txt.&lt;/P&gt;
&lt;P&gt;Newer versions of Excel will always complain when you open such a file with a wrong extension.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And why so complicated?&lt;/P&gt;
&lt;P&gt;Let SAS handle most of the tab-separation:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%macro export_sas_v2(folder_out=,fichier=,version=);

PROC CONTENTS DATA = &amp;amp;fichier.
OUT = work.dictionnaire
NOPRINT ;
RUN ;

PROC SQL noprint ;
	SELECT COMPBL(name!!
		CASE
			WHEN (type=1 AND
			format IS MISSING)
			THEN " NUMX15.2 "
		WHEN (type=1) THEN " "!!
		COMPRESS(cats(format,formatL,".",formatD," "))
		ELSE ""
		END)
		,
	LEFT(TRIM(COALESCE(label,name))),
	COUNT(*),
	MAX(nobs)+1
	INTO : variables SEPARATED BY " ",
		: en_tete SEPARATED BY '09'x,
		: nbVar ,
		: nbObs
	FROM work.dictionnaire
		ORDER BY varnum
	;
Quit;

FILENAME xlData "&amp;amp;folder_out.&amp;amp;fichier.&amp;amp;version..txt";

DATA _NULL_ ;
FILE xlData DROPOVER lrecl=50000 dlm='09'x encoding= 'WE8MSWIN1252' ;
SET &amp;amp;fichier. ;

IF _N_ = 1 THEN PUT "&amp;amp;en_tete" ;
PUT &amp;amp;variables ;

RUN ;


%mend export_sas_v2 ;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Apr 2018 11:01:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452464#M114195</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-04-09T11:01:01Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452479#M114197</link>
      <description>&lt;P&gt;thanks for your quick response&lt;/P&gt;&lt;P&gt;by doing that I get the attended result&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;ODS TAGSETS.EXCELXP FILE = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"&amp;amp;xlsfile."&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; style=normal ;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;PROC PRINT DATA = &amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;tdb_mens.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;RUN ;&lt;/P&gt;&lt;P&gt;ODS HTML CLOSE ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 12:20:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452479#M114197</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T12:20:56Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452482#M114200</link>
      <description>&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; xlsfile = &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%str&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(%')&amp;amp;repwork.&amp;amp;tdb_mens..xml&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%str&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(%') ;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 12:31:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452482#M114200</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T12:31:28Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452484#M114202</link>
      <description>&lt;P&gt;Sorry, I am not following what it is your trying to say? What I can tell you is this:&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3" color="#0000ff"&gt;%Let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;xlsfile =&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3" color="#0000ff"&gt;%str&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(%')&amp;amp;repwork.&amp;amp;tdb_mens..xml&lt;/FONT&gt;&lt;FONT face="Courier New" size="3" color="#0000ff"&gt;%str&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(%') ;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;Will result in the following code, which I don't expect is what you wanted:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;ODS TAGSETS.EXCELXP FILE =&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3" color="#800080"&gt;"&lt;FONT face="Courier New" size="3"&gt;'......._mens..xml'&lt;/FONT&gt;"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;style=normal ;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I.e. with single quotes around it.&amp;nbsp; It is never a good idea to put quotes in a macro variable,&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3" color="#0000ff"&gt;%Let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;xlsfile =&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&amp;amp;repwork.&amp;amp;tdb_mens..xml&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;I would avoid coding in mixed or all upper case, it makes code harder to read.&amp;nbsp; And use code windows for posting code - its the {i} above post area.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 12:48:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452484#M114202</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-04-09T12:48:35Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452516#M114211</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;%Let xlsfile = &amp;amp;repwork.&amp;amp;tdb_mens..xml ;

ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  RUN ;
ODS HTML CLOSE ;&lt;/PRE&gt;&lt;P&gt;Thanks RW for your help.&lt;/P&gt;&lt;P&gt;I am trying to export a dataset into a flat file wich can be directly opened with excel.&amp;nbsp; by using ODS TAGSET. the proc "print" seems correct but it takes many elapsed time. SO I do not have the solution yet&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:04:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452516#M114211</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T15:04:03Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452518#M114215</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/147725"&gt;@Nasser_DRMCP&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;thanks for your quick response&lt;/P&gt;
&lt;P&gt;by doing that I get the attended result&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;ODS TAGSETS.EXCELXP FILE = &lt;/FONT&gt;&lt;FONT face="Courier New" size="3" color="#800080"&gt;"&amp;amp;xlsfile."&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; style=normal ; &lt;FONT color="#FF0000"&gt;*&amp;lt;- THis is ODS TAGSETS;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;PROC PRINT DATA = &amp;amp;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3" color="#008080"&gt;tdb_mens.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RUN ;&lt;/P&gt;
&lt;P&gt;ODS HTML CLOSE ; &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;*This should also be ODS TAGSETS.EXCELXP&lt;/STRONG&gt;&lt;/FONT&gt;;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;If you want an XLSX file, use ODS EXCEL (SAS 9.4M3+), otherwise this generates an XML file.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:11:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452518#M114215</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-09T15:11:48Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452525#M114221</link>
      <description>&lt;P&gt;It is not suprising it runs forever, you have opened ods tagsets.excelxp and never closed it!&lt;/P&gt;
&lt;PRE&gt;%Let xlsfile = &amp;amp;repwork.&amp;amp;tdb_mens..xml ;

ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  RUN ;
ODS tagsets.excelxp CLOSE ;&lt;/PRE&gt;
&lt;P&gt;As&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13879"&gt;@Reeza&lt;/a&gt;&amp;nbsp;states you can also use Excel to create files if you have a recent version of SAS, as that creates actual Excel files.&amp;nbsp; If you want plain text file, then ods csv.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:26:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452525#M114221</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-04-09T15:26:12Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452532#M114226</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  format REF_CTR_EXI $15. DAT_DBL_ANCIEN date10. ;
  RUN ;
ODS TAGSETS.EXCELXP CLOSE ;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not shure to use a really recent version 7.1 (7.100.0.1966) (64-bit)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;by doing that it takes also a long time&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:46:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452532#M114226</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T15:46:08Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452534#M114227</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/147725"&gt;@Nasser_DRMCP&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  format REF_CTR_EXI $15. DAT_DBL_ANCIEN date10. ;
  RUN ;
ODS TAGSETS.EXCELXP CLOSE ;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not shure to use a really recent version 7.1 (7.100.0.1966) (64-bit)&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;by doing that it takes also a long time&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Tagsets.excelxp writes uncompressed xml, so the resulting file can become&amp;nbsp;&lt;EM&gt;very&lt;/EM&gt; large. How many observations do you have in your dataset?&lt;/P&gt;
&lt;P&gt;If you just need to export &lt;EM&gt;values&lt;/EM&gt;&amp;nbsp;to Excel, a csv file is a much better means.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:51:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452534#M114227</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-04-09T15:51:05Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452535#M114228</link>
      <description>&lt;P&gt;Yes, it's slower, especially compared to a PROC EXPORT. Is there a reason you're not using a regular PROC EXPORT instead? I"m not seeing anything that precludes the usage, so as long as you have the SAS Access to PC FILES license it's likely the fastest method.&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/147725"&gt;@Nasser_DRMCP&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ODS TAGSETS.EXCELXP FILE = "&amp;amp;xlsfile."  style=normal  ;
  PROC PRINT DATA = &amp;amp;tdb_mens. ;
  format REF_CTR_EXI $15. DAT_DBL_ANCIEN date10. ;
  RUN ;
ODS TAGSETS.EXCELXP CLOSE ;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not shure to use a really recent version 7.1 (7.100.0.1966) (64-bit)&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;by doing that it takes also a long time&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 15:52:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452535#M114228</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-09T15:52:57Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452541#M114229</link>
      <description>&lt;P&gt;17 000 observ in the dataset&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:02:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452541#M114229</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T16:02:54Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452543#M114230</link>
      <description>&lt;P&gt;Yes Kurt. I just need to export values to Excel.&lt;/P&gt;&lt;P&gt;even if try with csv extension, it takes also a long time&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; xlsfile = &amp;amp;repwork.&amp;amp;tdb_mens..csv ;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:06:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452543#M114230</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T16:06:17Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452544#M114231</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc export data=sashelp.cars outfile="temp.xlsx" dbms=xlsx replace ; run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;What about a straight PROC EXPORT then?&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:09:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452544#M114231</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-09T16:09:25Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452546#M114232</link>
      <description>&lt;P&gt;the required module is not installed. by trying the proc export ,&amp;nbsp;the log says this:&lt;/P&gt;&lt;P&gt;The SAS/ACCESS Interface to PC Files is not installed. Please install this module in order to IMPORT/EXPORT to these file types.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:23:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452546#M114232</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T16:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452549#M114233</link>
      <description>&lt;P&gt;Ah...so in this case you're company was use DDE to get around not purchasing a license - I'm not sure why, the module saves enough time to make it worth it.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anyways, then the fastest method is&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/11562"&gt;@Kurt_Bremser&lt;/a&gt;&amp;nbsp;solution, export (using proc export) to a CSV file instead.&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc export data=sashelp.cars outfile='test.csv' dbms=csv replace; run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Unfortunately using ODS is slower, but you don't really have a workaround if you don't have the license.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you really want an XLSX file, then ODS EXCEL is the next best option:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods excel file='demo.xlsx' style=meadow;

proc print data=sashelp.cars noobs label;
run;

ods excel close;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:26:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452549#M114233</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-09T16:26:19Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452550#M114234</link>
      <description>&lt;P&gt;Thanks reeza&lt;/P&gt;&lt;P&gt;I try your suggestion but...&lt;/P&gt;&lt;P&gt;ERROR: Unable to load module 'SpreadsheetML' from template store!&lt;/P&gt;&lt;P&gt;ERROR: No body file. EXCEL output will not be created&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:30:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452550#M114234</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T16:30:20Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452551#M114235</link>
      <description>&lt;P&gt;Post your exact code and log from the code with errors. I'm assuming you updated the path to be something that would work for you?&lt;/P&gt;
&lt;P&gt;You may not have ODS EXCEL, run the following to see your SAS version (you've been providing your EG version which can vary).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc product_status;run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:32:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452551#M114235</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-09T16:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: macro to export dataset into excel file : a blank at end</title>
      <link>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452552#M114236</link>
      <description>&lt;P&gt;For Base SAS Software ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3_M2&lt;/P&gt;&lt;P&gt;Image version information: 9.03.01M2P080112&lt;/P&gt;&lt;P&gt;For SAS/STAT ...&lt;/P&gt;&lt;P&gt;Custom version information: 12.1&lt;/P&gt;&lt;P&gt;Image version information: 9.03.01M0P081512&lt;/P&gt;&lt;P&gt;For SAS/GRAPH ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3_M2&lt;/P&gt;&lt;P&gt;For SAS Integration Technologies ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3_M2&lt;/P&gt;&lt;P&gt;For SAS/ACCESS Interface to Oracle ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3_M1&lt;/P&gt;&lt;P&gt;For SAS/ACCESS Interface to ODBC ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3_M2&lt;/P&gt;&lt;P&gt;For SAS/ACCESS Interface to Netezza ...&lt;/P&gt;&lt;P&gt;Custom version information: 9.3&lt;/P&gt;&lt;P&gt;Image version information: 9.03.01M0P051111&lt;/P&gt;</description>
      <pubDate>Mon, 09 Apr 2018 16:36:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/macro-to-export-dataset-into-excel-file-a-blank-at-end/m-p/452552#M114236</guid>
      <dc:creator>Nasser_DRMCP</dc:creator>
      <dc:date>2018-04-09T16:36:26Z</dc:date>
    </item>
  </channel>
</rss>

