On Thu, Dec 19, 2002 at 03:23:34PM +0000, Dominic Mitchell wrote:
> Tim Bunce wrote:
> >Maybe drivers could use something like
> >
> >     $sth->bind_col( 1, \$foo, { CharSet => ... } );
> >
> >to indicate that a column is UTF8.
> 
> It's a little bit simpler than that, because the charsets other than 
> UTF-8 will "just work".

Depends on your definition of "just work".

> UTF-8 is the only one that perl has a special 
> flag for internally.  The rest are just bags 'o' bytes.
> 
> Have a look at the documentation of the Encode module for details.

Sure. My point was that
        $sth->bind_col( 1, \$foo, { CharSet => ... } );

is a general API. It can be used to at least recognise utf8, but
could also optionally *recode other charsets* into some desired
local encoding, like utf8 or something else:

        $dbh->{CharSet} => 'koi8_ru';

Tim.

Reply via email to