Hi guys,
I'm am currently trying to learn
Java and want to connect to a Postgresql database.
I am using a simple
JSP page and a bean which contains all database functions. This is set up in
Tomcat and JDK/1.6.0. Everything works fine but the connection itself, for some reason it throws a null value.
I suspect that the problem is the connection configuration, in tomcat/conf/context.xml.
Connecting to the database from terminal works fine, using psql -h etc...
This is what I have:
tomcat/conf/context.xml
tomcat/webapps/ROOT/WEB-INF/web.xml
tomcat/webapps/ROOT/WEB-INF/classes/bean/db.java
tomcat/webapps/ROOT/login.jsp
Running login.jsp returns error here:
Error output:
What am I doing wrong? Help is very much appreciated.
Thank you.