I am able to edit and clip polygon in an OGR Layer using cmSplitByPolyline. Layer saves fine as a shapefile to computer but upon saving ogr layer 1 half of the polygon is updated to the server only and other half is lost somehow.
Need guidance
This is probably because you read 1 feature and create 2 features. So one of the two features needs to be added. The OGR Layer has some glitches likes this. When time permits we try to improve it.
Are you using MW5 and the shapefile editor or are you using MapWinGIS (the mapping component) in your own application? If the latter could you share the relevant code?
Hi, trace.zip (27.4 KB)
LastErrorCode returns me 0, tried multiple times.
Trace file is attached as well as it’s xml.
Looks like nothing odd there but your expert opinion would be required obviously
Ok thanks this helps a lot - the trace tells me two things:
a) it’s not on the database (yay a bug :p)
b) the database never gets an insert from mapwingis so something goes wrong doing the update/inserts
As suggested @Mathijs.Dumon, running a SQL trace gave me error n 2601: "Cannot insert a duplicate key row in object ‘‘sys.syssingleobjrefs’’ with unique index ‘clst’. Any idea to solve that?
According to the MSDN: sys.syssingleobjrefs Exists in every database. Contains a row for each general N-to-1 reference.
are you sure this was related to your query? When running a SQLProfiler you’ll see a lot of queries unrelated to what you are doing (unless you’re the only person on that db).