ERROR: cannot find attribute 1 of relation pg_temp
ERROR: cannot find attribute 1 of relation pg_temp
От:
Vladimir Sakhovsky <sakhovsky@gmd.de>
Дата:
Hi, When I vacuuming database I'm getting this error: $vacuumdb --analyze mydatabase ERROR: cannot find attribute 1 of relation pg_temp.13435.0 vacuumdb: database vacuum failed on mydatabase How this can be fixed? I'm running on RadHat 6.2, Postgresql-6.5.3-6. Any help would be appreciated, Vladimir Sakhovsky
Re: ERROR: cannot find attribute 1 of relation pg_temp
От:
Bruce Momjian <pgman@candle.pha.pa.us>
Дата:
Looks like a temp table that lost it's pg_attribute entry. Try dropping pg_temp.13435 and see if that helps. > Hi, > > When I vacuuming database I'm getting this error: > > $vacuumdb --analyze mydatabase > > ERROR: cannot find attribute 1 of relation pg_temp.13435.0 > vacuumdb: database vacuum failed on mydatabase > > How this can be fixed? > > I'm running on RadHat 6.2, Postgresql-6.5.3-6. > > Any help would be appreciated, > > Vladimir Sakhovsky > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 853-3000 + If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania 19026
Function overloading
От:
Rynell Wesson <rwesson@cs.utexas.edu>
Дата:
I have tried to overload a function with the following signatures.
CREATE FUNCTION foo(int4, int4)
RETURNS NUMERIC AS '
CREATE FUNCTION foo(text, text)
RETURNS NUMERIC AS '
Can someone please tell me how to make these overloaded functions work
at the same time? I keep getting the following error.
psql:fdm:11: ERROR: Function 'foo(unknown, unknown)' does not exist
Unable to identify a function that satisfies the given argument types
You may need to add explicit typecasts
The foo(text, text) works just fine alone when I do not compile/store the
foo(int4, int4) procedure in the database together with it. The
foo(int4, int4) procedure works regardless of whether I compile/store the
foo(text, text) procedure together with it in the database. The error
message seems to be complaining about the foo(text, text) procedure. I
have tried the following typecasts and format conversions to see if it
would accept it, but still with no success. Maybe I am casting the
types incorrectly. Can someone help me out?
select foo((text) 'testing', (text) 'testing');
select foo((varchar) 'testing', (varchar) 'testing');
select foo(text('testing'), text('testing'));
select foo(varchar('testing'), varchar('testing'));
... and others that did not work....
Here is the output of \df foo
List of functions
Result | Function | Arguments
---------+----------+------------
numeric | foo | int4 int4
numeric | foo | text text
(2 rows)
Additional info:
Operating System: Linux 2.2.16 #1 SMP i686
Postgres version: 7.0.2
Thanks.
Rynell Wesson