<?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 proc sql statement continues to run in db server in Administration and Deployment</title>
    <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438433#M12325</link>
    <description>&lt;P&gt;Users successfully run a proc sql statement connecting to Greenplum server from Enterprise Guide. But 2 hours after the statement was successfully completed, the sql process continues to linger in the database server. The DB admins are not happy about it. Is this common? I think that EG query builder automatically adds a "quit;" statement at the end of the query, no?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 19 Feb 2018 16:47:06 GMT</pubDate>
    <dc:creator>putteringpluie</dc:creator>
    <dc:date>2018-02-19T16:47:06Z</dc:date>
    <item>
      <title>proc sql statement continues to run in db server</title>
      <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438433#M12325</link>
      <description>&lt;P&gt;Users successfully run a proc sql statement connecting to Greenplum server from Enterprise Guide. But 2 hours after the statement was successfully completed, the sql process continues to linger in the database server. The DB admins are not happy about it. Is this common? I think that EG query builder automatically adds a "quit;" statement at the end of the query, no?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2018 16:47:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438433#M12325</guid>
      <dc:creator>putteringpluie</dc:creator>
      <dc:date>2018-02-19T16:47:06Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql statement continues to run in db server</title>
      <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438438#M12326</link>
      <description>&lt;P&gt;When you say the 'sql process', do you mean the session's connection to the database?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Having known a few&amp;nbsp;DBAs, it's the kind of thing they'd get itchy about (for very little reason). The thing is, the connection won't be closed at the end of your PROC SQL statement, but rather for the duration of your libname assignment. This link will give you more insight into how it all works:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/acreldb/63647/HTML/default/viewer.htm#a001342247.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/acreldb/63647/HTML/default/viewer.htm#a001342247.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Nik&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2018 17:17:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438438#M12326</guid>
      <dc:creator>boemskats</dc:creator>
      <dc:date>2018-02-19T17:17:35Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql statement continues to run in db server</title>
      <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438443#M12327</link>
      <description>&lt;P&gt;Thanks Nik for the reply,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When the DBA looks for 'long-running' jobs on the DB server he can see the select statement and the join statement generated by the EG Query Builder, and it looks as if the query is still running on the DB server.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The EG user tells me that the query was completed a while back and the data was returned to him successfully, so my question is shouldn't the query disappear from the DB server after it completes?&amp;nbsp;It goes away when EG application is closed completely but not when the user just minimizes EG and steps away from the computer.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2018 17:37:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438443#M12327</guid>
      <dc:creator>putteringpluie</dc:creator>
      <dc:date>2018-02-19T17:37:33Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql statement continues to run in db server</title>
      <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438459#M12328</link>
      <description>&lt;P&gt;If the EG Query Builder is connecting to the db server with a LIBNAME statement then the database connection will remain active but not consuming any resources until the LIBNAME itself is cleared (libname libref clear;) or the EG session is closed. This appears to be the behaviour you are seeing.&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2018 19:11:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438459#M12328</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2018-02-19T19:11:42Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql statement continues to run in db server</title>
      <link>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438564#M12338</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/19084"&gt;@putteringpluie&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;as indicated, if your users just use a libname statement, the connection will last as long as the libname statement is assigned.&lt;/P&gt;
&lt;P&gt;For this purpose, once finished, the code will have to include a libname clear statement (&lt;A href="http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#chloptfmain.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#chloptfmain.htm&lt;/A&gt; + &lt;A href="http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#p1janotyd8q0qrn1jhkin21462in.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#p1janotyd8q0qrn1jhkin21462in.htm&lt;/A&gt;)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A very recommended feature, if your SAS/ACCESS engine allows it, is to pass the query statements with passthrough statements, which alllows to use the CONNECT andDISCONNECT functionality. You will be in control of your DB connections and will run with improved performance:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://documentation.sas.com/?docsetId=lrcon&amp;amp;docsetTarget=n1kbstf7vw0qcjn1ibfc8c78a9lc.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en" target="_blank"&gt;http://documentation.sas.com/?docsetId=lrcon&amp;amp;docsetTarget=n1kbstf7vw0qcjn1ibfc8c78a9lc.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;At last but not the least, I would like to recommend you to read this great paper, of DBMS usage on SAS Enterprise Guide:&amp;nbsp;&lt;A href="https://support.sas.com/resources/papers/proceedings11/306-2011.pdf" target="_blank"&gt;https://support.sas.com/resources/papers/proceedings11/306-2011.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please note: also, as long as your EG session is open, connected to the Workspace Server (SASApp), the SAS session is running on the server, meaning that ig the code has not closed the connection, the SAS process will have the DB connection open, indefinitely, until the EG session is closed or times-out.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All in all, I think the short and important message and recommendation is to adapt some working standards.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Feb 2018 09:03:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Administration-and-Deployment/proc-sql-statement-continues-to-run-in-db-server/m-p/438564#M12338</guid>
      <dc:creator>JuanS_OCS</dc:creator>
      <dc:date>2018-02-20T09:03:57Z</dc:date>
    </item>
  </channel>
</rss>

