Skip to main content



      Home
Home » Eclipse Projects » EclipseLink » set schema name for stored procedures using JPA
set schema name for stored procedures using JPA [message #778629] Fri, 13 January 2012 10:07 Go to next message
Eclipse UserFriend
Hello All:

I am using an Oracle database which has a schema name associated with it. I am able to use the SessionCustomizer override
session.getLogin().setTableQualifier(schema) to set the schema name. However, this only works for tables. When I try to call a stored procedure using a named query, it does not get honoured and I get procedure not found errors.

Can you please help me in this regard?

I appreciate all the help.

Thanks
Sridhar
Re: set schema name for stored procedures using JPA [message #779886 is a reply to message #778629] Mon, 16 January 2012 13:44 Go to previous messageGo to next message
Eclipse UserFriend
There is currently no tableQualifier on StoredProcedureCall. Please log a bug to have one added, and default to the login's qualifier.

As a workaround you will need to qualify the procedure name using "schema.procedure" when you define or execute your stored procedure.

You could also default the user's schema, so no tableQualifier is required.
Re: set schema name for stored procedures using JPA [message #779888 is a reply to message #778629] Mon, 16 January 2012 13:44 Go to previous messageGo to next message
Eclipse UserFriend
There is currently no tableQualifier on StoredProcedureCall. Please log a bug to have one added, and default to the login's qualifier.

As a workaround you will need to qualify the procedure name using "schema.procedure" when you define or execute your stored procedure.

You could also default the user's schema, so no tableQualifier is required.

--
James : http://wiki.eclipse.org/EclipseLink : http://en.wikibooks.org/wiki/Java_Persistence : http://java-persistence-performance.blogspot.com/
Re: set schema name for stored procedures using JPA [message #780286 is a reply to message #779888] Tue, 17 January 2012 09:34 Go to previous messageGo to next message
Eclipse UserFriend
Thanks James. I will logon a bug as requested. I have a question with regards to your recommendation "You could also default the user's schema, so no tableQualifier is required". Is that using the orm.xml <schema>OWNERS_SCHEMA</schema> tags?

Thanks
Re: set schema name for stored procedures using JPA [message #780288 is a reply to message #779888] Tue, 17 January 2012 09:34 Go to previous messageGo to next message
Eclipse UserFriend
Thanks James. I will logon a bug as requested. I have a question with regards to your recommendation "You could also default the user's schema, so no tableQualifier is required". Is that using the orm.xml <schema>OWNERS_SCHEMA</schema> tags?

Thanks
Re: set schema name for stored procedures using JPA [message #780854 is a reply to message #780286] Thu, 19 January 2012 11:29 Go to previous message
Eclipse UserFriend
No, you can do that on your database when your DBA creates your user.
Re: set schema name for stored procedures using JPA [message #781005 is a reply to message #780286] Thu, 19 January 2012 11:29 Go to previous message
Eclipse UserFriend
No, you can do that on your database when your DBA creates your user.

--
James : http://wiki.eclipse.org/EclipseLink : http://en.wikibooks.org/wiki/Java_Persistence : http://java-persistence-performance.blogspot.com/
Re: set schema name for stored procedures using JPA [message #781022 is a reply to message #780286] Thu, 19 January 2012 11:29 Go to previous message
Eclipse UserFriend
No, you can do that on your database when your DBA creates your user.

--
James : http://wiki.eclipse.org/EclipseLink : http://en.wikibooks.org/wiki/Java_Persistence : http://java-persistence-performance.blogspot.com/
Re: set schema name for stored procedures using JPA [message #781039 is a reply to message #780286] Thu, 19 January 2012 11:29 Go to previous message
Eclipse UserFriend
No, you can do that on your database when your DBA creates your user.

--
James : http://wiki.eclipse.org/EclipseLink : http://en.wikibooks.org/wiki/Java_Persistence : http://java-persistence-performance.blogspot.com/
Previous Topic:Shared cache on multi base using same classes
Next Topic:Error when trying to use PLSQLTable type as an IN parameter in a PLSQLStoredProcedure in eclipse lin
Goto Forum:
  


Current Time: Wed Jul 23 11:15:08 EDT 2025

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

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

Back to the top