File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Configuring a JNDI datasource along with schema name

 
vShyam Sundar
Ranch Hand
Posts: 60
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
How to configure a JNDI datasource in spring along with schema name. I am using spring and Ibatis. Though i am aware of placing the schema name in properties fiile and referring that in sql maps. I am not interested to do that as it needs 100s of sql maps to be modified with 1000s of queries.

Let me know if there is any other way of doing this.

Am really in need of help on this.

Thanks in advance.


-Shyam.
 
Mark Spritzler
ranger
Sheriff
Posts: 17276
6
IntelliJ IDE Mac Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are asking how to lookup a DataSource that is JNDI into your Spring app?

If so, use

<jee:jndi-lookup> tag

Which uses the
JndiObjectFactoryBean

Mark
 
vShyam Sundar
Ranch Hand
Posts: 60
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Mark,
My question is not related to using data sources. Instead my question is how to use the schema name appended to my sql queries
written in Ibatis config files. Is there any way to append the schema name to all queries with spring configuration while defining the data source.

Thanks,
Shyam.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic