pg.ddx.io pgsql-interfaces@postgresql.org mailing list archive
help / color / mirror / Atom feedapplet
6+ messages / 2 participants
[nested] [flat]
* applet
@ 1998-10-14 14:44 Andrea Antibo <antibo@mclink.it>
0 siblings, 1 reply; 6+ messages in thread
From: Andrea Antibo @ 1998-10-14 14:44 UTC (permalink / raw)
To: pgsql-interfaces
Hi,
I'm writing un applet for my application with postgres but it don't load (I
think) jdbc driver.
I add in .hotjava/properties jdbc.drivers=postgresql.Driver.
try{
resultsTextArea.setText("elaborazione in corso");
Class.forName("postgresql.Driver");
String url = "jdbc:postgres:tesi";
String usr = "andrea";
String pwd = "";
db = DriverManager.getConnection(url, usr, pwd);
st = db.createStatement();
....
....
}
It jump this try block.
What I can do?
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [INTERFACES] applet
@ 1998-10-14 17:30 Peter T Mount <peter@retep.org.uk>
parent: Andrea Antibo <antibo@mclink.it>
0 siblings, 1 reply; 6+ messages in thread
From: Peter T Mount @ 1998-10-14 17:30 UTC (permalink / raw)
To: Andrea Antibo <antibo@mclink.it>; +Cc: pgsql-interfaces
Three things here:
1) The Class.forName() line isn't needed if you use the jdbc.drivers
property. It doesn't hurt, but not required.
2) The JDBC Url is wrong. it should read jdbc:postgresql:tesi
3) You may be having problems with the null password. If you are using
trust, or ident authentication (set in pg_hba.conf), then you could put
anything in here. Otherwise, use "Alter user" to set yourself a password,
and put it in here.
On Wed, 14 Oct 1998, Andrea Antibo wrote:
> Hi,
> I'm writing un applet for my application with postgres but it don't load (I
> think) jdbc driver.
> I add in .hotjava/properties jdbc.drivers=postgresql.Driver.
>
> try{
> resultsTextArea.setText("elaborazione in corso");
>
> Class.forName("postgresql.Driver");
>
> String url = "jdbc:postgres:tesi";
> String usr = "andrea";
> String pwd = "";
>
>
> db = DriverManager.getConnection(url, usr, pwd);
>
> st = db.createStatement();
>
> ....
> ....
> }
>
>
> It jump this try block.
> What I can do?
>
>
--
Peter T Mount peter@retep.org.uk
Main Homepage: http://www.retep.org.uk
PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
Java PDF Generator: http://www.retep.org.uk/pdf
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [INTERFACES] applet
@ 1998-10-15 15:08 Andrea Antibo <antibo@mclink.it>
parent: Peter T Mount <peter@retep.org.uk>
0 siblings, 0 replies; 6+ messages in thread
From: Andrea Antibo @ 1998-10-15 15:08 UTC (permalink / raw)
To: Peter T Mount <peter@retep.org.uk>; +Cc: pgsql-interfaces
On 14-Oct-98 Peter T Mount wrote:
>
> Three things here:
>
> 1) The Class.forName() line isn't needed if you use the jdbc.drivers
> property. It doesn't hurt, but not required.
if I cut the line from source code or from .hotjava/properties file I have this
error:
File not found when looking for: postgresql.Driver
> 3) You may be having problems with the null password. If you are using
> trust, or ident authentication (set in pg_hba.conf), then you could put
> anything in here. Otherwise, use "Alter user" to set yourself a password,
> and put it in here.
Ok, but when I wrote a application like basic.java exemple without password it
worked fine.
>
> On Wed, 14 Oct 1998, Andrea Antibo wrote:
>
>> Hi,
>> I'm writing un applet for my application with postgres but it don't load (I
>> think) jdbc driver.
>> I add in .hotjava/properties jdbc.drivers=postgresql.Driver.
>>
>> try{
>> resultsTextArea.setText("elaborazione in corso");
>>
>> Class.forName("postgresql.Driver");
>>
>> String url = "jdbc:postgres:tesi";
>> String usr = "andrea";
>> String pwd = "";
>>
>>
>> db = DriverManager.getConnection(url, usr, pwd);
>>
>> st = db.createStatement();
>>
>> ....
>> ....
>> }
>>
>>
>> It jump this try block.
>> What I can do?
>>
>>
>
> --
> Peter T Mount peter@retep.org.uk
> Main Homepage: http://www.retep.org.uk
> PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
> Java PDF Generator: http://www.retep.org.uk/pdf
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [INTERFACES] applet
@ 1998-10-15 15:19 Andrea Antibo <antibo@mclink.it>
0 siblings, 1 reply; 6+ messages in thread
From: Andrea Antibo @ 1998-10-15 15:19 UTC (permalink / raw)
To: Peter T Mount <peter@retep.org.uk>; pgsql-interfaces
On 14-Oct-98 Peter T Mount wrote:
>
> Three things here:
>
> 1) The Class.forName() line isn't needed if you use the jdbc.drivers
> property. It doesn't hurt, but not required.
if I cut the line from source code or from .hotjava/properties file I have this
error:
File not found when looking for: postgresql.Driver
> 3) You may be having problems with the null password. If you are using
> trust, or ident authentication (set in pg_hba.conf), then you could put
> anything in here. Otherwise, use "Alter user" to set yourself a password,
> and put it in here.
Ok, but when I wrote a application like basic.java exemple without password it
worked fine.
>
> On Wed, 14 Oct 1998, Andrea Antibo wrote:
>
>> Hi,
>> I'm writing un applet for my application with postgres but it don't load (I
>> think) jdbc driver.
>> I add in .hotjava/properties jdbc.drivers=postgresql.Driver.
>>
>> try{
>> resultsTextArea.setText("elaborazione in corso");
>>
>> Class.forName("postgresql.Driver");
>>
>> String url = "jdbc:postgres:tesi";
>> String usr = "andrea";
>> String pwd = "";
>>
>>
>> db = DriverManager.getConnection(url, usr, pwd);
>>
>> st = db.createStatement();
>>
>> ....
>> ....
>> }
>>
>>
>> It jump this try block.
>> What I can do?
>>
>>
>
> --
> Peter T Mount peter@retep.org.uk
> Main Homepage: http://www.retep.org.uk
> PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
> Java PDF Generator: http://www.retep.org.uk/pdf
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [INTERFACES] applet
@ 1998-10-15 17:26 Peter T Mount <peter@retep.org.uk>
parent: Andrea Antibo <antibo@mclink.it>
0 siblings, 1 reply; 6+ messages in thread
From: Peter T Mount @ 1998-10-15 17:26 UTC (permalink / raw)
To: Andrea Antibo <antibo@mclink.it>; +Cc: pgsql-interfaces
On Thu, 15 Oct 1998, Andrea Antibo wrote:
>
> On 14-Oct-98 Peter T Mount wrote:
> >
> > Three things here:
> >
> > 1) The Class.forName() line isn't needed if you use the jdbc.drivers
> > property. It doesn't hurt, but not required.
>
>
> if I cut the line from source code or from .hotjava/properties file I have this
> error:
>
> File not found when looking for: postgresql.Driver
It sounds like the properties file isn't actually being used.
> > 3) You may be having problems with the null password. If you are using
> > trust, or ident authentication (set in pg_hba.conf), then you could put
> > anything in here. Otherwise, use "Alter user" to set yourself a password,
> > and put it in here.
>
> Ok, but when I wrote a application like basic.java exemple without password it
> worked fine.
It can depend. In the past, I've found that most failed connections are
caused by null or empty ("") passwords.
--
Peter T Mount peter@retep.org.uk
Main Homepage: http://www.retep.org.uk
PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
Java PDF Generator: http://www.retep.org.uk/pdf
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [INTERFACES] applet
@ 1998-10-16 07:25 Andrea Antibo <antibo@mclink.it>
parent: Peter T Mount <peter@retep.org.uk>
0 siblings, 0 replies; 6+ messages in thread
From: Andrea Antibo @ 1998-10-16 07:25 UTC (permalink / raw)
To: Peter T Mount <peter@retep.org.uk>; +Cc: pgsql-interfaces
>> if I cut the line from source code or from .hotjava/properties file I have
>> this
>> error:
>>
>> File not found when looking for: postgresql.Driver
>
> It sounds like the properties file isn't actually being used.
Please read the message with subject "driver".
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~1998-10-16 07:25 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
1998-10-14 14:44 applet Andrea Antibo <antibo@mclink.it>
1998-10-14 17:30 ` Peter T Mount <peter@retep.org.uk>
1998-10-15 15:08 ` Andrea Antibo <antibo@mclink.it>
1998-10-15 15:19 Re: [INTERFACES] applet Andrea Antibo <antibo@mclink.it>
1998-10-15 17:26 ` Peter T Mount <peter@retep.org.uk>
1998-10-16 07:25 ` Andrea Antibo <antibo@mclink.it>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox