[mapserver-users] Junk text field values for ArcSDE layers

Tamas Szekeres szekerest at gmail.com
Thu Jan 15 12:32:55 PST 2009


Hi,

As far as I know the driver doesn't do any character encodings with the
values retieved from the database, according to your
default database setting you may try to convert those strings manually. For
example if your database has the 1252 codepage by default, the character
conversion may look something like:

byte[] bytes = Encoding.Convert(Encoding.Unicode, Encoding.Default, Encoding
.Unicode.GetBytes(shape.getValue(index)));
string str = Encoding.GetEncoding(1252).GetString(bytes);


Best regards,

Tamas



2009/1/15 Murty Maganti <MMaganti at oriongis.com>

>  Hello
>
>
>
> I am having some issue with attribute (field) values for ArcSDE or Oracle
> Spatial layers. All text field values are becoming junk characters (after
> calling queryByRect() method). I am using C# map script and VS 2008. This is
> happening for text fields. Number and date fields seems to be fine. Is there
> any special encoding I need to handle in .Net when values are retrieved
> (shapeObj.values)? Same field values looks fine in ArcIMS and ArcMap.
>
>
>
> Thanks
>
> Murty
>
>
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20090115/81cb9162/attachment.htm>


More information about the MapServer-users mailing list