var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: # of Accesssharelocks when querying on partitioned table causing Shared Memory Error
I'm running simple range query on partitioned table. It is creating the huge number of Accesssharelocks which is causing the out of shared memory error.
partitioned key => date_dt
SELECT * FROM test WHERE date_dt BETWEEN '2015-01-01' AND '2015-01-31' (Around 100 rows)
Postgres version: PostgreSQL 9.3.4 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4), 64-bit
Only single user accessing this table still it is creating so many locks.
select a.pid, b.usename, count(a.mode) from pg_locks a join pg_stat_activity b
group by a.pid,b.usename order by count desc;
10944 test_user 2571
Any idea why it is creating so many locks? Any help would be really appreciated.