pg_group problem
Not sure what's going on but I have a problem using pg_group after creating a
group:
testschemas=# select * from pg_group;
groname | grosysid | grolist
---------+----------+---------
(0 rows)
testschemas=# create group testgrp_1 user foo,bar;
CREATE GROUP
testschemas=# select * from pg_group;
ERROR: cache lookup failed for type 2139062143
testschemas=# select * from pg_user;
usename | usesysid | usecreatedb | usesuper | usecatupd | passwd | valuntil | useconfig
----------+----------+-------------+----------+-----------+----------+----------+-----------
software | 1 | t | t | t | ******** | |
foo | 100 | f | f | f | ******** | |
bar | 101 | f | f | f | ******** | |
(3 rows)
testschemas=# select * from pg_group;
ERROR: cache lookup failed for type 2139062143
What's that all about?
Stopping and restarting the backend doesn't make the select of pg_group work,
unsurprisingly.
Okay, narrowed it down to adding users to a group I think. In a fresh build
and install from anoncvs:
testschemas=# create group mytest_grp;
CREATE GROUP
testschemas=# select * from pg_group;
groname | grosysid | grolist
------------+----------+---------
mytest_grp | 100 |
(1 row)
testschemas=# alter group mytest_grp add user foo;
ALTER GROUP
testschemas=# select * from pg_group;
ERROR: cache lookup failed for type 2139062143
Is this something to do with the recent changes to array_in/out perhaps?
--
Nigel J. Andrews
Director
---
Logictree Systems Limited
Computer Consultants
On Fri, 30 Aug 2002, Nigel J. Andrews wrote:
...
testschemas=# alter group mytest_grp add user foo;
ALTER GROUP
testschemas=# select * from pg_group;
ERROR: cache lookup failed for type 2139062143Is this something to do with the recent changes to array_in/out perhaps?
One other thing, there appears to be no regression test for this situation
since I didn't get any failures in make check. I don't suppose make bigcheck
will show any either but I'm running it now.
--
Nigel J. Andrews
"Nigel J. Andrews" <nandrews@investsystems.co.uk> writes:
testschemas=# select * from pg_group;
ERROR: cache lookup failed for type 2139062143
Ugh, I see it too.
Is this something to do with the recent changes to array_in/out perhaps?
Probably. I'm on it.
regards, tom lane
"Nigel J. Andrews" <nandrews@investsystems.co.uk> writes:
Is this something to do with the recent changes to array_in/out perhaps?
Yup, it is. The special-purpose code for manipulating group membership
lists (which are just int4[]) hadn't got updated. Fix committed ---
thanks for the report!
One other thing, there appears to be no regression test for this situation
I think we have regression tests for users but not any for groups. Feel
free to contribute one ...
regards, tom lane
PS: bugs in CVS tip are probably more profitably discussed on -hackers
than on -general.