Re: BUG #2811: Error determining param type in prepared statement of unused variable

From: Ross Cohen <rcohen(at)snurgle(dot)org>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2811: Error determining param type in prepared statement of unused variable
Date: 2006-12-06 23:48:04
Message-ID: 20061206234804.GW2749@snurgle.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Wed, Dec 06, 2006 at 05:55:32PM -0500, Tom Lane wrote:
> "Ross Cohen" <rcohen(at)snurgle(dot)org> writes:
> > PREPARE demo (unknown) AS SELECT 1;
> > ERROR: could not determine data type of parameter $1
>
> This doesn't seem like a bug to me. The parser needs to be able to
> resolve the types of any unknown parameters, and you've not given it
> enough information to do that.

It's not a bug, it's a feature request. It doesn't really need to be able
to resolve the type because the parameter will never be used. Yes, I'm being
lazy, it's possible for me to be more careful about what I pass in. On the
other hand, I think others would appreciate the ability to be this lazy,
as well.

Ross

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Markus Grabner 2006-12-07 01:40:37 BUG #2813: missing RPM build dependency: tcl-devel
Previous Message Tom Lane 2006-12-06 22:55:32 Re: BUG #2811: Error determining param type in prepared statement of unused variable