[mapserver-users] MapServer and Guid USING UNIQUE

Tamas Szekeres szekerest at gmail.com
Thu Mar 10 03:56:18 PST 2011


Hi Roger,

Could you create a ticket with this issue (
http://trac.osgeo.org/mapserver/newticket)? I'll take care of fixing this.

Best regards,

Tamas



2011/3/10 Roger Bedell <sylvanascent at gmail.com>

> Thanks Till, however, here is the trace from the ODBC tracer, pretty
> obvious what is going on:
>
>           DIAG [42000] [Microsoft][ODBC SQL Server Driver][SQL
> Server]Insufficient result space to convert uniqueidentifier value to char.
> (8170)
>
> Guids generally take up 36 characters when converted to a string, and the
> Select statement only has room for 20.
>
> Since this is a SQL specific query, my guess it is being generated in the
> sql spatial driver?
>
> Roger
>
>
>           HSTMT               0x0589B310
>           UCHAR *             0x05E1A990 [      -3] "SELECT
> Feature.STAsBinary(),convert(varchar(20), PKey) from MetesAndBoundsHeader
> WHERE Feature.STIntersects(Geometry::STGeomFromText('POLYGON((-104.18599
> 29.2473266843318,-93.22438 29.2473266843318,-93.22438
> 41.3707663156682,-104.18599 41.3707663156682,-104.18599
> 29.2473266843318))',4326)) = 1 \ 0"
>           SDWORD                    -3
>
>           DIAG [42000] [Microsoft][ODBC SQL Server Driver][SQL
> Server]Insufficient result space to convert uniqueidentifier value to char.
> (8170)
>
>
>
>
>
>
>
> On Thu, Mar 10, 2011 at 12:04 PM, adams <adams at terrestris.de> wrote:
>
>>  Dear Roger,
>>
>> if you get an empty image with no error, the first try would be to use a
>> simple symbol and no expression in your layer.
>> Also ensure, that your extent when querying the map is correct.
>>
>> So you make sure, that everything around your datasource is OK.
>>
>> Then use a datastring like this one:
>>
>>
>> DATA "the_geom from (SELECT Feature from MetesAndBoundsHeader) as foo
>> USING UNIQUE PKey USING SRID=4326"
>>
>> or however the geometry-column in mssql server is called ;-)
>>
>> Regards, Till
>>
>>
>>
>>
>> Roger Bedell wrote:
>>
>> Good Morning.
>> I am currently working with MapServer and the MSSQL Spatial driver. I am
>> seeing that MS does not work with a DATA statement like this in the Map
>> file:
>>
>> DATA "Feature from MetesAndBoundsHeader USING UNIQUE PKey USING SRID=4326"
>>
>> where PKey is defined like this:
>>
>> [PKey] [uniqueidentifier] DEFAULT NEWSEQUENTIALID() ROWGUIDCOL NOT NULL,
>>
>> No errors are triggered, however nothing is displayed, including all other
>> layers. Is this an issue with the SQL Spatial driver or MapServer? Any ideas
>> on how to fix it?
>>
>> Thanks!
>> Roger Bedell
>> Coordinate Solutions Inc.
>>
>> ------------------------------
>>
>> _______________________________________________
>> mapserver-users mailing listmapserver-users at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>> --
>>
>> ---------------------------------------------------------
>> terrestris GmbH & Co. KG
>> Irmintrudisstrasse 17
>> 53111 Bonn
>> Germany
>>
>> Till Adams
>> Geschäftsführung
>>
>> Tel: +49 (0)228 / 962 899-52
>> Fax: +49 (0)228 / 962 899-57adams at terrestris.de http://www.terrestris.de
>> Amtsgericht Bonn, HRA 6835
>> ---------------------------------------------------------
>>
>> Komplementärin:
>>
>> terrestris Verwaltungs GmbH
>>
>> vertreten durch:
>> Hinrich Paulsen, Till Adams
>>
>>
>
> _______________________________________________
> 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/20110310/9503df69/attachment.htm>


More information about the MapServer-users mailing list