Application Server Solutions for Microsoft IIS and ASP.NET
       solutions   products   partners   company   support   downloads         store
ServletExec Self-Help: FAQ
Back to Search >  Back to Search Results

Faq ID 178
Product ServletExec
Category JDBC
Question Does ServletExec support the use of JDBC 2.0 DataSources ?
Answer Yes.
Simply put the appropriate classes, such as:
  • jdbc2_0-stdext.jar
  • the JDBC driver classes for your database

into the appropriate ServletExec classpath and create an instance of the DataSource object and then use it.
If you wish, you may place your DataSource instance into a JNDI context so that your other code running inside of ServletExec can look it up and use it.
Beginning with version 4.0 of ServletExec, the ability to Manage your DataSources from the Main ServletExec Admin UI was added. With that version of ServletExec (and all higher versions), ServletExec provides an initial JNDI context into which your configured datasources will be automatically added. Your code could then lookup the DataSource using the following syntax:

Context ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup( "jdbc/<data source name>" );

company media information terms of use privacy policy contact us