<HTML><HEAD><TITLE>RE: [mapguide-users] postgis fdo-ogr and spatial indexes</TITLE>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.6000.16481" name=GENERATOR></HEAD>
<BODY dir=ltr>
<DIV>&nbsp;</DIV>
<DIV>Trunk is the only one that I check fixes into.</DIV>
<DIV>&nbsp;</DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
<DIV><FONT size=2>-----Original Message----- <BR><B>From:</B> mapguide-users-bounces@lists.osgeo.org&nbsp;on behalf of&nbsp;Jason Birch <BR><B>Sent:</B> Wed 6/13/2007 6:30 PM <BR><B>To:</B> MapGuide Users Mail List <BR><B>Cc:</B> <BR><B>Subject:</B> RE: [mapguide-users] postgis fdo-ogr and spatial indexes<BR><BR></FONT></DIV>
<P><FONT size=2>I believe that this is the 3.2.x branch:<BR><BR><A href="http://svn.osgeo.org/fdoogr/branches/3.2.x/Providers/OGR/">http://svn.osgeo.org/fdoogr/branches/3.2.x/Providers/OGR/</A><BR><BR>And this is the "bloated" version in trunk :)<BR><BR><A href="http://svn.osgeo.org/fdo/trunk/Providers/OGR/">http://svn.osgeo.org/fdo/trunk/Providers/OGR/</A><BR><BR>(that's a joke.&nbsp; fdoogr is the most minimal provider out there)<BR><BR>I'm not sure which is being used for the recent builds...<BR><BR>Jason<BR><BR><BR>-----Original Message-----<BR>From: mapguide-users-bounces@lists.osgeo.org [<A href="mailto:mapguide-users-bounces@lists.osgeo.org">mailto:mapguide-users-bounces@lists.osgeo.org</A>] On Behalf Of alucas<BR>Sent: Wednesday, June 13, 2007 14:48<BR>To: mapguide-users@lists.osgeo.org<BR>Subject: Re: [mapguide-users] postgis fdo-ogr and spatial indexes<BR><BR><BR>Where can I download the source code of ogr provider?<BR><BR><BR><BR>Frank Warmerdam-2 wrote:<BR>&gt;<BR>&gt; alucas wrote:<BR>&gt;&gt; Hello,<BR>&gt;&gt;<BR>&gt;&gt; I'm testing the ogr provider with postgis and it works fine, I<BR>&gt;&gt; connect vía Map 2008 and MGOS 1.2. So, the question is about the<BR>&gt;&gt; spatial indexes (gist).<BR>&gt;&gt; How works the ogr provider with gist indexes? I'm attempting to get<BR>&gt;&gt; better performance with this configuration.<BR>&gt;<BR>&gt; "alucas",<BR>&gt;<BR>&gt; GDAL/OGR 1.4 uses the following construct when building a query<BR>&gt; against a postgis table to apply a spatial filter.<BR>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; m_poFilterGeom-&gt;getEnvelope( &amp;sEnvelope );<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; osWHERE.Printf("WHERE %s &amp;&amp; SetSRID('BOX3D(%.12f %.12f, %.12f<BR>&gt; %.12f)'::box3d,%d) ",<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pszGeomColumn,<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sEnvelope.MinX, sEnvelope.MinY,<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sEnvelope.MaxX, sEnvelope.MaxY,<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; nSRSId );<BR>&gt;<BR>&gt; This is intended to use the spatial index and normally works as far as<BR>&gt; I know.&nbsp; If you run MgServer from the commandline, and enable<BR>&gt; CPL_DEBUG (set this enviroment variable to ON) you should see debug<BR>&gt; output from the OGR provider indicating the specific query it ends up<BR>&gt; using.&nbsp; It should be prefixed with something like:<BR>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp; OGRPGTableLayer::BuildWhere returns:<BR>&gt;<BR>&gt; Best regards,<BR>&gt; --<BR>&gt; ---------------------------------------+------------------------------<BR>&gt; ---------------------------------------+--------<BR>&gt; I set the clouds in motion - turn up&nbsp;&nbsp; | Frank Warmerdam,<BR>&gt; warmerdam@pobox.com<BR>&gt; light and sound - activate the windows | <A href="http://pobox.com/~warmerdam">http://pobox.com/~warmerdam</A><BR>&gt; and watch the world go round - Rush&nbsp;&nbsp;&nbsp; | President OSGeo, <A href="http://osgeo.org/">http://osgeo.org</A><BR>&gt;<BR>&gt; _______________________________________________<BR>&gt; mapguide-users mailing list<BR>&gt; mapguide-users@lists.osgeo.org<BR>&gt; <A href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</A><BR>&gt;<BR>&gt;<BR><BR>--<BR>View this message in context: <A href="http://www.nabble.com/postgis-fdo-ogr-and-spatial-indexes-tf3917522s16610.html#a11109589">http://www.nabble.com/postgis-fdo-ogr-and-spatial-indexes-tf3917522s16610.html#a11109589</A><BR>Sent from the MapGuide Users mailing list archive at Nabble.com.<BR><BR>_______________________________________________<BR>mapguide-users mailing list<BR>mapguide-users@lists.osgeo.org<BR><A href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</A><BR>_______________________________________________<BR>mapguide-users mailing list<BR>mapguide-users@lists.osgeo.org<BR><A href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</A><BR></FONT></P></BLOCKQUOTE></BODY></HTML>