<?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: Update Query Error in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113695#M31475</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have you checked to see if the query&lt;/P&gt;&lt;P&gt;select * from cardiac.pos b where mbr_sys_id=XXX and fst_srvc_dt=xxx&lt;/P&gt;&lt;P&gt;returns multiple rows?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Jun 2013 14:53:31 GMT</pubDate>
    <dc:creator>DBailey</dc:creator>
    <dc:date>2013-06-20T14:53:31Z</dc:date>
    <item>
      <title>Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113694#M31474</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When I run the following query, I get the response of subquery evaulated to more than one row. mbr_sys_id = XXXX fst_srvc_dt = xxxx&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 10pt; background: white; font-family: 'Courier New';"&gt;proc&lt;/STRONG&gt; &lt;STRONG style="color: navy; font-size: 10pt; background: white; font-family: 'Courier New';"&gt;sql&lt;/STRONG&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;update&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; cardiac.pos2 a&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;set&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; pl_of_srvc_sys_id = (select pl_of_srvc_sys_id from cardiac.pos b &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.mbr_sys_id=b.mbr_sys_id and a.fst_srvc_dt = b.fst_srvc_dt),&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;pl_of_srvc_sum_desc = (select pl_of_srvc_sum_desc from cardiac.pos b &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.mbr_sys_id=b.mbr_sys_id and a.fst_srvc_dt = b.fst_srvc_dt)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.pl_of_srvc_sys_id &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; null and pl_of_srvc_sum_desc &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; font-size: 10pt; background: white; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jun 2013 14:17:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113694#M31474</guid>
      <dc:creator>tmm</dc:creator>
      <dc:date>2013-06-20T14:17:49Z</dc:date>
    </item>
    <item>
      <title>Re: Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113695#M31475</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have you checked to see if the query&lt;/P&gt;&lt;P&gt;select * from cardiac.pos b where mbr_sys_id=XXX and fst_srvc_dt=xxx&lt;/P&gt;&lt;P&gt;returns multiple rows?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jun 2013 14:53:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113695#M31475</guid>
      <dc:creator>DBailey</dc:creator>
      <dc:date>2013-06-20T14:53:31Z</dc:date>
    </item>
    <item>
      <title>Re: Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113696#M31476</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes it does have multiple rows. I cannot change the multiple rows within the table being updated because it has to be as it is. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jun 2013 16:07:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113696#M31476</guid>
      <dc:creator>tmm</dc:creator>
      <dc:date>2013-06-20T16:07:09Z</dc:date>
    </item>
    <item>
      <title>Re: Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113697#M31477</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How would you determine which of the multiple rows to use for the update?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Jun 2013 13:00:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113697#M31477</guid>
      <dc:creator>DBailey</dc:creator>
      <dc:date>2013-06-21T13:00:17Z</dc:date>
    </item>
    <item>
      <title>Re: Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113698#M31478</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nevermind. I changed it to the following because the reason for multiple member ids is we have various provider tins and mpins that serviced the member. So, I had to pull in a table that says give me member, tin, mpin place of service and service desc. so i did it this way instead with the update&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'Courier New'; background: white; color: navy; font-size: 10pt;"&gt;proc&lt;/STRONG&gt; &lt;STRONG style="font-family: 'Courier New'; background: white; color: navy; font-size: 10pt;"&gt;sql&lt;/STRONG&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;update&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; cardiac.pos2 a&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;set&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; pl_of_srvc_sys_id = (select pl_of_srvc_sys_id from cardiac.pos b &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.mbr_sys_id=b.mbr_sys_id and a.fst_srvc_dt = b.fst_srvc_dt and a.prov_tin = b.prov_tin and a.mpin = b.mpin),&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;pl_of_srvc_sum_desc = (select pl_of_srvc_sum_desc from cardiac.pos b &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.mbr_sys_id=b.mbr_sys_id and a.fst_srvc_dt = b.fst_srvc_dt and a.prov_tin = b.prov_tin and a.mpin = b.mpin)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;where&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; a.pl_of_srvc_sys_id &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; null and pl_of_srvc_sum_desc &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: blue; font-size: 10pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt; null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'Courier New'; background: white; color: navy; font-size: 10pt;"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Courier New'; background: white; color: black; font-size: 10pt;"&gt;It is running now. No row error. The only problem is I changed it yesterday about 4pm and it is now 11am the next day and still running. But, it has to go through 10.1 million rows sooooooooooo Will let you know if this works in the end and if so, great. Thanks.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Jun 2013 15:09:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113698#M31478</guid>
      <dc:creator>tmm</dc:creator>
      <dc:date>2013-06-21T15:09:04Z</dc:date>
    </item>
    <item>
      <title>Re: Update Query Error</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113699#M31479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;lots of columns/records to update....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is cardiac.pos sorted or indexed?&amp;nbsp; If not, then you definitely need to do that.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Jun 2013 12:31:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Update-Query-Error/m-p/113699#M31479</guid>
      <dc:creator>DBailey</dc:creator>
      <dc:date>2013-06-24T12:31:59Z</dc:date>
    </item>
  </channel>
</rss>

