<?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: SAS Export in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260165#M269041</link>
    <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15410"&gt;@data_null__﻿&lt;/a&gt;&amp;nbsp; Can you explain how DOW WHILE (1) is working and what is _name_ variable?&lt;/P&gt;</description>
    <pubDate>Wed, 30 Mar 2016 17:23:37 GMT</pubDate>
    <dc:creator>SAS_inquisitive</dc:creator>
    <dc:date>2016-03-30T17:23:37Z</dc:date>
    <item>
      <title>SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260115#M269036</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I use enterprise guide (for coding not point and click) and I was looking to export a large dataset into a CSV file.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was going to use a proc export as I need to use the delimiter '|'. An issue I have is I want all the character variables to be output within double quotations (" ") and the numeric/date variables to be output without them.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a quick way of achieving this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2016 14:31:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260115#M269036</guid>
      <dc:creator>mk131190</dc:creator>
      <dc:date>2016-03-30T14:31:28Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260122#M269037</link>
      <description>&lt;P&gt;Try this, I did not make the name row.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;40         data _null_;
41            set sashelp.class;
42            file log dlm='|';
43            put (_all_)(:);
44            format _character_ $quote128.;
45            run;

"Alfred"|"M"|14|69|112.5
"Alice"|"F"|13|56.5|84
"Barbara"|"F"|13|65.3|98
"Carol"|"F"|14|62.8|102.5
"Henry"|"M"|14|63.5|102.5
"James"|"M"|12|57.3|83
"Jane"|"F"|12|59.8|84.5
"Janet"|"F"|15|62.5|112.5
"Jeffrey"|"M"|13|62.5|84
"John"|"M"|12|59|99.5
"Joyce"|"F"|11|51.3|50.5
"Judy"|"F"|14|64.3|90
"Louise"|"F"|12|56.3|77
"Mary"|"F"|15|66.5|112
"Philip"|"M"|16|72|150
"Robert"|"M"|12|64.8|128
"Ronald"|"M"|15|67|133
"Thomas"|"M"|11|57.5|85
"William"|"M"|15|66.5|112&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 30 Mar 2016 14:39:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260122#M269037</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-03-30T14:39:33Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260134#M269038</link>
      <description>&lt;P&gt;I added NAME row not quote. &amp;nbsp;Notice that the absence of DSD will make that slightly different from PROC EXPORT. &amp;nbsp;But with DSD the quotes are doubled and double quoted.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;40         data _null_;
41            set sashelp.heart(obs=50);
42            file log dlm='|' ls=256;
43            if _n_ eq 1 then link names;
44            put (_all_)(:);
45            format _character_ $quote128.;
46            return;
47         names:
48            length _name_ $32;
49            do while(1);
50               call vnext(_name_);
51               if upcase(_name_) eq '_NAME_' then leave;
52               put _name_ @;
53               end;
54            put;
55            run;


Status|DeathCause|AgeCHDdiag|Sex|AgeAtStart|Height|Weight|Diastolic|Systolic|MRW|Smoking|AgeAtDeath|Cholesterol|Chol_Status|BP_Status|Weight_Status|Smoking_Status
"Dead"|"Other"|.|"Female"|29|62.5|140|78|124|121|0|55|.|""|"Normal"|"Overweight"|"Non-smoker"
"Dead"|"Cancer"|.|"Female"|41|59.75|194|92|144|183|0|57|181|"Desirable"|"High"|"Overweight"|"Non-smoker"
"Alive"|""|.|"Female"|57|62.25|132|90|170|114|10|.|250|"High"|"High"|"Overweight"|"Moderate (6-15)"
"Alive"|""|.|"Female"|39|65.75|158|80|128|123|0|.|242|"High"|"Normal"|"Overweight"|"Non-smoker"
"Alive"|""|.|"Male"|42|66|156|76|110|116|20|.|281|"High"|"Optimal"|"Overweight"|"Heavy (16-25)"
"Alive"|""|.|"Female"|58|61.75|131|92|176|117|0|.|196|"Desirable"|"High"|"Overweight"|"Non-smoker"
"Alive"|""|.|"Female"|36|64.75|136|80|112|110|15|.|196|"Desirable"|"Normal"|"Overweight"|"Moderate (6-15)"
"Dead"|"Other"|.|"Male"|53|65.5|130|80|114|99|0|77|276|"High"|"Normal"|"Normal"|"Non-smoker"
"Alive"|""|.|"Male"|35|71|194|68|132|124|0|.|211|"Borderline"|"Normal"|"Overweight"|"Non-smoker"&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 30 Mar 2016 15:06:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260134#M269038</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-03-30T15:06:56Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260139#M269039</link>
      <description>My character variables are coming out "" ""|"" ""&lt;BR /&gt;&lt;BR /&gt;Is there a reason why they are in 2 lots of double quotes?</description>
      <pubDate>Wed, 30 Mar 2016 15:38:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260139#M269039</guid>
      <dc:creator>mk131190</dc:creator>
      <dc:date>2016-03-30T15:38:54Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260141#M269040</link>
      <description>&lt;P&gt;If you used DSD option that will cause it. &amp;nbsp;Show your program.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2016 15:41:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260141#M269040</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-03-30T15:41:56Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260165#M269041</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15410"&gt;@data_null__﻿&lt;/a&gt;&amp;nbsp; Can you explain how DOW WHILE (1) is working and what is _name_ variable?&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2016 17:23:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260165#M269041</guid>
      <dc:creator>SAS_inquisitive</dc:creator>
      <dc:date>2016-03-30T17:23:37Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Export</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260168#M269042</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/64404"&gt;@SAS_inquisitive﻿&lt;/a&gt;&amp;nbsp;DO WHILE(1); is infinite loop. &amp;nbsp;Notice the LEAVE statement to exit.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;_NAME_ is the value returned from CALL VNEXT. &amp;nbsp;It is the name of a variable from the PDV.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Each time VNEXT is executed it returns the "next" variable in the PDV. &amp;nbsp;It provides a way to iterate across the PDV. &amp;nbsp;It will also return the length and type of the variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In some other languages it might be writen using FOR statement a list iterator.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;for NAME in PDV do
   end&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2016 17:32:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Export/m-p/260168#M269042</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-03-30T17:32:40Z</dc:date>
    </item>
  </channel>
</rss>

