You didn't mention version, but 8.1.x has bitmap index scans that might
greatly speed this up...

On Sat, Apr 22, 2006 at 02:34:13PM -0700, [EMAIL PROTECTED] wrote:
> Hi List
> I have maybe an easy question but i do not find an answer, i have this
> SQL query:
> 
> SELECT geom,group,production_facs FROM south_america
>               WHERE municipio = ''
>                       OR municipio = 'ACRE'
>                       OR municipio = 'ADJUNTAS'
>                       OR municipio = 'AGUADA'
> 
> The performance of this query is quite worse as longer it gets, its
> possible that this query gets over 20 to 30 OR comparisons, but then
> the performance is really worse, is it possible to speed it up?
> Thanks
> Clemens
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 5: don't forget to increase your free space map settings
> 

-- 
Jim C. Nasby, Sr. Engineering Consultant      [EMAIL PROTECTED]
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
       choose an index scan if your joining column's datatypes do not
       match

Reply via email to