Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Obtaining Instance of Connection from EM
Obtaining Instance of Connection from EM [message #538073] Fri, 04 June 2010 20:28 Go to next message
Mauro Flores is currently offline Mauro FloresFriend
Messages: 84
Registered: September 2009
Location: Brasil
Is there a way to obtaing the instance of java.sql.Connection being used by an instance of EntityManager?

Thanks, Mauro.
Re: Obtaining Instance of Connection from EM [message #538474 is a reply to message #538073] Mon, 07 June 2010 16:58 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

In JPA 2.0 you can use,


Previously you could access the connection from the DatabaseAccessor of the EntityManager's Session.

James : Wiki : Book : Blog : Twitter
Previous Topic:Query across Variable One to One mapping
Next Topic:HistoryPolicy: INSERT Error with missing fields
Goto Forum:

Current Time: Mon Nov 30 02:43:48 GMT 2015

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

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