Creating a datasource on JBoss

Place the oracle database driver (ojdbc14.jar) in C:\JBoss\jboss-5.1.0.CR1\server\default\lib Create the datasource xml file and place it in C:\JBoss\jboss-5.1.0.CR1\server\default\deploy oracle-ds.xml <datasources> <local-tx-datasource> <jndi-name>OracleDS</jndi-name> <connection-url>jdbc:oracle:thin:@192.168.96.95:1521:orcl</connection-url> <driver-class>oracle.jdbc.driver.OracleDriver</driver-class> <user-name>scott</user-name> <password>tiger</password> <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name> <check-valid-connection-sql>select * from dual</check-valid-connection-sql> <metadata> <type-mapping>Oracle9i</type-mapping> </metadata> </local-tx-datasource> </datasources> Start the server run -c default Deploy the application that uses a datasrouce index.jsp

Continue reading »