Hi all,
I've been trying to implement UPDATE and DELETE to work on subclasses.
I made some changes and it kinda seems to work. It works when I have no
WHERE condition. When I put a WHERE condition in, it seems to update the
wrong tuple, and then things go wierd...
pghack=# update a set aa='zzz' where oid=19286;
UPDATE 1
pghack=# select oid,* from a; oid | aa
-------+------19286 | aaaa19285 | zzz
(2 rows)
pghack=# update a set aa='zzz' where oid=19285;
ERROR: heap_update: (am)invalid tid
ERROR: heap_update: (am)invalid tid
pghack=# update a set aa='zzz';
ERROR: heap_update: (am)invalid tid
ERROR: heap_update: (am)invalid tid
This message seems to be something to do with a tuple being in an
"Invisible" state whatever that means.
The change I made was basicly to add an "inh" parameter to
setTargetTable which I pass on down to addRangeTableEntry. From there I
expect it to be passed on to the executor and as I said it seems to work
ok without a where clause.
The patch is here. Any suggestions on where to start looking?
ftp://ftp.tech.com.au/pub/patch.only2
--
Chris Bitmead
mailto:chris@bitmead.com