Thread: The question of jdbc
Dear sir I'm interesting to use the PostgreSQL. In my concept, I have 2 server in a RedHat 7.2. The one is a webserver and the later is a dataserver. I read the document of PostgreSQL JDBC and practic it. It doesn't work . The Fist method: In mye webserver, I install the J2SDK1.4.0, the Tomcat-3.2.3.1noarch, a PostgreSQL-7.1.3-2 and the PostgresSQL-JDBC-7.1.3-2. By the way, I setup Path and ClassPath in the .bash_profile : JAVA_HOME=/usr/java/j2sdk1.4.0 JDBC_HOME=/usr/share/pgsql/ PATH=$PATH:${JAVA_HOME}/bin CLASSPATH=$CLASSPATH:${JAVA_HOME}/lib:${JDBC_HOME}/lib/jdbc7.1-1.2.jar and I write to a sample.java for test programe.When I use javac to compile : javac sample.java --- is complete and then I use java to run this programe: java sample ---- is message Excepton caught. java.loang.ClassNotFoundException: org.postgresql.Driver Please you tell me about this problem. The second method to make a postgresql.jar : In my dataserve, I install is a PostgreSQL server, Java and Ant. When I build a drive. It can not to mak a postgresql.jar. Please you make this file to me and tell me about detail it. And I hope you to help me. Sincerity __________________________________________________ Do You Yahoo!? Great stuff seeking new owners in Yahoo! Auctions! http://auctions.yahoo.com
Can you send the code Dave -----Original Message----- From: pgsql-jdbc-owner@postgresql.org [mailto:pgsql-jdbc-owner@postgresql.org] On Behalf Of runway runable Sent: Tuesday, January 29, 2002 12:30 AM To: pgsql-jdbc@postgresql.org Subject: [JDBC] The question of jdbc Dear sir I'm interesting to use the PostgreSQL. In my concept, I have 2 server in a RedHat 7.2. The one is a webserver and the later is a dataserver. I read the document of PostgreSQL JDBC and practic it. It doesn't work . The Fist method: In mye webserver, I install the J2SDK1.4.0, the Tomcat-3.2.3.1noarch, a PostgreSQL-7.1.3-2 and the PostgresSQL-JDBC-7.1.3-2. By the way, I setup Path and ClassPath in the .bash_profile: JAVA_HOME=/usr/java/j2sdk1.4.0 JDBC_HOME=/usr/share/pgsql/ PATH=$PATH:${JAVA_HOME}/bin CLASSPATH=$CLASSPATH:${JAVA_HOME}/lib:${JDBC_HOME}/lib/jdbc7.1-1.2.jar and I write to a sample.java for test programe.When I use javac to compile : javac sample.java --- is complete and then I use java to run this programe: java sample ---- is message Excepton caught. java.loang.ClassNotFoundException: org.postgresql.Driver Please you tell me about this problem. The second method to make a postgresql.jar : In my dataserve, I install is a PostgreSQL server, Java and Ant. When I build a drive. It can not to mak a postgresql.jar. Please you make this file to me and tell me about detail it. And I hope you to help me. Sincerity __________________________________________________ Do You Yahoo!? Great stuff seeking new owners in Yahoo! Auctions! http://auctions.yahoo.com ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org
This message almost certainly means that the jdbc7.1-1.2.jar file is not in the classpath when you execute the program. The other likely possibility is that the driver name is mis-spelled. I'd suggest checking both of these possibilities out very carefully. In particular, make sure that the classpath doesn't get changed when the JVM is invoked. (I've seen this happen with Debian Linux.) -Nick > -----Original Message----- > From: pgsql-jdbc-owner@postgresql.org > [mailto:pgsql-jdbc-owner@postgresql.org]On Behalf Of runway runable > Sent: Tuesday, January 29, 2002 12:30 AM > To: pgsql-jdbc@postgresql.org > Subject: [JDBC] The question of jdbc > > > Dear sir > I'm interesting to use the PostgreSQL. In my > concept, I have 2 server in a RedHat 7.2. The one is a > webserver and the later is a dataserver. I read the > document of PostgreSQL JDBC and practic it. It > doesn't work . > The Fist method: In mye webserver, I install the > J2SDK1.4.0, the Tomcat-3.2.3.1noarch, a > PostgreSQL-7.1.3-2 and the PostgresSQL-JDBC-7.1.3-2. > By the way, I setup Path and ClassPath in the > .bash_profile : > JAVA_HOME=/usr/java/j2sdk1.4.0 > JDBC_HOME=/usr/share/pgsql/ > > PATH=$PATH:${JAVA_HOME}/bin > CLASSPATH=$CLASSPATH:${JAVA_HOME}/lib:${JDBC_HOME}/lib/jdbc7.1-1.2.jar > and I write to a sample.java for test programe.When I > use javac to compile : > javac sample.java --- is complete and then I use java > to run this programe: > java sample ---- is message > Excepton caught. > java.loang.ClassNotFoundException: > org.postgresql.Driver > Please you tell me about this problem. > > The second method to make a postgresql.jar : In my > dataserve, I install is a PostgreSQL server, Java and > Ant. When I build a drive. It can not to mak a > postgresql.jar. Please you make this file to me and > tell me about detail it. > And I hope you to help me. Sincerity > > > > > > > __________________________________________________ > Do You Yahoo!? > Great stuff seeking new owners in Yahoo! Auctions! > http://auctions.yahoo.com > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://archives.postgresql.org >