John Giotta
John Giotta

Reputation: 16934

ALTER COLUMN on table with access lock

I'm trying to alter a table column in Postgres, but the table has several AccessShare and AccessExclusive locks. How do I over come the locks?

Upvotes: 1

Views: 665

Answers (1)

Frank Heikens
Frank Heikens

Reputation: 126991

Kick out the connections that cause the locks. Use pg_cancel_backend() or even pg_terminate_backend().

http://www.postgresql.org/docs/current/static/functions-admin.html

Upvotes: 1

Related Questions