Re: Lexing with different charsets - Mailing list pgsql-hackers

From Fabien COELHO
Subject Re: Lexing with different charsets
Date
Msg-id Pine.LNX.4.58.0404141021330.7237@sablons.cri.ensmp.fr
Whole thread Raw
In response to Re: Lexing with different charsets  (Dennis Bjorklund <db@zigo.dhs.org>)
Responses Re: Lexing with different charsets  (Dennis Bjorklund <db@zigo.dhs.org>)
List pgsql-hackers
> > I cannot see where I could use such a feature.
>
> Applications usually generate queries.

Sure.

> So you can do things like
>
> printf ("SELECT * FROM foo WHERE field1 = _latin1'%s';", my_latin1_data);

Hmmm... I guess the following was too complicated. You need a library
for conversion. You need to take care of conversions.

printf("SELECT * FROM foo WHERE field1 = '%s'",      latin1_to_database_encoding(...));


Well, so this is a great new useful feature indeed, that will help improve
the lexer code a lot;-)

Good luck,

-- 
Fabien Coelho - coelho@cri.ensmp.fr


pgsql-hackers by date:

Previous
From: Dennis Bjorklund
Date:
Subject: Re: Lexing with different charsets
Next
From: Dennis Bjorklund
Date:
Subject: Re: Lexing with different charsets