<?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: How to close an SDE connection in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163204#M4244</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hello,&lt;BR /&gt;&lt;BR /&gt;Is there a proper way to close an SDE connection or just let the IWorkspace garbage collected by .NET.&amp;nbsp; What we have is an IWorkspace to an SDE that we start and edit session, made some edits, stopped the operation, stopped edit session.&amp;nbsp; At this point should we issue another command to close the IWorkspace?&lt;BR /&gt;&lt;BR /&gt;Currently, in our Oracle database the SDE.states table grows by one record for every edit session that is opened and these records stay after the edit session is stopped.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Vu&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Its not like normal database.. something like close and open the connection..once done with start and stop edit sessions ... that is done..&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 15 Feb 2011 02:46:26 GMT</pubDate>
    <dc:creator>Venkata_RaoTammineni</dc:creator>
    <dc:date>2011-02-15T02:46:26Z</dc:date>
    <item>
      <title>How to close an SDE connection</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163203#M4243</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there a proper way to close an SDE connection or just let the IWorkspace garbage collected by .NET.&amp;nbsp; What we have is an IWorkspace to an SDE that we start and edit session, made some edits, stopped the operation, stopped edit session.&amp;nbsp; At this point should we issue another command to close the IWorkspace?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Currently, in our Oracle database the SDE.states table grows by one record for every edit session that is opened and these records stay after the edit session is stopped.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Vu&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Feb 2011 19:29:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163203#M4243</guid>
      <dc:creator>VuDang</dc:creator>
      <dc:date>2011-02-14T19:29:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to close an SDE connection</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163204#M4244</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hello,&lt;BR /&gt;&lt;BR /&gt;Is there a proper way to close an SDE connection or just let the IWorkspace garbage collected by .NET.&amp;nbsp; What we have is an IWorkspace to an SDE that we start and edit session, made some edits, stopped the operation, stopped edit session.&amp;nbsp; At this point should we issue another command to close the IWorkspace?&lt;BR /&gt;&lt;BR /&gt;Currently, in our Oracle database the SDE.states table grows by one record for every edit session that is opened and these records stay after the edit session is stopped.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Vu&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Its not like normal database.. something like close and open the connection..once done with start and stop edit sessions ... that is done..&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Feb 2011 02:46:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163204#M4244</guid>
      <dc:creator>Venkata_RaoTammineni</dc:creator>
      <dc:date>2011-02-15T02:46:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to close an SDE connection</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163205#M4245</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;... should we issue another command to close the IWorkspace? &lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pWorkspace = Nothing&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Feb 2011 16:26:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163205#M4245</guid>
      <dc:creator>JonHall</dc:creator>
      <dc:date>2011-02-15T16:26:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to close an SDE connection</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163206#M4246</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Use the comReleaser object when you are done.&amp;nbsp; You have to use it on the cursors, tables, featureclasses, features,&amp;nbsp; rows,&amp;nbsp; cursors etc. or else you will still have objects with a connection open.&amp;nbsp; It is actually quite tricky.&amp;nbsp; Even if you just access a object through the property of another object, will will end up with a reference to that object in memory not assigned to a variable...&amp;nbsp; Make sure you assign these to a variable so you can release it later.&amp;nbsp; I like to make a using block with a new comreleaser and add all the variables to the be managed by the comreleaser, when the using block end the comreleaser gets destroyed and releases all the references it manages.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Feb 2011 16:41:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163206#M4246</guid>
      <dc:creator>AlexanderGray</dc:creator>
      <dc:date>2011-02-15T16:41:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to close an SDE connection</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163207#M4247</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;...the SDE.states table grows by one record for every edit session that is opened and these records stay after the edit session is stopped.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Isn't this normal when editing a versioned database?&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Have you run ArcCatalog (ArcToolbox &amp;gt; data management &amp;gt; database &amp;gt; ) COMPRESS, then checked the sde_states table ?&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Are you editing in the Default version? If not, you may need to reconcile, post the edits in your Version, delete the Version, then run Compress...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If Compress isn't removing sde_States records that you think are unreferenced, then maybe they are still referenced. Have your DBA check that COMPRESS moved all the A &amp;amp; D records to the base tables, and that no A or D table records that still reference that SDE-State_ID. If the A&amp;amp; D table records are still there, then have the DBA check if locks are beingleft open.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;What version of ArcSDE Enterprise are you connecting to?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unlike ADO connections, there is no .close method.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think it will solve your problems if you set the workspace = nothing, and have your DBA set up a regularly scheduled automatic Compress&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Feb 2011 16:45:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/how-to-close-an-sde-connection/m-p/163207#M4247</guid>
      <dc:creator>JonHall</dc:creator>
      <dc:date>2011-02-15T16:45:12Z</dc:date>
    </item>
  </channel>
</rss>

