Select to view content in your preferred language

Inner ring order - question

1080
6
05-23-2012 03:46 AM
LakshmananVenkatesan
Frequent Contributor
Hi All,

I am saving a polygon with 2 exclusions [Inner rings] (i.e. say exlcusion 'A' as 4 vertices and exclusion 'B') into SDE database.
When I do a Sliverlight ESRI query task to retrive the same shape, am getting exclusion B as first inner ring and exclusion A as second inner ring.
How do I get a polygon rings in same order as I saved into database. Please help.

Note: shapes from sliverlight has been saved to SDE using GP Tools where inner rings are added into geometry bag in same order and stored in geodatabae

SR
0 Kudos
6 Replies
LakshmananVenkatesan
Frequent Contributor
Repost and brought forward... any one help me with this query?
0 Kudos
JenniferNery
Esri Regular Contributor
Can you check in Fiddler, the request for geometry returns the rings in the same order as you want them drawn? If the query result is already reversed then ArcGIS API for Silverlight have respected the order geometry was received. I believe REST API also does not manipulate the order. May I ask why the order of rings is important?
0 Kudos
LakshmananVenkatesan
Frequent Contributor
Can you check in Fiddler, the request for geometry returns the rings in the same order as you want them drawn? If the query result is already reversed then ArcGIS API for Silverlight have respected the order geometry was received.


jennifer,

Query Task returns rings in different order .i.e. In SDE, polygon has 2 inner rings with 5 and 4 vertices. Query task returns polygon with 2 inner rings where 1st inner ring has 4 vertices and second has 5 vertices. One important thing is some times it returns in same order also. This is unpredictable. Please help me quickly. This is one of the important request from client. Thank you.
0 Kudos
LakshmananVenkatesan
Frequent Contributor
repost and brought forward
0 Kudos
JenniferNery
Esri Regular Contributor
Can you try using EditorWidget instead of GP tool to add the shape? You can create rings by performing Cut. Try to see if the order of rings is still unpredictable. If no, then maybe the GP tool is causing this?

You can also try performing the query from your web browser through the REST end point. Is this off a map service or feature service? I don't know how I could help. I asked the REST API team and they also do not manipulate the order, they simply return geometry as it is returned by service.

What version of ArcGIS Server do you have? I'm thinking ArcGIS Server team might be able to assist you but you also might want to contact support and give them a reproducible sample?
0 Kudos
LakshmananVenkatesan
Frequent Contributor
Can you try using EditorWidget instead of GP tool to add the shape? You can create rings by performing Cut. Try to see if the order of rings is still unpredictable. If no, then maybe the GP tool is causing this?

You can also try performing the query from your web browser through the REST end point. Is this off a map service or feature service? I don't know how I could help. I asked the REST API team and they also do not manipulate the order, they simply return geometry as it is returned by service.

What version of ArcGIS Server do you have? I'm thinking ArcGIS Server team might be able to assist you but you also might want to contact support and give them a reproducible sample?


Thanks a ton. First I would like to say that am working ESRI product for last 10 years and strong in arcobjects.

Shape has been saved into database using GP tool which correctly maintain ring order [using geometry bag to add the ring in order]which is sent from client. No issues, no second thought.

Simple test case : Just make a query using query task on a SDE where polygon contains multiple rings and check the order of rings returned.

We use ArcGIS 10 SP1 and ESRI SL API 2.1

I have already raised an incident and looking for quick response.
0 Kudos