Re: pgsql: Coerce 'unknown' type parameters to the right type in the - Mailing list pgsql-committers

From Tom Lane
Subject Re: pgsql: Coerce 'unknown' type parameters to the right type in the
Date
Msg-id 19030.1282139839@sss.pgh.pa.us
Whole thread Raw
In response to pgsql: Coerce 'unknown' type parameters to the right type in the  (heikki@postgresql.org (Heikki Linnakangas))
Responses Re: pgsql: Coerce 'unknown' type parameters to the right type in the  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
List pgsql-committers
heikki@postgresql.org (Heikki Linnakangas) writes:
> Log Message:
> -----------
> Coerce 'unknown' type parameters to the right type in the fixed-params
> parse_analyze() function. That case occurs e.g with PL/pgSQL
> EXECUTE ... USING 'stringconstant'.

> The coercion with a CoerceViaIO node. The result is similar to the coercion
> via input function performed for unknown constants in coerce_type(),
> except that this happens at runtime.

Unfortunately, this entirely fails to enforce the rule that an unknown
Param be coerced the same way everywhere.  You'd need a cleanup pass as
well, cf check_variable_parameters().

            regards, tom lane

pgsql-committers by date:

Previous
From: heikki@postgresql.org (Heikki Linnakangas)
Date:
Subject: pgsql: Coerce 'unknown' type parameters to the right type in the
Next
From: Heikki Linnakangas
Date:
Subject: Re: pgsql: Coerce 'unknown' type parameters to the right type in the