Search Postgresql Archives

WITH and exclusive locks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

When conducting performance tests of our application, I saw quite a few exclusive locks in SELECTs with WITH clause. So I created a big table and executed a query which takes time.
with x as (select * from emp where first_name like 'Sco%')
select * from x;   
I got 2 locks - one accesshare lock against the table and one ExclusiveLock with out  any database/relation.
2417            postgres    10/95    10/95    ExclusiveLock    Yes    2013-11-23 17:38:58+05:30   

My guess is that the Exclusive lock is against some in-memory structure (the temp table created by the WITH clause) and hence is not an issue. Is that correct?
Regards,
Jayadevan


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux