Altough this is more PostgreSQL/PostGIS related and should go to there list but I tried it and... strange, I can not reproduce your problem. This is what I did:
create table swip3 ( id int, zname varchar(20), pid int, geom geometry, rdate timestamp ); insert into swip3 values ( 28, 'Zone 2', 607, geomfromewkb( decode( '0101000020BB1000007ADFF8DA335161406551D845D17541C0', 'hex')), '2009-02-12 13:30:00'::timestamp ); create table probe ( int id, int logger_id ); insert into probe values ( 607, 1 ); create table logger ( int id, int client_id ); insert into logger values ( 1, 120 ); SELECT * from swip3 WHERE (pid in (select probe.id from probe where logger_id in (select id from logger where client_id=120)) and rdate='2009-02-12 13:30:00') and (geom && setSRID( 'BOX3D(138.5356633 -34.9225467,138.5397151 -34.9184949)'::BOX3D,4283) ); id | zname | pid | geom | rdate ----+--------+-----+---------------------------------------------------- +--------------------- 28 | Zone 2 | 607 | 0101000020BB1000007ADFF8DA335161406551D845D17541C0 | 2009-02-12 13:30:00 (1 Zeile) So I believe this has really nothing to do with MS. _______________________________________________ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users