Re: New to Glassfish with PostgreSQL



csharpdotcom wrote:
Hi - I've been using JSF with Glassfish successfully for the last few
months, but up to now have not tried to use databases with it, which
I'm now trying for the first time. Before I try writing any code, I
wanted to test out the code in chapter 10 of "Core JavaServer Faces"
to see if database access works with my configuration, and it does
not!

I configured the server as given in the book, and specified the JNDI
name as "jdbc/mydb", and compiled the code provided, created a war
file and deployed it. Online I found a file called
"postgresql-8.3dev-601.jdbc4.jar.zip", copied it to my "/glassfish/
domains/domain1/lib/ext/" folder, as instructed and started the server
and the application. However, after starting the application and
attempting to log in on its test page, I get the "Internal Error"
message produced by the code. In checking the log at localhost:4848 I
get various error messages saying that the connection was refused,
including that I should check TCP/IP.

Could someone kindly advise me on what is going wrong, as until I can
get an example running from the book, I can't go any further. The book
says on page 466 that I first have to create a table with a few
entries, with an example given, but nothing is said as to how I can do
that.

Some help would be most appreciated.

The error seems to indicate that there is nothing wrong with your JDBC driver but it just can't connect to a PostgreSQL database server. Is that up and running and did you configure the correct JDBC connection URL?

Regards,

Silvio Bierman
.



Relevant Pages

  • Re: How to Distribute a New Version
    ... about preserving the test data that your users have already entered. ... The agency stuck me> with doing this project even though I am a legal assistant, not a database> developer! ... > Looks like I am stuck spending hours on the phone doing it the hard way> having users import tables, do append queries to add the data to the new> tables and then deleting the old tables. ... Front end has a "first time run" routine that>> establishes the links to the back end file automatically when first run. ...
    (microsoft.public.access.gettingstarted)
  • Re: SetOption "Default Database Directory"
    ... As I said it works except for the first time the database opens and is set ... even with the rowsource problem solved. ... Database and reopen it and the form, ...
    (microsoft.public.access.formscoding)
  • Re: Storing Password
    ... allow to create their password the first time they use the program. ... file, the Registry, etc.) there's always a chance a user could delete it. ... could store the password in the database itself, ... you could save the file to a network folder for ...
    (microsoft.public.vb.general.discussion)
  • Upgrading a databse to ms access 2007? Help
    ... I have a ms access 2003 database that I would like to ... The first time I opened I had to fix a few ... I have tried to run it as a 2003 file and as a converted accdb file, ... show every thing but then the list disappears and only the first one ...
    (comp.databases.ms-access)
  • Re: Capture of First Use Date
    ... Here is another alternative done completely within the database. ... created when the main form opens. ... the first time the application is used. ... >> Where do you want to store it? ...
    (microsoft.public.access.forms)