Does SET STATISTICS lock the table?

Started by Joseph Shraibmanabout 22 years ago2 messagesgeneral
Jump to latest
#1Joseph Shraibman
jks@selectacast.net

Does ALTER TABLE <table> ALTER <field> SET STATISTICS 100; lock the
table? I just tried to do that while a query is running and the ALTER
is hanging.

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Joseph Shraibman (#1)
Re: Does SET STATISTICS lock the table?

Joseph Shraibman <jks@selectacast.net> writes:

Does ALTER TABLE <table> ALTER <field> SET STATISTICS 100; lock the
table? I just tried to do that while a query is running and the ALTER
is hanging.

Any ALTER TABLE will lock the table.

regards, tom lane