PHP MapScript queryByAttributes Issue
Ian Tidy
IANT at NAPIER.GOVT.NZ
Tue Jan 8 15:11:29 PST 2008
Hi All,
I am running MapServer 4.10 and am having a problem with a query.
My query code is:
$qstring = "/^$street.*/";
$oLayer = $map->getlayerbyname("smartworx");
$oLayer->set("status", MS_ON);
@$oLayer->queryByAttributes('STNAME', $qstring, MS_MULTIPLE);
And this fails, but when I run the same code using a different table it
works:
$qstring = "/^$street.*/";
$oLayer = $map->getlayerbyname("crs_road_centreline");
$oLayer->set("status", MS_ON);
@$oLayer->queryByAttributes('ROAD_LABEL', $qstring,
MS_MULTIPLE);
Now I know the obvious answer is that the item I am searching for
doesn't exist in my table, but I have checked and it does exist. The
only difference between the two (2) shape files is that
crs_road_centreline is a LINE table and smartworx is a POINT table and
have slightly different structures.
crs_road_centreline is the road centreline network
smartworx is a address point file.
Any Ideas???
Cheers Ian
______________________
Ian Tidy
GIS Analyst / Developer
Works Asset Department
Napier City Council
Hastings St, Private Bag 6010, Napier, New Zealand
Phone +64-6-835-7579 Ext. 8115
Fax +64-6-834-4195
mailto:iant at napier.govt.nz
http://www.napier.govt.nz | http://maps.napier.govt.nz
#####################################################################################
This e-mail message has been scanned for Viruses and Content and cleared
by MailMarshal
#####################################################################################
######################################################################
Attention:
This e-mail message and accompanying data may contain information that
is confidential and subject to legal privilege. Any information
provided is given in good faith. However unless specifically stated to
the contrary, Napier City Council accepts no liability for the
content of this e-mail or for the consequences of any action taken on
the basis of the information provided, unless that information is
subsequently confirmed in writing. If you are not the intended recipient,
you are notified that any use, dissemination, distribution or copying
of this message or data is prohibited. If you received this e-mail
message in error, please notify us immediately and erase all copies
of this message and attachments. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20080109/5817adb1/attachment.htm>
More information about the MapServer-users
mailing list