<?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: Issue in using CALCULATED VARIABLE in proc update SET statement in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207449#M38575</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, I am not getting your questions&lt;/P&gt;&lt;P&gt;L_* are columns of the table Work.Sim_re_BERM.&lt;/P&gt;&lt;P&gt;Setting L9BE_C based on calculation max(0,L9_C*(L9BE/L9))&lt;/P&gt;&lt;P&gt;And L9RM_C based difference between L9_C on CALCUALTED L9BE_C.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 30 Apr 2015 17:30:40 GMT</pubDate>
    <dc:creator>PrakashBashyam</dc:creator>
    <dc:date>2015-04-30T17:30:40Z</dc:date>
    <item>
      <title>Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207447#M38573</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I m using below query&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Courier New;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;proc sql;&lt;/P&gt;&lt;P&gt;update Work.Sim_re_BERM&lt;/P&gt;&lt;P&gt;set L9BE_C=max(0,L9_C*(L9BE/L9)),&lt;/P&gt;&lt;P&gt;L9RM_C=L9_C - calculated L9BE_C;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Courier New;"&gt;Quit;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is throwing an ERROR: The illegal use of a CALCULATED variable has been detected in an UPDATE statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Courier New;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 16:29:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207447#M38573</guid>
      <dc:creator>PrakashBashyam</dc:creator>
      <dc:date>2015-04-30T16:29:25Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207448#M38574</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That query makes no sense to me. What are you trying to do?&amp;nbsp;&amp;nbsp; - PG&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 16:58:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207448#M38574</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-04-30T16:58:01Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207449#M38575</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, I am not getting your questions&lt;/P&gt;&lt;P&gt;L_* are columns of the table Work.Sim_re_BERM.&lt;/P&gt;&lt;P&gt;Setting L9BE_C based on calculation max(0,L9_C*(L9BE/L9))&lt;/P&gt;&lt;P&gt;And L9RM_C based difference between L9_C on CALCUALTED L9BE_C.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 17:30:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207449#M38575</guid>
      <dc:creator>PrakashBashyam</dc:creator>
      <dc:date>2015-04-30T17:30:40Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207450#M38576</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK, maybe I get it now. Have you tried getting rid of CALCULATED :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG&gt;proc sql;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG&gt;update Work.Sim_re_BERM&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG&gt;set&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; L9BE_C = max(0, L9_C*(L9BE/L9)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; L9RM_C = L9_C - &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; background-color: #ffffff;"&gt;max(0, L9_C*(L9BE/L9))&lt;/SPAN&gt;;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG style="font-size: 10pt; font-style: inherit; font-family: 'Courier New';"&gt;Quit;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New';"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New';"&gt;PG&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 18:08:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207450#M38576</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-04-30T18:08:43Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207451#M38577</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;it perfectly works. But would like to understand whats wrong in using CALCUALTED variable like that &lt;img id="smileysad" class="emoticon emoticon-smileysad" src="https://communities.sas.com/i/smilies/16x16_smiley-sad.png" alt="Smiley Sad" title="Smiley Sad" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 18:32:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207451#M38577</guid>
      <dc:creator>PrakashBashyam</dc:creator>
      <dc:date>2015-04-30T18:32:30Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in using CALCULATED VARIABLE in proc update SET statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207452#M38578</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SQL is a formal language with very strict syntax. That is very different from natural languages which are much more flexible but also more prone to misinterpretation. I think the UPDATE query is made such that every assignment (&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;L9BE_C =&lt;/STRONG&gt;,&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt; &lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;L9RM_C =&lt;/STRONG&gt;&lt;/STRONG&gt;, etc) clause can be treated separately (and thus, in parallel).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PG &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2015 18:59:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Issue-in-using-CALCULATED-VARIABLE-in-proc-update-SET-statement/m-p/207452#M38578</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-04-30T18:59:01Z</dc:date>
    </item>
  </channel>
</rss>

