agora inbox for pgsql-sql@postgresql.org  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Voillequin, Jean-Marc <Jean-Marc.Voillequin@moodys.com>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: pgsql-bugs@lists.postgresql.org
Cc: pgsql-sql@lists.postgresql.org
Subject: Re: Weird "could not determine which collation to use for string comparison" with LEAST/GREATEST on PG11 procedure
Date: Wed, 21 Nov 2018 13:19:20 -0500
Message-ID: <12249.1542824360@sss.pgh.pa.us> (raw)
In-Reply-To: <1EC8157EB499BF459A516ADCF135ADCE39FFAC54@LON-WGMSX712.ad.moodys.net>
References: <1EC8157EB499BF459A516ADCF135ADCE39FFAC54@LON-WGMSX712.ad.moodys.net>

"Voillequin, Jean-Marc" <Jean-Marc.Voillequin@moodys.com> writes:
> SIMPLE=> create or replace procedure same_values_proc(a text, b text) as $body$
> SIMPLE$> begin
> SIMPLE$>        assert a = b;
> SIMPLE$> end;$body$ language plpgsql;
> CREATE PROCEDURE
> SIMPLE=>
> SIMPLE=> call same_values_proc(least('a','b'),'a');
> ERROR:  could not determine which collation to use for string comparison
> HINT:  Use the COLLATE clause to set the collation explicitly.

Yeah, same here.  I think somebody forgot to run assign_expr_collations()
on CALL arguments.

			regards, tom lane




view thread (5+ messages)  latest in thread

Message-ID: <12249.1542824360@sss.pgh.pa.us>
Permalink:  ../12249.1542824360@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/12249.1542824360@sss.pgh.pa.us

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, Jean-Marc.Voillequin@moodys.com, peter.eisentraut@2ndquadrant.com, pgsql-bugs@lists.postgresql.org, pgsql-sql@lists.postgresql.org
  Subject: Re: Weird "could not determine which collation to use for string comparison" with LEAST/GREATEST on PG11 procedure
  In-Reply-To: <12249.1542824360@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox