Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#3274 closed defect (fixed)

msPostGISLayerGetItems() error with !BOX! macro

Reported by: szigeti Owned by: pramsey
Priority: normal Milestone: 6.0 release
Component: PostGIS Interface Version: svn-trunk (development)
Severity: normal Keywords: !BOX!, LayerGetItems
Cc:

Description

The msPostGISLayerGetItems() function performs an sql query, but in the query string the !BOX! macro is not substituted by any valid expression, so the postrgesql backend complains about some unknown column.

In the patch I have written !BOX! is replaced by "st_setsrid(st_makebox2d(st_point(0,0),st_point(0,0)),4326)". Maybe it is not the best choice, since it uses a predefined srid value..

Feel free to apply/rewrite the patch!

Attachments (1)

postgis_box.patch (1.1 KB ) - added by szigeti 14 years ago.

Download all attachments as: .zip

Change History (3)

by szigeti, 14 years ago

Attachment: postgis_box.patch added

comment:1 by pramsey, 14 years ago

Resolution: fixed
Status: newclosed

I didn't use the patch, but this issue provided some good motivation to investigate and rationalize how !BOX! is handled throughout the code. Thanks, committed a change at r9737 in trunk.

comment:2 by dmorissette, 13 years ago

Milestone: 6.0 release
Note: See TracTickets for help on using tickets.