| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Howard Cole <howardnews(at)selestial(dot)com> |
| Cc: | "'PgSql General'" <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Query Help |
| Date: | 2007-01-19 18:52:39 |
| Message-ID: | 17899.1169232759@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Howard Cole <howardnews(at)selestial(dot)com> writes:
> If I try the following query:
> delete from operator where operator_id=283;
> I get the following error message:
> ERROR: could not open relation with OID 438427
> SQL state: XX000
> Context: SQL statement "UPDATE ONLY "public"."timesheet_booking" SET
> "operator_id" = NULL WHERE "operator_id" = $1"
It looks like you have a stale plan for that ON DELETE SET NULL
constraint. Was there perhaps an index on operator_id that you removed?
Postgres is not very good about flushing cached plans when you change
table schemas (something I hope will be fixed in 8.3).
If that is the problem, starting a fresh session would be enough to take
care of it.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Richard Troy | 2007-01-19 18:58:38 | Re: Spam from EnterpriseDB? |
| Previous Message | Merlin Moncure | 2007-01-19 18:51:18 | Re: Spam from EnterpriseDB? |