Postgresql-Perl -->PQexec() -- there is no connection to the backend

From: JESUS AVILA MOLINA <avimolje(at)tuguri(dot)eupmt(dot)es>
To: pgsql-sql(at)postgresql(dot)org
Cc: pgsql-general(at)postgresql(dot)org
Subject: Postgresql-Perl -->PQexec() -- there is no connection to the backend
Date: 1998-06-15 06:51:33
Message-ID: Pine.SOL.3.95.980615074202.3332D-200000@tuguri.eupmt.es
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-sql

Hello PostgreSQL LIST!

My name is Jesus Avila and I'm studying Telematics Engineering.
Nowadays I'm doing the final project of the speciality and
it consists of managing the PostgreSQL through PERL language
using the Apache Server in RedHat.
The problem I have is the following:
* Everytime I try to access to the database, in a file where I
keep all the traces I find this:

UW PICO(tm) 2.9 File: pgtrace.out

PQexec() -- There is no connection to the backend.

The system is the following. I have a form in an .html file who
calls the CGI 'proba.pl' to insert the data into the data base.
The program who makes the error is attached (it's name is proba.pl).
The same error appears when I do "INSERT" and also when I do "SELECT".
In it you can see the path from the pgtrace.out and how I create it.
Could you help me? I'm desperate! I don't know how can i solve
the problem! Thank you very much in advance!

The Following things are some data that I've considered
in order to help to try to solve my problem. I have only two
weeks left to finish the project and I need the database
functioning for yesterday. So please, could you help me.
I'll be very grateful for your help.
Thank you very much in advance.

Version of the programs I use!!!
-----------------------------------

PosgreSQL version 6.3 (postgresql-6.3.2.tar.gz)
PERL version 5.004 patch 1
RedHat 5.0
Server version Apache/1.2.4.

* Accessing to the database typing "psql proba" functions, I can
INSERT, DELETE, CREATE TABLE, ...
* The database "postgres" is created.
* When I type postgres, those are the things that appears on the screen:

[postgres(at)localhost pgsql]$ postgres

---debug info---
Quiet = f
Noversion = f
timings = f
dates = Normal
bufsize = 64
sortmem = 512
query echo = f
DatabaseName = [postgres]
----------------

InitPostgres()..

POSTGRES backend interactive interface
$Revision: 1.67 $ $Date: 1998/02/26 04:36:31 $
>

-> What is the meaning of that?
-> and Which are the things you can do with that?

The configuration of the file ".bash_profile"!!!
------------------------------------------------
PATH=$PATH:$HOME/bin
ENV=$HOME/.bashrc
USERNAME="postgres"

export USERNAME ENV PATH

PATH=$PATH:/usr/local/pgsql/bin
MANPATH=$MANPATH:/usr/local/pgsql/man
PGLIB=/usr/local/pgsql/lib
PGDATA=/usr/local/pgsql/data
export PATH MANPATH PGLIB PGDATA

nohup postmaster -d > server.log 2>&1 &

If I open the file "server.log" the things I find are the folliwing:
--------------------------------------------------------------------

FindBackend: searching PATH ...
FindBackend: found "/usr/local/pgsql/bin/postgres" using PATH

The implementation of the database i try to access!!!
-----------------------------------------------------

Database = proba
+------------------+----------------------------------+----------+
| Owner | Relation | Type |
+------------------+----------------------------------+----------+
| postgres | dada | table |
+------------------+----------------------------------+----------+

Table = dada
+----------------------------------+-----------------------------+-------+
| Field | Type | Length|
+----------------------------------+-----------------------------+-------+
| nom | varchar() | 40 |
| cog1 | varchar() | 40 |
| cog2 | varchar() | 40 |
| edat | int2 | 2 |
| sexe | varchar() | 4 |
+----------------------------------+-----------------------------+-------+

GRANT select,insert,delete,update ON dada TO nobody;

Thank you very much another time !!!
--------------------------------

Attachment Content-Type Size
proba.pl text/plain 2.6 KB

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dwight Johnson 1998-06-15 08:23:21 Re: [SQL] Postgresql-Perl -->PQexec() -- there is no connection to the backend
Previous Message Stefan Welzmiller 1998-06-15 03:39:12 Problem creating a DB under 6.3.2 and Linux 2.00.33

Browse pgsql-sql by date

  From Date Subject
Next Message Dwight Johnson 1998-06-15 08:23:21 Re: [SQL] Postgresql-Perl -->PQexec() -- there is no connection to the backend
Previous Message SQYang 1998-06-15 02:41:42