>>>>> "Steven" == Steven Dahlin <[EMAIL PROTECTED]> writes:
Steven> When I try to get a datasource which has been defined in the struts-config.xml no matter what I do the datasource returns back null. My struts-config.xml for data-sources is: Steven> <data-sources> Steven> <data-source key = "conPool"> Steven> <set-property property = "autoCommit" Steven> value = "false"/> Steven> <set-property property = "description" Steven> value = "database source"/> Steven> <set-property property = "driverClass" Steven> value = "oracle.jdbc.driver.OracleDriver"/> Steven> <set-property property = "user" Steven> value = "theuser"/> Steven> <set-property property = "password" Steven> value = "thepassword"/> Steven> <set-property property = "url" Steven> value = "jdbc:oracle:thin:@192.192.192.192:1675:inst"/> Steven> </data-source> Steven> </data-sources> Steven> In the section of code used for initialization of the datasource there is the following: Steven> ServletContext context = actSrv.getServletContext(); Steven> dsSrc = ( DataSource ) context.getAttribute( "ConPool" ); Steven> The context is captured but the datasource remains null. Are you using modules? The data-source is put into the ServletContext with a key that is constructed by appending the module prefix to the given key. -- =================================================================== David M. Karr ; Java/J2EE/XML/Unix/C++ [EMAIL PROTECTED] ; SCJP -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>