Could someone explain how the DB handles record locking when an aggregate function is called? For instance:
...
select count(*)
into v_count
from x;
...
Is there a lock maintained on table x for the duration of the transaction so no rows can be inserted or deleted?