[jboss-user] [Datasource Configuration] - Oracle User Type Mappings

jaikiran pai do-not-reply at jboss.com
Wed Jul 21 14:34:03 EDT 2010


jaikiran pai [http://community.jboss.org/people/jaikiran] replied to the discussion

"Oracle User Type Mappings"

To view the discussion, visit: http://community.jboss.org/message/553812#553812

--------------------------------------------------------------
> Bob Frapples wrote:
> 
> I implemented this code:
> 
> DataSource ds = (DataSource)
> new InitialContext().lookup("jdbc/MyDS"); // replace this with your datasource deployed in JBoss
> +
> +** 
> *+
> +*
> ** 
Looks like you are using the datasource configured through Spring beans. I'm not sure how Spring works, but it looks like it creates a proxy to the original datasource. So instead of trying to lookup the spring one, directly lookup the JBoss deployed datasource:

new InitialContext().lookup("java:jdbc/MyDS");  


Note the java: prefix. That's the namespace to which JBoss by default deploys the datasources.

--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/553812#553812]

Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2077]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100721/75d1dde7/attachment.html 


More information about the jboss-user mailing list