[Mapserver-users] phpMapScript unable to query PostGIS layer that has a Bit() column?

Perry Casson perry.casson at waypointinfo.com
Fri Apr 30 01:01:48 EDT 2004


I'm fairly new to all of this MapServer stuff but I appear to have ran 
into a bug when trying to do a map query on a PostGIS layer that has a 
column that is defined as bit(8).  Is this a known issue?  I'm running 
version MapServer 4.0.2 (Linux)


Fatal error: [MapServer Error]: msPOSTGISLayerGetShape(): Error 
executing POSTGIS SQL statement (in FETCH ALL): DECLARE mycursor2 BINARY 
CURSOR FOR SELECT 
esn::text,gmuid::text,messageid::text,timestamp::text,recievedat::text,devicetype::text,identifier::text,isgps::text,longitude::text,latitude::text,gpsvalid::text,gpstime::text,v1::text,v2::text,v3::text,max1::text,max2::text,max3::text,actuator_previous::text,actuator_current::text,userdata::text,battery::text,asbinary(force_collection(force_2d(geo)),'NDR') 
from wp_point WHERE OID = 27497 -ERROR: Cannot cast type bit to text

The table is defined like this:
CREATE TABLE wp_point(ESN varchar(12), gmUID varchar(40), messageID 
varchar(40), TimeStamp timestamp, RecieveDat timestamp, DeviceType 
varchar(32), Identifier varchar(32), IsGPS varchar(2), Longitude float8, 
Latitude float8, GPSValid varchar(2), GPSTime timestamp, V1 int2, V2 
int2, V3 int2, Max1 int2, Max2 int2, Max3 int2, Actuator_Previous bit(8) 
, Actuator_Current bit(8) ,UserData varchar(64), Battery varchar(8));


Perry Casson




More information about the mapserver-users mailing list