<?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 how do i delete certain rows, replace certain cells in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/how-do-i-delete-certain-rows-replace-certain-cells/m-p/184613#M46958</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i have a column called&amp;nbsp; &lt;STRONG&gt;annualreportdat&lt;/STRONG&gt;e&lt;/P&gt;&lt;P&gt;that column has observations such as dec2012, dec 2010, dec 2011, current&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1.)&amp;nbsp; how do i delete all the rows with current?&lt;/P&gt;&lt;P&gt;1.1) instead of deleting, how do i replace those with 2013?&lt;/P&gt;&lt;P&gt;2) i also want to remove all the dec from dec 2012, dec 2010....and so on.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Apr 2014 22:05:43 GMT</pubDate>
    <dc:creator>aarony</dc:creator>
    <dc:date>2014-04-17T22:05:43Z</dc:date>
    <item>
      <title>how do i delete certain rows, replace certain cells</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/how-do-i-delete-certain-rows-replace-certain-cells/m-p/184613#M46958</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i have a column called&amp;nbsp; &lt;STRONG&gt;annualreportdat&lt;/STRONG&gt;e&lt;/P&gt;&lt;P&gt;that column has observations such as dec2012, dec 2010, dec 2011, current&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1.)&amp;nbsp; how do i delete all the rows with current?&lt;/P&gt;&lt;P&gt;1.1) instead of deleting, how do i replace those with 2013?&lt;/P&gt;&lt;P&gt;2) i also want to remove all the dec from dec 2012, dec 2010....and so on.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2014 22:05:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/how-do-i-delete-certain-rows-replace-certain-cells/m-p/184613#M46958</guid>
      <dc:creator>aarony</dc:creator>
      <dc:date>2014-04-17T22:05:43Z</dc:date>
    </item>
    <item>
      <title>Re: how do i delete certain rows, replace certain cells</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/how-do-i-delete-certain-rows-replace-certain-cells/m-p/184614#M46959</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;One way to remove creating a new data set:&lt;/P&gt;&lt;P&gt;data want;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set have;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if annualreportdate="current" then delete;/* have to assume the variable is character if the value is actually "current"*/&lt;/P&gt;&lt;P&gt;/* you also may have to address case if sometimes it is current, Current, or CURRENT, so better would be*/&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if upcase(annualreportdate) = "CURRENT" then delete;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To modify a value:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if upcase(annualreportdate) = "CURRENT" then &amp;lt;do something&amp;gt;;&lt;/P&gt;&lt;P&gt;could be&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then annualreportdate='2013';&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then annualreportdate=tranwrd(annualreportdate,'dec','');&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2014 22:17:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/how-do-i-delete-certain-rows-replace-certain-cells/m-p/184614#M46959</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2014-04-17T22:17:02Z</dc:date>
    </item>
  </channel>
</rss>

