Dmitry Iv Popov <[EMAIL PROTECTED]> wrote:

 > how do I make my DB accessible from the Web (via JDBC)?  With what
 > parameters should I call 'Class.forName()' and
 > 'DriverManager.getConnection()' in case of PostgreSQL?

The following is quoted from 

  ".../pgsql/src/interfaces/jdbc/example/basic.java":

    // Load the driver
    Class.forName("postgresql.Driver");
    
    // Connect to database
    System.out.println("Connecting to Database URL = " + url);
    db = DriverManager.getConnection(url, usr, pwd);

`url' could be "localhost:postgresql:rscexamdb", e.g. If your program
can't find the driver class, you maybe have forgotten to put it into
the CLASSPATH:

   declare -x CLASSPATH=$CLASSPATH:./:/usr/local/lib/java/postgresql.jar 

(or equivalents, depends on your shell; valid only, if file
"postgresql.jar" is in "/usr/local/lib/java", of course).

In the jdbc driver directory (".../src/interfaces/jdbc", see above)
you'll find a README telling you something about building, installing
and using the driver.

Hope it helps,
Ulf

P.S.: 

 > P.S.: you can write me in russian - it's my native lang. :)

unfortunately not mine ;-)

-- 
======================================================================
 %%%%%            Ulf Mehlig              <[EMAIL PROTECTED]>
   %%%%!%%%       Projekt "MADAM"         <[EMAIL PROTECTED]>
%%%% %!% %%%%     ----------------------------------------------------
 ---| %%%         MADAM:  MAngrove    |  Center for Tropical Marine
    ||--%!%              Dynamics     |  Biology
    ||                  And           |  Fahrenheitstrasse 1
 _ /||\_/\_            Management     |  
/  /    \  \ ~~~~~~~~~~~~~~~~~        |  28359 Bremen/Germany
  ~~~~~~~~~~~~~~~~~~~~

Reply via email to