FATAL 1: Database dbname=template1 does not exist in pg_database
FATAL 1: Database dbname=template1 does not exist in pg_database
От:
Carsten Huettl <chuettl@ahorn-Net.de>
Дата:
Hello again, When I ty to access my pgsql with apache and php3 I got the following error: FATAL 1: Database dbname=template1 does not exist in pg_database When I connect with psql I can see template1. How do I insert template1 into pg_database? TIA C.
Re: [GENERAL] FATAL 1: Database dbname=template1 does not exist in pg_database
От:
Andrew McMillan <Andrew@catalyst.net.nz>
Дата:
Carsten Huettl wrote:
>
> Hello again,
>
> When I ty to access my pgsql with apache and php3 I got the following
> error:
>
> FATAL 1: Database dbname=template1 does not exist in pg_database
> When I connect with psql I can see template1.
>
> How do I insert template1 into pg_database?
Looks like you're using the wrong syntax for pg_open?
Try:
$template_db = pg_Connect("dbname=template1");
or:
$template_db = pg_Connect("", "", "", "", "template1");
Cheers,
Andrew.
--
_____________________________________________________________________
Andrew McMillan, e-mail: Andrew@cat-it.co.nz
Catalyst IT Ltd, PO Box 10-225, Level 22, 105 The Terrace, Wellington
Me: +64 (21) 635 694, Fax: +64 (4) 499 5596, Office: +64 (4) 499 2267
How to install perl module without root access
От:
Ryan Ho <ryanho@pacific.net.sg>
Дата:
Hi, I am using a shared web server with a web hosting company. We have no root access. I know it is possible to compile and install postgreSQL even without root access but is it possible to install the perl module Pg without root access? Is it possible to install and run it off a local directory in which I have access rights? I heard about the perl -I option but I don't know if it would work in this case. Thanks in Advance Ryan
Re: [GENERAL] FATAL 1: Database dbname=template1 does not exist in pg_database
От:
Carsten Huettl <chuettl@ahorn-Net.de>
Дата:
Andrew McMillan schrieb: > > > FATAL 1: Database dbname=template1 does not exist in pg_database > > When I connect with psql I can see template1. > > > > How do I insert template1 into pg_database? In the meantime I figured out, was was going wrong with my postgresql installation. I made a big mistake configuring the config.inc.php3 file There I had wrong entries for user and stduser. After correcting this phpPGadmin work quite well. C.
Re: [GENERAL] FATAL 1: Database dbname=template1 does not exist in pg_database
От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
Carsten Huettl writes: > When I ty to access my pgsql with apache and php3 I got the following > error: > FATAL 1: Database dbname=template1 does not exist in pg_database > When I connect with psql I can see template1. > How do I insert template1 into pg_database? Read it again: the error message is complaining because you tried to access a database named "dbname=template1". Better check the syntax on the connection subroutine you are using --- looks like a confusion between positional parameters and keyword-style connect strings... regards, tom lane