Re: ERROR: cache lookup failed for type 0 - Mailing list pgsql-general

From Tom Lane
Subject Re: ERROR: cache lookup failed for type 0
Date
Msg-id 6841.1105207005@sss.pgh.pa.us
Whole thread Raw
In response to Re: ERROR: cache lookup failed for type 0  (Greg Stark <gsstark@mit.edu>)
List pgsql-general
Greg Stark <gsstark@mit.edu> writes:
> Tom Lane <tgl@sss.pgh.pa.us> writes:
>> You didn't palloc the values array.  Any reasonable compiler would have
>> warned you about that BTW.  If you don't have compiler warnings enabled,
>> learn to use them.

> I think with gcc this type of warning is only enabled when you're compiling
> with optimizations. Most people don't compile with optimizations enabled when
> developing.

Pretty much the first thing you learn when developing with gcc is to use
-O1 -Wall for compiling devel code.  Gets all the warnings and doesn't
confuse gdb too badly.  Once in a long while I'll recompile an
individual file with -O0 so that I can single-step through it more
easily, but 99.44% of the time I'd rather have the
uninitialized-variable warning.

            regards, tom lane

pgsql-general by date:

Previous
From: Greg Stark
Date:
Subject: Re: ERROR: cache lookup failed for type 0
Next
From: Tzahi Fadida
Date:
Subject: Is it possible to measure IO costs of a query in postgreSQL?