Hi David
On 08/02/14 03:45, David E. Wheeler wrote:
On Feb 7, 2014, at 3:59 AM, Peter J. Holzer wrote:
o Decoding incoming data
$$item{$_} = decode('utf-8', $$item{$_} || '') for keys %$item
Same here. With pg_enable_utf8 I would expect to get character strings,
not byte strings, so no deco
On Feb 7, 2014, at 3:59 AM, Peter J. Holzer wrote:
>> o Decoding incoming data
>> $$item{$_} = decode('utf-8', $$item{$_} || '') for keys %$item
>
> Same here. With pg_enable_utf8 I would expect to get character strings,
> not byte strings, so no decode should be necessary.
With 3.0.0, if you h
Hi Peter
I've written a demo using MySQL and will shortly expand it to Pg and
SQLite, and then blog about it, either on this list or blogs.perl.org.
It stores a string in both encoded and unencoding forms, and retrieves it.
On 07/02/14 22:59, Peter J. Holzer wrote:
On 2014-02-06 12:30:15 +1
On 2014-02-06 12:30:15 +1100, Ron Savage wrote:
> 'Major change in UTF-8 handling' is right. I was:
I haven't checked the docs yet, just my gut feeling how it should work.
> o Declaring the Pg db as utf8
I guess this means setting pg_enable_utf8?
> o Encoding outgoing data
> Eg: map{($_ => en
Hi Tim
On 06/02/14 23:48, Tim Bunce wrote:
On Thu, Feb 06, 2014 at 12:30:15PM +1100, Ron Savage wrote:
Eg: map{($_ => encode('utf-8', $$hashref{$_}) )} keys %$hashref
$$item{$_} = decode('utf-8', $$item{$_} || '') for keys %$item
Performance tip: using the function form of encode() and decod
On Thu, Feb 06, 2014 at 12:30:15PM +1100, Ron Savage wrote:
> Eg: map{($_ => encode('utf-8', $$hashref{$_}) )} keys %$hashref
> $$item{$_} = decode('utf-8', $$item{$_} || '') for keys %$item
Performance tip: using the function form of encode() and decode()
is significantly slower than using the m
Hi
'Major change in UTF-8 handling' is right. I was:
o Declaring the Pg db as utf8
o Encoding outgoing data
Eg: map{($_ => encode('utf-8', $$hashref{$_}) )} keys %$hashref
o Decoding incoming data
$$item{$_} = decode('utf-8', $$item{$_} || '') for keys %$item
o Using on my web page
And eac
-BEGIN PGP SIGNED MESSAGE-
Hash: RIPEMD160
Version 3.0.0 of DBD::Pg, the Perl interface to Postgres,
has just been released. As you can see from the version
number, this is a major release. In addition to many
bugfixes and enhancements, the behavior of pg_enable_utf8
has been changed.