Re: error tryiing to insert with collate - Mailing list pgsql-novice

From Jean-Yves F. Barbier
Subject Re: error tryiing to insert with collate
Date
Msg-id 20120102170201.696b31a7@anubis.defcon1
Whole thread Raw
In response to Re: error tryiing to insert with collate  (Thom Brown <thom@linux.com>)
List pgsql-novice
On Mon, 2 Jan 2012 15:22:19 +0000
Thom Brown <thom@linux.com> wrote:

Oops, strange: often my answer goes to ML goes only to sender;
back in the loop.

>
> I suspect you have char or varchar fields you're inserting those text
> values into that are smaller than the values you're attempting to
> insert into them.

Wrong hunch:
INSERT INTO tst1m VALUES (default,
    'źŠÿǚŦÏÔćÍĊĜÿG' COLLATE "hu_HU.utf8",
    'úĽčŏUĶďeźİīŇč' COLLATE "hu_HU.utf8" );
ERROR:  unsupported node type: 325

Anyway the columns are large enough to cope with these strings (32 & 64)
as they are copy from an existing row.

>  In any case, it's not a helpful error you've been
> given back so that should be improved.

Yep, I seeked gogol for that and only get a very few answers, most of
them linking to PG source or unrelated.

> What do you get if you perform the exact same INSERT without the COLLATE parts?

Works (of course, see above) perfectly:
INSERT INTO tst1m VALUES ( default,
    'źŠÿǚŦÍÏÔJŽććżûŘäpèăîÍŢŃDµŴŻĊĜÿG' ,
    'úĽčŏṻŗĿÁťħĵŇğŚáÛĨæħŽīhĴÝUĶďeźİīŇč'  );
INSERT 0 1

JY
--
Love is the only game that is not called on account of darkness.
        -- M. Hirschfield

pgsql-novice by date:

Previous
From: Thom Brown
Date:
Subject: Re: error tryiing to insert with collate
Next
From: Sergio Sinuco
Date:
Subject: Lock while delete a table