<?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: can we keep/drop a variable without reading the the dataset. in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72801#M15683</link>
    <description>Hi patrik, &lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&amp;gt; data want;&lt;BR /&gt;
&amp;gt;   infile datalines dsd truncover;&lt;BR /&gt;
&amp;gt; length id ValuePair_Cnt 8;&lt;BR /&gt;
&amp;gt;   input id N_ValuePairs Col_Ind @;&lt;BR /&gt;
&amp;gt; do ValuePair_Cnt=1 to N_ValuePairs;&lt;BR /&gt;
&amp;gt;     input x y @;&lt;BR /&gt;
&amp;gt; output;&lt;BR /&gt;
&amp;gt;   end;&lt;BR /&gt;
&amp;gt; talines;&lt;BR /&gt;
&amp;gt; 1, 2,23,4,5,24,6,7&lt;BR /&gt;
&amp;gt; 2, 3, 234,2,6,712,8,4,1025,10,3&lt;BR /&gt;
 &amp;gt; ;&lt;BR /&gt;
&amp;gt; run;&lt;BR /&gt;
&amp;gt; &lt;BR /&gt;
&lt;BR /&gt;
In your code you read col_ind only once ...&lt;BR /&gt;
but  after reading fist x,y  the col_ind changes&lt;BR /&gt;
&lt;BR /&gt;
eg..   &lt;BR /&gt;
for 1st obs   .... its 1st ... 23 then 24&lt;BR /&gt;
for 2nd obs ... its 234, 712, 1025...&lt;BR /&gt;
&lt;BR /&gt;
I can place col_ind like this ...&lt;BR /&gt;
&lt;BR /&gt;
input col_ind x y @;&lt;BR /&gt;
output;&lt;BR /&gt;
&lt;BR /&gt;
but this approach is not suitable for me as the id  should be unique per row. &lt;BR /&gt;
&lt;BR /&gt;
thanks &lt;BR /&gt;
&lt;BR /&gt;
regards,&lt;BR /&gt;
Avi</description>
    <pubDate>Fri, 02 Apr 2010 09:32:55 GMT</pubDate>
    <dc:creator>deleted_user</dc:creator>
    <dc:date>2010-04-02T09:32:55Z</dc:date>
    <item>
      <title>can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72791#M15673</link>
      <description>can we drop a variable without reading the the dataset?&lt;BR /&gt;
&lt;BR /&gt;
just like we can rename it in proc datasets...&lt;BR /&gt;
&lt;BR /&gt;
my dataset is just too huge ... &lt;BR /&gt;
i am creating a dataset using array , it can have x_1 - x_2000 columns. &lt;BR /&gt;
but not every the time all columns are populated. &lt;BR /&gt;
i have to drop columns which are not populated.&lt;BR /&gt;
i can maintain a list of the index of column which are populated in a macro variable.&lt;BR /&gt;
&lt;BR /&gt;
i have too do this keep drop operation in other datasteps.&lt;BR /&gt;
it also takes too much of time. i want to save that time.&lt;BR /&gt;
&lt;BR /&gt;
thanks in advance&lt;BR /&gt;
&lt;BR /&gt;
Regards&lt;BR /&gt;
Avi

Message was edited by: Avi</description>
      <pubDate>Wed, 31 Mar 2010 14:59:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72791#M15673</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-03-31T14:59:06Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72792#M15674</link>
      <description>Not possible.  But with a DATA step and most PROCs, do consider the KEEP= and DROP= dataset options (DATA or SET stmt or DATA= or OUT= with PROCs) for altering your SAS file either on input or output depending on your circumstances and requirements.&lt;BR /&gt;
&lt;BR /&gt;
COMMENT: Suggest you investigate using SAS VIEWs and possibly the INDEX, depending on your data-volume and processing requirements, as an alternative, where suitable.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.&lt;BR /&gt;
&lt;BR /&gt;
Suggested Google advanced search argument, this topic/post:&lt;BR /&gt;
how to drop variable site:sas.com</description>
      <pubDate>Wed, 31 Mar 2010 16:11:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72792#M15674</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2010-03-31T16:11:42Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72793#M15675</link>
      <description>If a data is permanent, you can create a view using keep/drop statement.&lt;BR /&gt;
&lt;BR /&gt;
If a data is temporary, don't bother using extra step and eliminating empty variables.</description>
      <pubDate>Thu, 01 Apr 2010 12:07:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72793#M15675</guid>
      <dc:creator>SAS_user</dc:creator>
      <dc:date>2010-04-01T12:07:13Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72794#M15676</link>
      <description>You could PROC SQL; ALTER TABLE statement&lt;BR /&gt;
&lt;BR /&gt;
see the documentation linked here&lt;BR /&gt;
&lt;A href="http://support.sas.com/documentation/cdl/en/proc/61895/HTML/default/a002473671.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/proc/61895/HTML/default/a002473671.htm&lt;/A&gt;&lt;BR /&gt;
See below for a code example&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
proc sql;&lt;BR /&gt;
  create table work.shoes as&lt;BR /&gt;
    select * &lt;BR /&gt;
	from sashelp.shoes;&lt;BR /&gt;
quit;&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
proc sql;&lt;BR /&gt;
  alter table work.shoes&lt;BR /&gt;
    drop inventory;&lt;BR /&gt;
quit;&lt;BR /&gt;
&lt;BR /&gt;
proc sql;&lt;BR /&gt;
  select *&lt;BR /&gt;
  from work.shoes;&lt;BR /&gt;
quit;</description>
      <pubDate>Thu, 01 Apr 2010 12:15:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72794#M15676</guid>
      <dc:creator>darrylovia</dc:creator>
      <dc:date>2010-04-01T12:15:43Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72795#M15677</link>
      <description>hi all ,&lt;BR /&gt;
Thanks of the reply ... Alter table is a good option .&lt;BR /&gt;
&lt;BR /&gt;
regards,&lt;BR /&gt;
Avi</description>
      <pubDate>Thu, 01 Apr 2010 12:58:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72795#M15677</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-04-01T12:58:11Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72796#M15678</link>
      <description>I think that the PROC SQL ALTER statement still re-writes the data set, it just does it in the background.  The documentation is not specific, but you can test it easily enough, by looking to see if there is a change in the size of the dataset through PROC CONTENTS.&lt;BR /&gt;
&lt;BR /&gt;
I tend to agree with Steve, you are SOL on this one.</description>
      <pubDate>Thu, 01 Apr 2010 14:11:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72796#M15678</guid>
      <dc:creator>Doc_Duke</dc:creator>
      <dc:date>2010-04-01T14:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72797#M15679</link>
      <description>I'm afraid that Doc is correct I ran an experiment comparing a data step vs. proc sql.  The PROC SQL ALTER didnot even complete.&lt;BR /&gt;
&lt;BR /&gt;
I created a table 2K columns 1M rows. &lt;BR /&gt;
&lt;BR /&gt;
See the SAS log for the details&lt;BR /&gt;
&lt;BR /&gt;
16         &lt;BR /&gt;
17         data bigdata;&lt;BR /&gt;
18         &lt;BR /&gt;
19           array num(2000);&lt;BR /&gt;
20         &lt;BR /&gt;
21           do i=1 to 2000;&lt;BR /&gt;
22             num&lt;I&gt;=ranuni(i);&lt;BR /&gt;
23           end;&lt;BR /&gt;
24         &lt;BR /&gt;
25         &lt;BR /&gt;
26           do j=1 to 1000000;&lt;BR /&gt;
27             output;&lt;BR /&gt;
28           end;&lt;BR /&gt;
29         run;&lt;BR /&gt;
&lt;BR /&gt;
NOTE: The data set WORK.BIGDATA has 1000000 observations and 2002 variables.&lt;BR /&gt;
NOTE: DATA statement used (Total process time):&lt;BR /&gt;
      real time           6:19.66&lt;BR /&gt;
      cpu time            3:50.78&lt;BR /&gt;
      &lt;BR /&gt;
&lt;BR /&gt;
30         &lt;BR /&gt;
31         data bigdata2;&lt;BR /&gt;
32           set bigdata (drop=i j);&lt;BR /&gt;
33         run;&lt;BR /&gt;
&lt;BR /&gt;
NOTE: DATA statement used (Total process time):&lt;BR /&gt;
      real time           16:57.68&lt;BR /&gt;
      cpu time            5:55.24&lt;BR /&gt;
      &lt;BR /&gt;
NOTE: There were 1000000 observations read from the data set WORK.BIGDATA.&lt;BR /&gt;
2                                        The SAS System            09:56 Thursday, April 1, 2010&lt;BR /&gt;
&lt;BR /&gt;
NOTE: The data set WORK.BIGDATA2 has 1000000 observations and 2000 variables.&lt;BR /&gt;
&lt;BR /&gt;
34         &lt;BR /&gt;
35         proc sql;&lt;BR /&gt;
36           alter table bigdata&lt;BR /&gt;
37             drop i ,j;&lt;BR /&gt;
ERROR: Write to WORK.BIGDATA.DATA failed. File is full and may be damaged.&lt;BR /&gt;
ERROR: The table WORK.BIGDATA was not altered due to an error condition.&lt;BR /&gt;
NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements.&lt;BR /&gt;
38         quit;&lt;BR /&gt;
NOTE: The SAS System stopped processing this step because of errors.&lt;BR /&gt;
NOTE: PROCEDURE SQL used (Total process time):&lt;BR /&gt;
      real time           12:54.35&lt;BR /&gt;
      cpu time            4:11.15&lt;/I&gt;</description>
      <pubDate>Thu, 01 Apr 2010 16:53:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72797#M15679</guid>
      <dc:creator>darrylovia</dc:creator>
      <dc:date>2010-04-01T16:53:31Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72798#M15680</link>
      <description>Avi&lt;BR /&gt;
&lt;BR /&gt;
I believe Scott is just right: "Not possible".&lt;BR /&gt;
&lt;BR /&gt;
If one thinks how native SAS data is stored (descriptor part, data part) then it also makes sense that deleting a variable means processing the data, deleting every single value and re-organising the data (http://support.sas.com/onlinedoc/913/getDoc/en/lrcon.hlp/a000776576.htm).&lt;BR /&gt;
&lt;BR /&gt;
For the same reason renaming a variable is quick as this needs only a change in the descriptor part of the SAS data set.&lt;BR /&gt;
&lt;BR /&gt;
As space seems to be the issue for you: Make sure you're using the data set option:  options compress=yes;  - or: data a (compress=yes);&lt;BR /&gt;
&lt;BR /&gt;
It also might help to get more disk space or alternatively delete some unneeded tables (i.e. some work tables which are no more needed for further processing).&lt;BR /&gt;
&lt;BR /&gt;
Also: Try to avoid creating the unwanted variables in first place.&lt;BR /&gt;
&lt;BR /&gt;
HTH&lt;BR /&gt;
Patrick</description>
      <pubDate>Fri, 02 Apr 2010 01:15:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72798#M15680</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2010-04-02T01:15:50Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72799#M15681</link>
      <description>Hi All,&lt;BR /&gt;
&lt;BR /&gt;
I also tried using alter table , it take more time to run.&lt;BR /&gt;
previously i have compressed the DS but now i don't, as i need to work further on it&lt;BR /&gt;
so why unecessary compress and uncompress, also i have enough diskspace to store the data.&lt;BR /&gt;
&lt;BR /&gt;
the input file from where i am populating this DS is as follows&lt;BR /&gt;
&lt;BR /&gt;
1, 2,23,4,5,24,6,7&lt;BR /&gt;
&lt;BR /&gt;
2, 3, 234,2,6,712,8,4,1025,10,3&lt;BR /&gt;
&lt;BR /&gt;
where 1st  is id i.e  id=1&lt;BR /&gt;
2nd is no. of values (of index)  cnt =2&lt;BR /&gt;
&lt;BR /&gt;
23 is the index of column (basically its some other id)&lt;BR /&gt;
4, 5 are the values   i.e.  x_23  =4  , y_23 = 5 &lt;BR /&gt;
 x_24 = 6,  y_24 = 7&lt;BR /&gt;
&lt;BR /&gt;
similarly for second record id= 2, &lt;BR /&gt;
cnt =3 and the 3 values are&lt;BR /&gt;
x_234 = 2 y_234=6 , &lt;BR /&gt;
x_712=8,  y_712=4 , &lt;BR /&gt;
x_1025 =10, y_1025 = 3&lt;BR /&gt;
&lt;BR /&gt;
so this index can vary from 1 to 2000.&lt;BR /&gt;
&lt;BR /&gt;
so i have defined a array of all the columns  &lt;BR /&gt;
&lt;BR /&gt;
array x_{2000};&lt;BR /&gt;
array y_{2000};&lt;BR /&gt;
 &lt;BR /&gt;
infile "c:\inputfile.csv" dsd missover lrecl=32767;&lt;BR /&gt;
&lt;BR /&gt;
input id cnt @;&lt;BR /&gt;
do i=1 to cnt;&lt;BR /&gt;
input id2  x_[id2] y_[id2] @;&lt;BR /&gt;
end;&lt;BR /&gt;
&lt;BR /&gt;
................&lt;BR /&gt;
so can we have  alternate method so that we can make columns only that we want.&lt;BR /&gt;
&lt;BR /&gt;
Regards,&lt;BR /&gt;
Avi</description>
      <pubDate>Fri, 02 Apr 2010 04:46:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72799#M15681</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-04-02T04:46:20Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72800#M15682</link>
      <description>Avi&lt;BR /&gt;
&lt;BR /&gt;
It all comes down to data organisation.&lt;BR /&gt;
&lt;BR /&gt;
Below how I think your dataset should look like. The primary key of the result data set is {id,ValuePair_Cnt}, Col_Ind is the classification variable, X and Y the analysis variables, N_ValuePairs is not needed in the output and could be dropped.&lt;BR /&gt;
&lt;BR /&gt;
data want;&lt;BR /&gt;
  infile datalines dsd truncover;&lt;BR /&gt;
  length id ValuePair_Cnt 8;&lt;BR /&gt;
  input id N_ValuePairs Col_Ind @;&lt;BR /&gt;
  do ValuePair_Cnt=1 to N_ValuePairs;&lt;BR /&gt;
    input x y @;&lt;BR /&gt;
    output;&lt;BR /&gt;
  end;&lt;BR /&gt;
datalines;&lt;BR /&gt;
1, 2,23,4,5,24,6,7&lt;BR /&gt;
2, 3, 234,2,6,712,8,4,1025,10,3&lt;BR /&gt;
;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
proc print data=want noobs;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Compression:&lt;BR /&gt;
It's true that having the compress option turned on adds some processing time when reading\writen a data set but it also reduces I\O which is often the bottleneck.&lt;BR /&gt;
&lt;BR /&gt;
HTH&lt;BR /&gt;
Patrick</description>
      <pubDate>Fri, 02 Apr 2010 08:38:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72800#M15682</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2010-04-02T08:38:47Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72801#M15683</link>
      <description>Hi patrik, &lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&amp;gt; data want;&lt;BR /&gt;
&amp;gt;   infile datalines dsd truncover;&lt;BR /&gt;
&amp;gt; length id ValuePair_Cnt 8;&lt;BR /&gt;
&amp;gt;   input id N_ValuePairs Col_Ind @;&lt;BR /&gt;
&amp;gt; do ValuePair_Cnt=1 to N_ValuePairs;&lt;BR /&gt;
&amp;gt;     input x y @;&lt;BR /&gt;
&amp;gt; output;&lt;BR /&gt;
&amp;gt;   end;&lt;BR /&gt;
&amp;gt; talines;&lt;BR /&gt;
&amp;gt; 1, 2,23,4,5,24,6,7&lt;BR /&gt;
&amp;gt; 2, 3, 234,2,6,712,8,4,1025,10,3&lt;BR /&gt;
 &amp;gt; ;&lt;BR /&gt;
&amp;gt; run;&lt;BR /&gt;
&amp;gt; &lt;BR /&gt;
&lt;BR /&gt;
In your code you read col_ind only once ...&lt;BR /&gt;
but  after reading fist x,y  the col_ind changes&lt;BR /&gt;
&lt;BR /&gt;
eg..   &lt;BR /&gt;
for 1st obs   .... its 1st ... 23 then 24&lt;BR /&gt;
for 2nd obs ... its 234, 712, 1025...&lt;BR /&gt;
&lt;BR /&gt;
I can place col_ind like this ...&lt;BR /&gt;
&lt;BR /&gt;
input col_ind x y @;&lt;BR /&gt;
output;&lt;BR /&gt;
&lt;BR /&gt;
but this approach is not suitable for me as the id  should be unique per row. &lt;BR /&gt;
&lt;BR /&gt;
thanks &lt;BR /&gt;
&lt;BR /&gt;
regards,&lt;BR /&gt;
Avi</description>
      <pubDate>Fri, 02 Apr 2010 09:32:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72801#M15683</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2010-04-02T09:32:55Z</dc:date>
    </item>
    <item>
      <title>Re: can we keep/drop a variable without reading the the dataset.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72802#M15684</link>
      <description>Avi&lt;BR /&gt;
&lt;BR /&gt;
Missed how col_ind really works. &lt;BR /&gt;
&lt;BR /&gt;
Still: With the change you made you would get a unique composite key.&lt;BR /&gt;
&lt;BR /&gt;
But let's assume you need the data horizontal.&lt;BR /&gt;
&lt;BR /&gt;
I believe the following should do without creating too many unnecessary variables:&lt;BR /&gt;
&lt;BR /&gt;
data sample;&lt;BR /&gt;
  infile datalines dsd truncover;&lt;BR /&gt;
  input id N_ValuePairs @;&lt;BR /&gt;
  do i=1 to N_ValuePairs;&lt;BR /&gt;
    input Col_Ind @;&lt;BR /&gt;
    do name='x','y';&lt;BR /&gt;
      input Value_Var @;&lt;BR /&gt;
      Name_Var=cats(name,'_',Col_Ind);&lt;BR /&gt;
      output;&lt;BR /&gt;
    end;&lt;BR /&gt;
  end;&lt;BR /&gt;
  keep id name_var value_var;&lt;BR /&gt;
datalines;&lt;BR /&gt;
1, 2,23,4,5,24,6,7&lt;BR /&gt;
2, 3, 234,2,6,712,8,4,1025,10,3&lt;BR /&gt;
3, 1,23,14,15&lt;BR /&gt;
;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
proc transpose data=sample out=sample(drop=_name_) ;&lt;BR /&gt;
  by id;&lt;BR /&gt;
  id Name_Var;&lt;BR /&gt;
  var Value_VAR;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
proc print data=sample noobs;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
HTH&lt;BR /&gt;
Patrick</description>
      <pubDate>Fri, 02 Apr 2010 10:22:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-we-keep-drop-a-variable-without-reading-the-the-dataset/m-p/72802#M15684</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2010-04-02T10:22:22Z</dc:date>
    </item>
  </channel>
</rss>

