Opened 14 years ago
Closed 13 years ago
#3462 closed defect (fixed)
MapScript resultsGetShape() method fails with a OracleSpatial layer
Reported by: | aboudreault | Owned by: | aboudreault |
---|---|---|---|
Priority: | normal | Milestone: | 6.0 release |
Component: | MapScript | Version: | svn-trunk (development) |
Severity: | normal | Keywords: | |
Cc: | jimk |
Description
With this php script:
$map = ms_newMapObj("gmap75.map"); $l = $map->getLayerByName("popplace"); $l->queryByRect($map->extent); $l->open(); $s = $l->resultsGetShape(0);
I'm getting this error:
[Fri May 28 09:06:12 2010].978444 msOracleSpatialLayerResultGetShape was called. Using the record = -1 of 143. (shape: 0 should equal pkey: 0)
I've also tested the similar script with Python.
Change History (2)
comment:1 by , 14 years ago
Milestone: | → 6.0 release |
---|---|
Version: | unspecified → svn-trunk (development) |
Note:
See TracTickets
for help on using tickets.
The problem was in the oraclespatial driver code. The virtual method msOracleSpatialLayerResultGetShapeVT, which is called by msLayerResultsGetShape calls the following function:
but here's the definition of this function:
So the record and tile parameters and not correctly used in that function. Since the pkey is not used at all I modified the function definition to work as it should:
Committed in r10190. jimk, could you review and close this ticket to be sure it's ok when you get a chance?