Re: [GENERAL] Different encoding for string values and identifier strings? Or (select 'tést' as tést) returns different values for string and identifier...

From: "Francisco Figueiredo Jr(dot)" <francisco(at)npgsql(dot)org>
To: Andreas Kretschmer <akretschmer(at)spamfence(dot)net>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] Different encoding for string values and identifier strings? Or (select 'tést' as tést) returns different values for string and identifier...
Date: 2011-03-15 18:25:56
Message-ID: AANLkTin2n5P9yKER+REVQM7R511JqsaO7hKiGVBRacPA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

This is the query our user sent as one of the problems:

select "zurück" as zurück3_103_ from "Tabelle" tabellenhib0_

And here is the link to our bug report:

http://pgfoundry.org/tracker/index.php?func=detail&aid=1010988&group_id=1000140&atid=590

I didn't test putting double quotes in the column name identifier as
the bug report isn't using it.

What happens if you remove the double quotes in the column name identifier?

Thanks in advance.

On Tue, Mar 15, 2011 at 15:21, Andreas Kretschmer
<akretschmer(at)spamfence(dot)net> wrote:
> Francisco Figueiredo Jr. <francisco(at)npgsql(dot)org> wrote:
>
>> Hi all!
>>
>> I received a bug report about problems with identifiers.
>>
>> If I do the following select:
>>
>> select 1 as tést
>>
>> The column name returned contains strange chars.
>>
>> If I do:
>>
>> select 'tést' as tést
>>
>> the select value returned is ok but the column name is not. :(
>>
>> Is there any configuration I need to change to specify the encoding of
>> the identifiers?
>
> test=# select 'tést' as "tést";
>  tést
> ------
>  tést
>
> looks okay for me ...
>
>
> Andreas
> --
> Really, I'm not out to destroy Microsoft. That will just be a completely
> unintentional side effect.                              (Linus Torvalds)
> "If I was god, I would recompile penguin with --enable-fly."   (unknown)
> Kaufbach, Saxony, Germany, Europe.              N 51.05082°, E 13.56889°
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

--
Regards,

Francisco Figueiredo Jr.
Npgsql Lead Developer
http://www.npgsql.org
http://fxjr.blogspot.com
http://twitter.com/franciscojunior

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Raymond O'Donnell 2011-03-15 18:26:13 Re: How to add hosts to pg_hba.conf and postgresql.conf?
Previous Message Andreas Kretschmer 2011-03-15 18:21:18 Re: Different encoding for string values and identifier strings? Or (select 'tést' as tést) returns different values for string and identifier...