Skip site navigation (1) Skip section navigation (2)

Re: PG 8.3.3 - ERROR: lock AccessShareLock on object 16385/16467/0 is already held

From: Michael Milligan <milli(at)acmeps(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: PG 8.3.3 - ERROR: lock AccessShareLock on object 16385/16467/0 is already held
Date: 2008-08-29 22:44:22
Message-ID: 48B87BC6.5010901@acmeps.com (view raw or flat)
Thread:
Lists: pgsql-bugs

Tom Lane wrote:
> Michael Milligan <milli(at)acmeps(dot)com> writes:
>> Tom Lane wrote:
>>> Huh, that shouldn't happen.  What object is that?  The 16385 should be
>>> a database OID, and the 16467 is most likely a table's OID within that
>>> database.
> 
> Please answer the above question.

16385 is the database (db) and 16467 is the table (email) the prepared
inserts are executed against.  That table (email) is an inherited table
definition for partitioned tables that are named by date ranges.  E.g.,

CREATE TABLE email_2008_week27 ( PRIMARY KEY (id), CHECK ( ts >=
'2008-06-30'::timestamp AND ts < '2008-07-07'::timestamp ) ) INHERITS
(email)

> 
>> And a correction, the transaction that caused this error was inserting
>> 13.5 million rows and failed near the end.
> 
> Once you've determined which table the error message is talking about,
> please show us what the transaction does with that table.

You mean like:

BEGIN;
PREPARE msg (...) INSERT INTO email VALUES (...);
EXECUTE msg (...)
EXECUTE msg (...)
EXECUTE msg (...)
EXECUTE msg (...)
... repeated millions of times
COMMIT;

Regards,
Mike

-- 
Michael Milligan                                   -> milli(at)acmeps(dot)com


In response to

Responses

pgsql-bugs by date

Next:From: Tom LaneDate: 2008-08-30 00:28:06
Subject: Re: PG 8.3.3 - ERROR: lock AccessShareLock on object 16385/16467/0 is already held
Previous:From: Tom LaneDate: 2008-08-29 21:30:13
Subject: Re: PG 8.3.3 - ERROR: lock AccessShareLock on object 16385/16467/0 is already held

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group