Try: $qfield = 'gid'; $qstring = "([gid] IN '1,2,3')"; @$datQuery = $query_layer->queryByAttributes($qfield,$qstring,MS_MULTIPLE);
I'm guessing the layer in question is PostGIS? In older versions of MapServer the query string could be given in the native SQL language of underlying driver. In 7.0 there was some expression normalization work done where expressions and filters are given in MapServer expression syntax and then converted to native SQL. It's possible that you've hit an example where the translation isn't working as it should. Steve -----Original Message----- From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Sven Schroeter Sent: Wednesday, October 11, 2017 10:46 AM To: mapserver-users@lists.osgeo.org Subject: [mapserver-users] php Mapscript queryByAttributes Hi, Old Server: PHP 5.4.36 with MS 6.4.1 (MS4W) New Server: PHP 5.6.31 with MS 7.0.6 (MS4W 3.2.2) My Test Script: $qfield = 'gid'; $qstring = "gid IN (1,2,3)"; @$datQuery = $query_layer->queryByAttributes($qfield,$qstring,MS_MULTIPLE); Works fine on the old Server, on the new Server no result. I have tried to change the query expression, i.e.: $qstring = "('[gid]' in '1,2,3')"; No result on old server and new... How can I get it run on MS7? Thanks + greetings Sven ************************************** NETGIS GbR Benediktinerstr. 32a 54292 Trier Tel.: 0651-1704731 Fax: 0651-1704733 schroe...@netgis.de www.netgis.de _______________________________________________ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users