AI Rumman wrote:
> I execued the query:
> ALTER TABLE entity ADD COLUMN owner_type char(1) NOT NULL default 'U';
>
> The db is stuck. The enity table has 2064740 records;
>
> Watching locks:
[all locks are granted]
> Any idea for the db stuck?
To add the column, PostgreSQL has to modify all rows in the table.
But then 2064740 records is not very much, so it shouldn't take forever.
Do you see processor or I/O activity?
Yours,
Laurenz Albe