Re: problem name database - Mailing list pgadmin-support

From Andreas Pflug
Subject Re: problem name database
Date
Msg-id 416D7F07.9020009@pse-consulting.de
Whole thread Raw
In response to problem name database  (frank_lupo <frank_lupo@email.it>)
List pgadmin-support
frank_lupo wrote:
> Hi all,
> 
> I have create database èèèè not "èèèè".
> When I click on dabatabase èèèè in tree pgadmin3 show error: database "____"
> does not exist

Uuu, this was a really bad one.
The name of the database as displayed depends on the encoding used when 
the database was created, and the database used when retrieving the 
database information. Unfortunately, we can't know this at connect time, 
so we have to guess.

In your case, you obviously created the database over a Unicode 
connection, so it's stored as "èèèè". If you do SELECT * from 
pg_database on a Unicode connection again, you'll get "èèèè", a 
SQL_ASCII connection (usually template1) you see that encoded string.

While connecting, we only tried without Unicode conversion. I've added a 
second try now.

Additionally, the name may be even unreadable. This can happen if you 
create the database using SQL_ASCII (even if the DB itself is UNICODE). 
In that case, it's impossible to retrieve the pg_database row, because 
its content is illegal for unicode.

cvs patch committed, new snapshot to come.

Regards,
Andreas


pgadmin-support by date:

Previous
From: frank_lupo
Date:
Subject: problem name database
Next
From: Tim Booth
Date:
Subject: pgadmin3 beta2 connect to 7.3.4 server