Interesting, I have been looking for a way to speed up those types of queries for a while, thanks!<div><br></div><div>Do you have metrics on this?<br><br><div class="gmail_quote">On Wed, Dec 5, 2012 at 10:53 AM, Paul Norman <span dir="ltr"><<a href="mailto:penorman@mac.com" target="_blank">penorman@mac.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Something else is that tags->'highway' in ( 'motorway', 'primary', 'secondary' ) will NOT use indexes on tags.<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">tags @> hstore('highway', 'motorway') OR tags @> hstore('highway', 'primary') OR tags @> hstore('highway', 'secondary') should be significantly faster with proper indexes.<u></u><u></u></span></p>

<p class="MsoNormal"></p></blockquote></div><br><br clear="all"><div><br></div>-- <br>Martijn van Exel<br><a href="http://oegeo.wordpress.com/" target="_blank">http://oegeo.wordpress.com/</a><br><a href="http://openstreetmap.us/" target="_blank">http://openstreetmap.us/</a><br>


</div>