<?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 WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624117#M183791</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#I'm Trying to fill up missing values for variable age with adding new column call age_&amp;nbsp; which will filled with the condition then i ll drop the column age and rename age_ to age however i got the warning above in subject and missing values still missing&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Data DATA bank_Filling_All_Missing ;&lt;BR /&gt;SET bank_filling_Income;&lt;BR /&gt;Age_ = .;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'U') then Age_ = 47.9;&lt;BR /&gt;if(Age &amp;gt;1) and (res = 'U') then Age_ = Age;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'R') then Age_ = 48.16;&lt;BR /&gt;if(Age&amp;gt;1) and (res = 'R') then Age_ = Age;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'S') then Age_ = 47.7;&lt;BR /&gt;if(Age&amp;gt;1) and (res = 'S') then Age_ = Age;&lt;BR /&gt;drop Age_;&lt;BR /&gt;rename Age_ =Age;&lt;BR /&gt;RUN ;&lt;/P&gt;</description>
    <pubDate>Wed, 12 Feb 2020 09:31:05 GMT</pubDate>
    <dc:creator>MAJEED</dc:creator>
    <dc:date>2020-02-12T09:31:05Z</dc:date>
    <item>
      <title>WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624117#M183791</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#I'm Trying to fill up missing values for variable age with adding new column call age_&amp;nbsp; which will filled with the condition then i ll drop the column age and rename age_ to age however i got the warning above in subject and missing values still missing&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Data DATA bank_Filling_All_Missing ;&lt;BR /&gt;SET bank_filling_Income;&lt;BR /&gt;Age_ = .;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'U') then Age_ = 47.9;&lt;BR /&gt;if(Age &amp;gt;1) and (res = 'U') then Age_ = Age;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'R') then Age_ = 48.16;&lt;BR /&gt;if(Age&amp;gt;1) and (res = 'R') then Age_ = Age;&lt;BR /&gt;if(Age&amp;lt;0) and (res = 'S') then Age_ = 47.7;&lt;BR /&gt;if(Age&amp;gt;1) and (res = 'S') then Age_ = Age;&lt;BR /&gt;drop Age_;&lt;BR /&gt;rename Age_ =Age;&lt;BR /&gt;RUN ;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 09:31:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624117#M183791</guid>
      <dc:creator>MAJEED</dc:creator>
      <dc:date>2020-02-12T09:31:05Z</dc:date>
    </item>
    <item>
      <title>Re: WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624123#M183794</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/283621"&gt;@MAJEED&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It seems you have two issues:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Data /*DATA*/ bank_Filling_All_Missing ;
SET bank_filling_Income;
Age_ = .;
if(Age&amp;lt;0) and (res = 'U') then Age_ = 47.9;
if(Age &amp;gt;1) and (res = 'U') then Age_ = Age;
if(Age&amp;lt;0) and (res = 'R') then Age_ = 48.16;
if(Age&amp;gt;1) and (res = 'R') then Age_ = Age;
if(Age&amp;lt;0) and (res = 'S') then Age_ = 47.7;
if(Age&amp;gt;1) and (res = 'S') then Age_ = Age;
drop Age/*_*/;
rename Age_ =Age;
RUN ;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 12 Feb 2020 09:38:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624123#M183794</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-02-12T09:38:14Z</dc:date>
    </item>
    <item>
      <title>Re: WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624124#M183795</link>
      <description>&lt;P&gt;what are the issues&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 09:40:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624124#M183795</guid>
      <dc:creator>MAJEED</dc:creator>
      <dc:date>2020-02-12T09:40:15Z</dc:date>
    </item>
    <item>
      <title>Re: WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624125#M183796</link>
      <description>&lt;P&gt;plz try&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#339966"&gt;&lt;STRONG&gt;drop Age;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;rename Age_ =Age;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;instead of&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;drop Age_;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;rename Age_ =Age;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 09:40:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624125#M183796</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2020-02-12T09:40:36Z</dc:date>
    </item>
    <item>
      <title>Re: WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624128#M183799</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/283621"&gt;@MAJEED&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Look at the portion in the code I have put in comments -&amp;gt;&lt;/P&gt;
&lt;P&gt;/*DATA*/&lt;/P&gt;
&lt;P&gt;/*_*/ -&amp;gt; Age instead of Age_&lt;/P&gt;</description>
      <pubDate>Wed, 12 Feb 2020 09:44:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624128#M183799</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-02-12T09:44:18Z</dc:date>
    </item>
    <item>
      <title>Re: WARNING: The variable Age_ in the DROP, KEEP, or RENAME list has never been referenced</title>
      <link>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624230#M183860</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/283621"&gt;@MAJEED&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;what are the issues&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;When you DROP a variable it is no longer available to RENAME.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Note that statements like DROP are not executable. That means the order of their of appearance in a data step doesn't matter. The variable is Dropped. Period.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Which is why you get the same warning with this code:&lt;/P&gt;
&lt;PRE&gt;152  data junk;
153     Set sashelp.class;
154     rename age=newage;
155     drop age;
156  run;

WARNING: The variable age in the DROP, KEEP, or RENAME list has never been referenced.
NOTE: There were 19 observations read from the data set SASHELP.CLASS.

&lt;/PRE&gt;</description>
      <pubDate>Wed, 12 Feb 2020 16:05:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/WARNING-The-variable-Age-in-the-DROP-KEEP-or-RENAME-list-has/m-p/624230#M183860</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-02-12T16:05:54Z</dc:date>
    </item>
  </channel>
</rss>

