I have a MXD with about 25 total Layers and Tables I'm trying to publish to AGOL as a Feature Service. The data source for all the layers and tables is an Enterprise Geodatabase. I'm able to publish successfully, but the resulting Feature Service only has 1 layer. It's always the top listed layer in Table of Contents in ArcMap.
I've tried multiple ways of publishing, such as saving the Service Definition file and publishing it separately from AGOL and using a Geoprocessing tool, using the File>Share As approach, etc. Always the same result. I didn't get the behavior when I published to ArcGIS Enterprise and had Feature Access enabled, however I want this data on AGOL.
Adrian Welsh I just tried removing the tables and re-publishing. Still got the same result, only one layer making it into the Feature Service. Nothing too crazy about the data, some polygon and point layers. See the images below
For this kind of issue it would be best to try and narrow down the problem, this is what I would do first:
1. Open the original map document, and then open another, blank map document next to it.
2. Highlight everything in the table of contents in the original map document, then drag/drop it in the table of contents in the new MXD. This copies the content from your original map document into the new map document, along with all the symbology.
3. Try to publish from this new MXD to see if that resolves the issue
If the same issue persists after trying a new map document, try adding/publishing one layer at a time from the new map document to see if one or many of the layers fail to publish successfully. This will involve dragging one layer from the original map document and dropping it into the new map document > then publish the single layer from the new map document to ArcGIS Online.
If it's successful, remove the layer from the new map document and move on to the next layer from the old map document. Do this for each layer in your old map document until you find one that doesn't work, or until all the layers are published successfully and work correctly in ArcGIS Online.
The above steps will help narrow down if the issue is with the map document, a layer (or multiple layers), or both.
I like Jacob's idea. I think copying and pasting all of your layers into a new map document should really narrow down the issue. It's interesting that only your first layer is being published into your service. It's also interesting that the icon for your feature service is the outline of the airport area but the layer published was the first layer. When you open the feature service, are there other layers in it? Or just that one?
Either way, I'll be curious to see what works with the above suggestions.