From: Tom Lane <tgl@sss.pgh.pa.us>
To: A. Kretschmer <andreas.kretschmer@schollglas.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: what exactly is a query structure?
Date: Fri, 26 Feb 2010 10:11:56 -0500
Message-ID: <27166.1267197116@sss.pgh.pa.us> (raw)
In-Reply-To: <20100226095358.GG11413@a-kretschmer.de>
References: <4B876F23.8040401@bankir.ru>
<4B879803.5020006@bankir.ru>
<20100226095358.GG11413@a-kretschmer.de>
"A. Kretschmer" <andreas.kretschmer@schollglas.com> writes:
> In response to silly sad :
>> my own wild guess:
>> string constant '*' is of type "unknown"
> Maybe. Add a explicit cast, for instance '*'::text
Definitely. More recent versions of PG provide a more explicit error
message:
regression=# SELECT * from get_noobs();
ERROR: structure of query does not match function result type
DETAIL: Returned type unknown does not match expected type text in column "pass".
CONTEXT: PL/pgSQL function "get_noobs" line 2 at RETURN QUERY
regards, tom lane
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, andreas.kretschmer@schollglas.com
Subject: Re: what exactly is a query structure?
In-Reply-To: <27166.1267197116@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 DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox