Attributes missing from Feature Service built on Feature Class with joined table

4264
11
10-29-2012 10:14 AM
MatthewCarey
Occasional Contributor
The Attribute Table in a Feature Service that I'm publishing has mysteriously vanished and I was hoping someone would have some insight.Thanks!

Here's the process I've followed if you can bear with me:

- Start with SDE Feature Class (polygons) and SDE Table (I added an Attribute Index to this in order to make a later Join more efficient). This is an earlier version than 10, I believe it's 9.3

- In ArcMap, add these 2 items and perform a Join based on a unique field.

- Symbolize the features using a number field from joined table (Manual Breaks).

- Publish the map to ArcGIS Server, with the following changes made to the default settings before hitting Analyze:
- Increase max number of records to accommodate number of features (around 1700)
- Check Capabilites boxes for WMS(not relevant I don't think) and Feature Access
- Under Feature Access options, uncheck Create, Delete and Update as I only want viewers to work with these on a read-only basis and the SDE connection that the ArcGIS Server box uses only has read-only access
- Uncheck 'allow geometry updates'

- Hit Analyze.

- The results feature 5 Warnings but no Errors:


-Layer's draw time may be affected by slow join access times
- Layer data does not have a feature template set
- Layer's data source is ArcSDE not accessed via a direct connection
- Layer has an in-memory join or relate (Feature Service)
- Missing Tags in Item Description
- Layer draws at all scale ranges

- OK, so the service won't be winning any prizes for drawing speed and elegance, but I just need it to work right now....

- Preview works fine

- Publish works fine


- The Map Service works fine when consumed in ArcMap, symbology is correct and doing an Identify on a polygon pulls up the attributes of both the original feature class and the joined table.

- The equivalent Feature Service, when consumed in ArcMap, does not render any features. In the TOC it shows the symbology as it should be and shows the field name that it should be basing the symbolization on.
Opening the Attribute Table of the Feature Class reveals only the OBJECTID and SHAPE fields and nothing else. If the symbology is changed to Single Symbol, the layer IS drawn using that symbol.

Also, when the TOC is viewed with the List by Source option,the joined table's attributes are available to be seen and exported.

My question is, then: why are most of the attributes missing from the Attribute Table of the Feature Service polygon layer when I bring it up in ArcMap? Similarly if I go to this URL in my web browser:

http://<server name>/arcgis/rest/services/<folder name>/<service name>/FeatureServer/0

I only see the field OBJECTID where I would expect to see all of the fields including those from the joined table.



Any suggestions gratefully accepted. I'm thinking the issue is maybe with the SDE data source and its setttings.

Thanks.
Tags (2)
0 Kudos
11 Replies
MeleKoneya
Occasional Contributor III
Did you ever find any solution to this?   Unfortunately,  I cannot provide any insight as I am having the exact same problem with ArcGIS Server 10. sp4 but thought I would see if you found any resolution.

Thanks,

Mele
0 Kudos
MatthewCarey
Occasional Contributor
Hi, I think it turned out the answer was right under my nose the whole time:

"- Layer has an in-memory join or relate (Feature Service)"  

It turned out that you couldn't use a layer with a join active on it to author a Feature Service (it's OK for a Map Service though).

I had a specific need to publish a Feature Service, and we ended up with my colleague the database expert creating an SDE 'spatial view' instead, using command-line tools (we use Oracle for our database). The spatial view brings together the geography, plus variou fields from various tables but just to look at it you wouldn't know it's any different from any other feature class.

Esri tech support helped us with getting the spatial view constructed when we ran into a problem.

Hope this helps, good luck!
0 Kudos
BrandonIves
New Contributor
Hi, I think it turned out the answer was right under my nose the whole time:

"- Layer has an in-memory join or relate (Feature Service)"  

It turned out that you couldn't use a layer with a join active on it to author a Feature Service (it's OK for a Map Service though).

I had a specific need to publish a Feature Service, and we ended up with my colleague the database expert creating an SDE 'spatial view' instead, using command-line tools (we use Oracle for our database). The spatial view brings together the geography, plus variou fields from various tables but just to look at it you wouldn't know it's any different from any other feature class.

Esri tech support helped us with getting the spatial view constructed when we ran into a problem.

Hope this helps, good luck!



Was the command line tool used to create your "spatial view" an ArcCatalog command line tool?
0 Kudos
BrandonIves
New Contributor
Was the command line tool used to create your "spatial view" an ArcCatalog command line tool?



I also found a way to create the spatial view through SQL statements for anyone else researching this.

http://resources.arcgis.com/en/help/main/10.2/index.html#//002n000000t3000000
0 Kudos
MatthewCarey
Occasional Contributor
That link sounds like the process my colleague followed. She tells me she was using the command line on the Oracle server itself, it wasn't via ArcCatalog.

Hope this helps and it works out for you.
0 Kudos
BrandonIves
New Contributor
That link sounds like the process my colleague followed. She tells me she was using the command line on the Oracle server itself, it wasn't via ArcCatalog.

Hope this helps and it works out for you.


To anyone else looking into doing this, the process works great for viewing data in ArcMap or a Map Service. Editing won't work because it is a view.
0 Kudos
BrandonIves
New Contributor
That link sounds like the process my colleague followed. She tells me she was using the command line on the Oracle server itself, it wasn't via ArcCatalog.

Hope this helps and it works out for you.




I am getting an error trying to create a feature service. Are you able to create the feature service with your new view?
0 Kudos
MatthewCarey
Occasional Contributor
Yes, we've been able to publish it, but I'm sure there were a couple of errors thrown up along the way that we had to address first.

Could you give the details of the errors?
0 Kudos
BrandonIves
New Contributor
Yes, we've been able to publish it, but I'm sure there were a couple of errors thrown up along the way that we had to address first.

Could you give the details of the errors?



Thanks for your response.

"Layer's data source is not supported (Feature Service)"


I also cannot edit the view through ArcMap (because it is a view?) even though I granted Select, Insert, Update, and Delete privileges.
0 Kudos