Hello all, i have problem regarding mssql connection /*****Code Snippet for MSSQL connection*******/ public static Connection getSqlConnection() throws SQLException { try { Context c = new InitialContext(); DataSource dataSource = (DataSource) c.lookup("java:/comp/env/jdbc/mssql"); return dataSource.getConnection(); } catch (NamingException err) { throw new SQLException(); } }
I got a SQLEXCEPTION in getSqlConnection() function: "*javax.naming.NameNotFoundException: cannot create resource instance" /*****Code Snippet of context path for MSSQL connection*******/ <Resource name="jdbc/mssql" type="net.sourceforge.jtds.jdbcx.JtdsDataSource" removeAbandoned="true" removeAbandonedTimeout="60" maxActive="4" maxIdle="2" username="sa" password="root" maxWait="5000" driverClassName="net.sourceforge.jtds.jdbc.Driver" url="jdbc:jdts:sqlserver://localhost:1433/flight" /> How can i remove this sql exception? Looking forward to your suggestion. Thank you -- View this message in context: http://www.nabble.com/mssql-connection-problem-tp21787078p21787078.html Sent from the Wicket - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org