[mapserver-users] queryByAttributes returns no result with OGR/ODBC data source
Dejan.Gambin at pula.hr
Dejan.Gambin at pula.hr
Sun May 17 23:31:56 PDT 2009
Still doesn't help :-(. Maybe I am doing something wrong...I don't know if
I can "debug" this query on a lower level...
This works for me correctly:
ogrinfo -where "KOORDINATAX=5460870" krk.ovf krk
although I get :
ERROR 4: Update access not supported for VRT datasources
Had to open data source read-only.
mapserver-users-bounces at lists.osgeo.org wrote on 18.05.2009 08:22:37:
>
>
>
>
> Try to remove the brackets [] from the field names
>
> queryByAttributes("KOORDINATAX", 5460870, MS_MULTIPLE);
>
> Regards
> Maher
>
>
>
> |---------+--------------------------->
> | | Dejan.Gambin at pul|
> | | a.hr |
> | | |
> | | 05/18/2009 09:19|
> | | AM |
> |---------+--------------------------->
>
>
>--------------------------------------------------------------------------------------------------------------------------------------------------
> |
> | |
> | To: Maher Karim <Maher_Karim at dorsch.com.jo> |
> | cc: mapserver-users <mapserver-users at lists.osgeo.
> org>, mapserver-users-bounces <mapserver-users-bounces at lists.osgeo.
> org> |
> | Subject: Re: [mapserver-users] queryByAttributes returns
> no result with OGR/ODBC data source |
>
>
>--------------------------------------------------------------------------------------------------------------------------------------------------
> |
>
>
>
>
> Hi,
>
> Unfortunatelly it doesn't help. I have tried with:
>
> queryByAttributes("[KOORDINATAX]", ( [KOORDINATAX] = 5460870 ),
> MS_MULTIPLE);
>
> and with
>
> queryByAttributes("[KOORDINATAX]", 5460870, MS_MULTIPLE);
>
> Neither one gives results :-(
>
> dejan
>
> Maher Karim <Maher_Karim at dorsch.com.jo> wrote on 18.05.2009 07:28:19:
>
> >
> >
> >
> >
> > HI,
> > Please consider that there is a difference the field name definintion
for
> > the item query, the field name is differenet when you are using
> shapefiles
> > than PostGIS tables.
> > Try to use
> > $strExp=( [KOORDINATAX] = 5460870 );
> > queryByAttributes('itemname',$strExp,MS_MULTIPLE)
> >
> > and if Not working try
> > queryByAttributes( [KOORDINATAX],5460870,MS_MULTIPLE)
> >
> > Hope that it helps
> >
> > Regards
> > Maher
> >
> >
> >
> >
> > |---------+--------------------------------------->
> > | | Dejan.Gambin at pula.hr |
> > | | Sent by: |
> > | | mapserver-users-bounces at list|
> > | | s.osgeo.org |
> > | | |
> > | | |
> > | | 05/18/2009 12:50 AM |
> > |---------+--------------------------------------->
> >
> >
>
>--------------------------------------------------------------------------------------------------------------------------------------------------
>
> > |
> > |
> |
> > | To: mapserver-users at lists.osgeo.org
> |
> > | cc:
> |
> > | Subject: [mapserver-users] queryByAttributes returns no
> > result with OGR/ODBC data source
> |
> >
> >
>
>--------------------------------------------------------------------------------------------------------------------------------------------------
>
> > |
> >
> >
> >
> >
> > Hi,
> >
> > I am using OGR Virtual Spatial Data to connect to MS Access database
> using
> > ODBC. Database has X/Y columns. I have created .ovf file like this:
> >
> > <OGRVRTDataSource>
> > <OGRVRTLayer name="krk">
> > <SrcDataSource>ODBC:@Krk</SrcDataSource>
> > <FID>ID</FID>
> > <SrcLayer>Dozvole</SrcLayer>
> > <GeometryType>wkbPoint</GeometryType>
> > <GeometryField encoding="PointFromColumns" x="KoordinataX"
> > y="KoordinataY"/>
> > </OGRVRTLayer>
> > </OGRVRTDataSource>
> >
> > It is all working fine and the points are showing on the map (using
> > p.mapper). Alos, ogrinfo with -where clause is working fine. But the
> > attribute query gives no result, whichever field I query. Query string
is
> > like:
> >
> > ( [KOORDINATAX] = 5460870 )
> >
> > This syntax works fine with shape files and also wit OGR layers based
on
> > MapInfo files. But not with ODBC/Access.
> >
> > I am using ms4w 2.2.7
> >
> > Any help?
> >
> > regards, dejan_______________________________________________
> > mapserver-users mailing list
> > mapserver-users at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
> >
> >
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20090518/f31172ba/attachment.htm>
More information about the MapServer-users
mailing list