<?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: how to add a record into an empty dataset. And the values in this record are all missing in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294634#M61485</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;see ( if you need to preserve dataset label)
http://goo.gl/FvNbjT

Simplest?

proc sql;
  create table class like sashelp.class
;quit;

* unfortunately the dataset label is not preserved;

&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Sun, 28 Aug 2016 15:02:48 GMT</pubDate>
    <dc:creator>rogerjdeangelis</dc:creator>
    <dc:date>2016-08-28T15:02:48Z</dc:date>
    <item>
      <title>record are all missing</title>
      <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294551#M61455</link>
      <description />
      <pubDate>Sat, 27 Aug 2016 04:10:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294551#M61455</guid>
      <dc:creator>cecily</dc:creator>
      <dc:date>2016-08-27T04:10:00Z</dc:date>
    </item>
    <item>
      <title>Re: how to add a record into an empty dataset. And the values in this record are all missing</title>
      <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294560#M61461</link>
      <description>&lt;P&gt;Do you already have the empty dataset?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;untested but I would try something like the following:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data want;&lt;/P&gt;
&lt;P&gt;set want;&lt;/P&gt;
&lt;P&gt;call missing(_all_);&lt;/P&gt;
&lt;P&gt;output;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 27 Aug 2016 02:05:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294560#M61461</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-08-27T02:05:47Z</dc:date>
    </item>
    <item>
      <title>Re: how to add a record into an empty dataset. And the values in this record are all missing</title>
      <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294562#M61463</link>
      <description>&lt;P&gt;Get the variable names, but don't read the dataset as that will stop the data step before you can add a new record:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* Create an empty dataset */
data a;
length x y 8 r s t $12;
stop;
run;

/* Add a new record */
data b;
if 0 then set a; /* Get the var names, but don't read */
output;
stop;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 27 Aug 2016 02:19:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294562#M61463</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2016-08-27T02:19:46Z</dc:date>
    </item>
    <item>
      <title>Re: how to add a record into an empty dataset. And the values in this record are all missing</title>
      <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294634#M61485</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;see ( if you need to preserve dataset label)
http://goo.gl/FvNbjT

Simplest?

proc sql;
  create table class like sashelp.class
;quit;

* unfortunately the dataset label is not preserved;

&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 28 Aug 2016 15:02:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294634#M61485</guid>
      <dc:creator>rogerjdeangelis</dc:creator>
      <dc:date>2016-08-28T15:02:48Z</dc:date>
    </item>
    <item>
      <title>Re: how to add a record into an empty dataset. And the values in this record are all missing</title>
      <link>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294635#M61486</link>
      <description>&lt;P&gt;Ignore my previous post, I missunderstood the problem. My solution does not have one observation with missing values.&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 15:09:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/record-are-all-missing/m-p/294635#M61486</guid>
      <dc:creator>rogerjdeangelis</dc:creator>
      <dc:date>2016-08-28T15:09:46Z</dc:date>
    </item>
  </channel>
</rss>

