Re: [GENERAL] Slow queries when functions are inlined

2012-05-16 Thread Tom Lane
Evan Martin writes: > Thanks, Tom. You mean this bit, right? > -> Seq Scan on _test_pos (cost=0.00..10728.00 rows=1 width=4) > Filter: > ((('010120E6101C401C40'::geography && > _st_expand(pos, 30::double precision)) AND ... > I tried to find some i

Re: [GENERAL] Slow queries when functions are inlined

2012-05-16 Thread Evan Martin
Thanks, Tom. You mean this bit, right? -> Seq Scan on _test_pos (cost=0.00..10728.00 rows=1 width=4) Filter: ((('010120E6101C401C40'::geography && _st_expand(pos, 30::double precision)) AND ... I tried to find some info on selectivity estimation f

Re: [GENERAL] Slow queries when functions are inlined

2012-05-16 Thread Tom Lane
Evan Martin writes: > I've run into a weird query performance problem. I have a large, complex > query which joins the results of several set-returning functions with > some tables and filters them by calling another function, which involves > PostGIS calls (ST_DWithin). This used to run in abo

[GENERAL] Slow queries when functions are inlined

2012-05-15 Thread Evan Martin
I've run into a weird query performance problem. I have a large, complex query which joins the results of several set-returning functions with some tables and filters them by calling another function, which involves PostGIS calls (ST_DWithin). This used to run in about 10 seconds until I change