[mapserver-dev] numeric values in string columns

Yewondwossen Assefa yassefa at dmsolutions.ca
Mon Nov 10 09:13:31 EST 2008


Daniel Morissette wrote:
> bartvde at osgis.nl wrote:
>> Hi list,
>>
>> we've got a dataset with road numbers, the column in ArcSDE is a 
>> character
>> type. But the values can look like numbers (002 etc.) as well as strings
>> (e.g. N329).
>>
>> Mapserver will fail in this case, seeing it will check the value for
>> determining the type of column (mapogcfilter.c).
>>
>> Will this be easy to fix, or will it require that Mapserver stores column
>> types internally?
>>
> 
> I'll let Assefa answer about mapogcfilter.c specifically, but I think it 
> would be a good thing to maintain the original column type.
> 
> I started working on support for column types in MapServer a few years 
> ago but never finished it... I think that may even have been for WFS... 
> I checked this morning and unfortunately I could not find that code 
> anywhere.
> 
> Daniel



Ideally if the layer's column type is available with the layer object, 
we could use that. Not sure when/if that will be available.
The other alternative is to use metadata on the layer (the same way we 
use it now for attribute name aliases). We could have <item_name>_type 
and have that value used  to build the expressions. I am willing to add 
the metatadata support if you think this is appropriate.

Best Regards,

-- 
----------------------------------------------------------------
Assefa Yewondwossen
Software Analyst

Email: assefa at dmsolutions.ca
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925
----------------------------------------------------------------



More information about the mapserver-dev mailing list