<?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 Case statement in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6333#M2500</link>
    <description>I am trying to define a column using the following:&lt;BR /&gt;
CASE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
WHEN NULL THEN T3."ICIS_PRODUCT_ID"&lt;BR /&gt;
ELSE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
END AS PSEUDO_PRID,&lt;BR /&gt;
&lt;BR /&gt;
SAS does not like this.  Is there another way to define a column called PSEUDO_PRID &lt;BR /&gt;
code like when the field Component_Product_Id is null then give me ICIS_Product_Id else give me Component_Product_Id.</description>
    <pubDate>Fri, 11 Jan 2008 14:19:40 GMT</pubDate>
    <dc:creator>lloraine</dc:creator>
    <dc:date>2008-01-11T14:19:40Z</dc:date>
    <item>
      <title>Case statement</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6333#M2500</link>
      <description>I am trying to define a column using the following:&lt;BR /&gt;
CASE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
WHEN NULL THEN T3."ICIS_PRODUCT_ID"&lt;BR /&gt;
ELSE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
END AS PSEUDO_PRID,&lt;BR /&gt;
&lt;BR /&gt;
SAS does not like this.  Is there another way to define a column called PSEUDO_PRID &lt;BR /&gt;
code like when the field Component_Product_Id is null then give me ICIS_Product_Id else give me Component_Product_Id.</description>
      <pubDate>Fri, 11 Jan 2008 14:19:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6333#M2500</guid>
      <dc:creator>lloraine</dc:creator>
      <dc:date>2008-01-11T14:19:40Z</dc:date>
    </item>
    <item>
      <title>Re: Case statement</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6334#M2501</link>
      <description>Hi:&lt;BR /&gt;
  This is not an ODS or Base Reporting (PROC PRINT, REPORT, TABULATE) question.&lt;BR /&gt;
&lt;BR /&gt;
  The SAS documentation for PROC SQL does have examples of using a CASE clause. Alternately, you might consider contacting Tech Support for help. To send a question to Tech Support, go to &lt;A href="http://support.sas.com/" target="_blank"&gt;http://support.sas.com/&lt;/A&gt; and in the left-hand navigation pane, click on the link entitled "Submit a Problem".&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Fri, 11 Jan 2008 14:23:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6334#M2501</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2008-01-11T14:23:15Z</dc:date>
    </item>
    <item>
      <title>Re: Case statement</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6335#M2502</link>
      <description>Try using sas functions.&lt;BR /&gt;
&lt;BR /&gt;
I kind of remember using something similar to the following in some code some while back...&lt;BR /&gt;
&lt;BR /&gt;
In proc sql try the following;&lt;BR /&gt;
 case t3.component_product_id;&lt;BR /&gt;
when Missing(t3.component_product_id) eq 1 then t3.ics_product_id etc;&lt;BR /&gt;
&lt;BR /&gt;
In Datastep;&lt;BR /&gt;
Select (component_product_id)&lt;BR /&gt;
  When (Missing(compoonent_product_id) eq 1) then ics_product_id eq ''; etc&lt;BR /&gt;
&lt;BR /&gt;
hope that helps....&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
CASE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
WHEN NULL THEN T3."ICIS_PRODUCT_ID"&lt;BR /&gt;
ELSE T3."COMPONENT_PRODUCT_ID"&lt;BR /&gt;
END AS PSEUDO_PRID,</description>
      <pubDate>Tue, 29 Jan 2008 13:14:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Case-statement/m-p/6335#M2502</guid>
      <dc:creator>CameronLawson</dc:creator>
      <dc:date>2008-01-29T13:14:36Z</dc:date>
    </item>
  </channel>
</rss>

