Error connecting database
Connection to database failed
connectDB() failed: Is the
postmaster running and
accepting TCP/IP (with -i)
connections at 'localhost' on
port '5432'?
This usually occurs because the "postmaster" (the postgreSQL backend) was not started with the -i option. Usually just adding -i to the command line that starts the postmaster and restarting will fix this.
If you have installed the prewritten script to start postgreSQL automatically, this option is (currently) commented out:
# PGOPTS="-i"
just remove the hash and space and comment out the "blank" option above:
PGOPTS=""
Error connecting database
See User Administration in the PgAccess tutorial for a description
of how to create users.
ftp://ftp.flex.ro/pub/pgaccess
is one place that you can download precompiled libpgtcl libraries for
PgAccess.
One solution was proposed by H.P.Heidinger ( hph@hphbbs.ruhr.de) and
is very simple.
If you look in the file pgaccess.tcl, you will find the fonts declared in
this manner:
$ grep -e '-font' -i pgaccess.tcl
-font -Adobe-Helvetica-Medium-R-Normal-*-*-120-*-*-*-*-iso8859-1
That is, inserting an asterisk between the first pair of hyphens, and changing
the final two asterisks to iso8859 and 1
respectively.
You can alter the source code by running the following script :
#!/bin/sh
The final version of PgAccess (1.0) will let the user decide what fonts
will be used through a "preferences" dialog window.
In the procedure wpg_exec change the following line:
set pgsql(errmsg) [pg_result $pgsql(res) -error]
to this:
set pgsql(errmsg) "NO ERROR INFORMATION SUPPLIED"
and the program will work. The only disadvantage is that with some error
conditions, you will not get the appropriate error message from libpgtcl.User not defined
Initially, postgreSQL only has one user, postgres, and any
other user who starts up PgAccess will get the message:
Connection to database failed
FATAL 1: SetUserId: user
'jim' is not in 'pg_shadow'libpgtcl not found
PgAccess requires a library of functions named libpgtcl. This
should be available with the postgreSQL distribution, and is usually placed in
the correct location when installing postgreSQL. First check that there is a
file named libpgtcl.so (perhaps with a number appended - or
libpgtcl.dll on Windows systems) on your
system. If not, you will have to download and perhaps compile this library.Locale specific characters
This problem occurs with some special characters used in different
countries because PgAccess did not use fonts with `-ISO8859-1' encoding.
-font -Adobe-Helvetica-Medium-R-Normal--*-120-*-*-*-*-*-* \
...
...
cp pgaccess.tcl pgaccess.tcl-org
cat pgaccess.tcl |\
sed -e's/\-\*\-\*\ /\-iso8859\-1\ /g' |\
sed -e's/\-\*\-\*\}/\-iso8859\-1}/g' |\
sed -e's/\-\*\-\*\]/\-iso8859\-1]/g' |\
sed -e's/\-\*\-\*$/\-iso8859\-1/g' |\
sed -e's/\-Clean\-/\-Fixed\-/g' |\
sed -e's/clean/fixed/g' >pgaccess.iso
mv pgaccess.iso pgaccess.tcl
chmod +x pgaccess.tclProblem with PostgreSQL 6.3.x
PgAccess 0.93 and later may have problems working with PostgreSQL 6.3.x.
Changes in libpgtcl have been made to remove these, but if you are
using PostgreSQL 6.3.x, this patch will allow you to get around the problems.