Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » HbDataStore.close() throwing SQLException
HbDataStore.close() throwing SQLException [message #82706] Wed, 09 May 2007 14:27 Go to next message
Paul Gardiner is currently offline Paul GardinerFriend
Messages: 94
Registered: July 2009
Member
Whenever I call HbDataStore.close(), or HbHelper.INSTANCE.closeAll(), I get
a SQLException "Cannot close a connection while a transaction is still
ative.". However, I have not opened any transactions myself, and all of my
sessions are closed, so I figure something during initialize() must have not
committed a transaction. Is there anything I have to do to make sure all
changes during initialization are committed?
Re: HbDataStore.close() throwing SQLException [message #82712 is a reply to message #82706] Wed, 09 May 2007 14:38 Go to previous messageGo to next message
Parvez is currently offline ParvezFriend
Messages: 181
Registered: July 2009
Senior Member
I normally call before that

session.flush();
session.clear();



Paul Gardiner wrote:
> Whenever I call HbDataStore.close(), or HbHelper.INSTANCE.closeAll(), I get
> a SQLException "Cannot close a connection while a transaction is still
> ative.". However, I have not opened any transactions myself, and all of my
> sessions are closed, so I figure something during initialize() must have not
> committed a transaction. Is there anything I have to do to make sure all
> changes during initialization are committed?
>
>
Re: HbDataStore.close() throwing SQLException [message #82715 is a reply to message #82712] Wed, 09 May 2007 15:37 Go to previous message
Paul Gardiner is currently offline Paul GardinerFriend
Messages: 94
Registered: July 2009
Member
Thanks. That seems to do it. I figured a close already flushed and cleared
it, but I guess not.

"PC" <p.chauhan@pilz.ie> wrote in message
news:f1smd7$md9$1@build.eclipse.org...
>I normally call before that
>
> session.flush();
> session.clear();
>
>
>
> Paul Gardiner wrote:
>> Whenever I call HbDataStore.close(), or HbHelper.INSTANCE.closeAll(), I
>> get a SQLException "Cannot close a connection while a transaction is
>> still ative.". However, I have not opened any transactions myself, and
>> all of my sessions are closed, so I figure something during initialize()
>> must have not committed a transaction. Is there anything I have to do to
>> make sure all changes during initialization are committed?
Re: HbDataStore.close() throwing SQLException [message #606641 is a reply to message #82706] Wed, 09 May 2007 14:38 Go to previous message
Parvez is currently offline ParvezFriend
Messages: 181
Registered: July 2009
Senior Member
I normally call before that

session.flush();
session.clear();



Paul Gardiner wrote:
> Whenever I call HbDataStore.close(), or HbHelper.INSTANCE.closeAll(), I get
> a SQLException "Cannot close a connection while a transaction is still
> ative.". However, I have not opened any transactions myself, and all of my
> sessions are closed, so I figure something during initialize() must have not
> committed a transaction. Is there anything I have to do to make sure all
> changes during initialization are committed?
>
>
Re: HbDataStore.close() throwing SQLException [message #606642 is a reply to message #82712] Wed, 09 May 2007 15:37 Go to previous message
Paul Gardiner is currently offline Paul GardinerFriend
Messages: 94
Registered: July 2009
Member
Thanks. That seems to do it. I figured a close already flushed and cleared
it, but I guess not.

"PC" <p.chauhan@pilz.ie> wrote in message
news:f1smd7$md9$1@build.eclipse.org...
>I normally call before that
>
> session.flush();
> session.clear();
>
>
>
> Paul Gardiner wrote:
>> Whenever I call HbDataStore.close(), or HbHelper.INSTANCE.closeAll(), I
>> get a SQLException "Cannot close a connection while a transaction is
>> still ative.". However, I have not opened any transactions myself, and
>> all of my sessions are closed, so I figure something during initialize()
>> must have not committed a transaction. Is there anything I have to do to
>> make sure all changes during initialization are committed?
Previous Topic:HbDataStore.close() throwing SQLException
Next Topic:[Teneo] MappingBuilder customization
Goto Forum:
  


Current Time: Mon Jan 25 15:13:16 GMT 2021

Powered by FUDForum. Page generated in 0.01607 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top