|
POST
|
Yes that is supported by default in all views.Schema changes like adding or dropping column in the source data will be propagated to all views. Also changing any field property like domains, alias would also be propagated to the views. Khaled Online feature service Dev. Lead
... View more
01-23-2019
06:57 AM
|
1
|
3
|
3296
|
|
POST
|
Online feature service supports reordering fields using views. You can always create a view layer based on a source layer. You can configure the view layer with any field ordering that are different from that of its source. With this solution, you would not need to do any work or ordering in the UX and you will persist your ordering in the server side. Ordering the fields in the view does not affect the source layer and the source layer will still be in the original source. Your maps would reference the view rather than the source. You can also select subset of the fields in the layer and you would not need to show all fields by marking them visible (true/false). Not sure if this is something you would like to pursue but it is an option we have in the server side. Thanks Khaled Hassen Online feature service lead
... View more
01-22-2019
03:50 PM
|
0
|
0
|
739
|
|
POST
|
Eric, I see the GUID field is defined as editable=false { "name" : "reference", "type" : "esriFieldTypeGUID", "alias" : "reference", "sqlType" : "sqlTypeOther", "length" : 38, "nullable" : false, "editable" : false, "domain" : null, "defaultValue" : null }, The guid field needs to be editable. The Globald is the only field that needs to have editable=false. Sorry we do not have a way to change this property from the admin API. You can drop the relatiohship and the guid column and repeat the process . Will be good to start from scratch just to be sure all are good. Thanks Khaled
... View more
01-14-2019
08:54 AM
|
1
|
19
|
1861
|
|
POST
|
Can you pl. provide me with accessible link to the feature service. Will be good to have it as public if it is ok with you. The last link you sent me was inaccessible to me. Will take a look.
... View more
01-14-2019
07:30 AM
|
0
|
21
|
2348
|
|
POST
|
We do not have any currently known bug in the export to filegdb. Do you have a link to the service to look at?
... View more
01-11-2019
07:38 AM
|
0
|
24
|
2348
|
|
POST
|
Eric, Not sure if you have lots of data in the related table. But if you do, will be good to index the fkey in the related table. try this first: https://url/ArcGIS/rest/admin/services/<service2>/FeatureServer/<relatedTableId>/addToDefinition Pass the following json: { "indexes" : [ { "name" : "myindex", // some unique name "fields" : "<fkey name in the related table"> } ] } Will be good to have this in your related table. Without indexing the related table foreign key, will get slow query and you might timeout and the results might be flaky like what you see. Thanks Khaled
... View more
01-10-2019
04:25 PM
|
0
|
1
|
3555
|
|
POST
|
Yes there is a unique index on the objectid. We normally there are issues with ObjectId based relationships and we always recommend GlobalId based relationship. Once thing you can try is export this service to a filegdb and then add it as another service with a new name. The objectId based relationship will be converted to one based on GlobalId and it would preserve the original ObjectId. When you add a related record you will be using the GlobalId instead of the globalId. Khaled
... View more
01-10-2019
04:01 PM
|
0
|
26
|
2348
|
|
POST
|
One place to look is the foreign key value in related table. It should match a primary key in the source or origin layer. You need to be sure also to create a unique index in the origin layer. To create a unique index, you need to use the layer addToDefinition admin API. Origin layer: https://url/ArcGIS/rest/admin/services/<service2>/FeatureServer/<layerId>/addToDefinition Pass the following json: { "indexes" : [ { "name" : "myindex", // some unique name "fields" : "<primary field name in the origin", "isUnique" : true } ] } You might need to create the index and repeat the workflow again if you do not have a unique index already. By the way, you can create the unique index from the UX as well. So I would recommend: 1. Create the unique index on the origin layer primary key that you will be using for the relationship. 2. Add the relationship again. You might need to start from scratch (sorry). Hope that helps. Khaled
... View more
01-10-2019
03:42 PM
|
0
|
1
|
2978
|
|
POST
|
Yes this is doable as long as the view is created from the same parent service. The steps are: 1. Create an empty service using portal API with "isView" = true 2. Use the Feature service addToDefinition admin API to add a view layer based on the parent source feature service. You can add a definition expression in the layer metadata. The json used here can be something like: https://..../ArcGIS/rest/admin/services/<myViewSerivceName/FeatureServer/addToDefinition { "layers" : [ { "adminLayerInfo" : { "viewLayerDefinition" : { "sourceServiceName" : "<source service name>", "sourceLayerId" : <source layerId>, "sourceLayerFields" : "*" } }, "name" : "<name of the view layer", // Can be different from the source layer "displayField": "", "description": "", "copyrightText": "", "defaultVisibility" : true, "drawingInfo":{"renderer":{"type":"simple","symbol":{"type":"esriSFS","style":"esriSFSSolid","color":[76,129,205,191],"outline":{"type":"esriSLS","style":"esriSLSSolid","color":[0,0,0,255],"width":0.75}}},"transparency":0,"labelingInfo":null}, "allowGeometryUpdates" : true, "htmlPopupType" : "esriServerHTMLPopupTypeNone", "maxRecordCount" : 1000, "maxRecordCountFactor" : 1, "definitionQuery" : "Status = 'some name'" // your time definition expression. Note pl. use sql'92 date query } ] } You can add as many layers as you want to each view as long as you reference the same parent service. Note: You can also do the above using the UX by creating a view from the source that has all source layers and then drops what you do not need using feature service deleteFromDefinition. https://..../ArcGIS/rest/admin/services/<myViewSerivceName/FeatureServer/deleteFromToDefinition { "layers" : [ { "id": 2 // This is the layerId that you do not want in the view }, { "id" : 3" } ] } Hope that helps. Khaled Hassen Online feature service Lead
... View more
01-10-2019
09:19 AM
|
1
|
1
|
1855
|
|
POST
|
Is this happening also when the service is also public? private services are not using the CDN cache and we wonder if it is a availability issue.
... View more
01-10-2019
08:07 AM
|
0
|
1
|
2009
|
|
POST
|
Here are the steps you need to copy the layer from one service to another; i.e., from service1 to service2 1. Create an empty layer (table you need) using service addToDefinition admin API. This will add an empy table or layer to the feature service. You will need to copy the list of fields from the source layer (service1) into the definition below which will live in service2. help url: Add to Definition (Feature Service)—ArcGIS REST API: Services Directory | ArcGIS for Developers https://url/ArcGIS/rest/admin/services/<service2>/FeatureServer/addToDefinition Json to use will look like: { "layers" : [ { "name" : "mylayername", "type" : "Table", // you can also make a feature layer by using Feature "Feature Layer" instead of "Table "fields" : [ { name" : "myFieldName", // copy the rest from the original layer } , ... ] } ] } 2. Export the layer from service one into a filegdb. 3. use Update data from the online UX to append the filegdb into the empty layer you created earlier. By completing 1,2,3 then you have move the table from service 1 to service 2. Then you will be able to add the relationship as we talked earlier. Hope that helps. Khaled
... View more
01-09-2019
04:27 PM
|
3
|
2
|
4946
|
|
POST
|
Are you trying to add relationship between two services layer? This is not supported. Relationships can be added only between two layers that belong to the same service. As you know, within each service, the layerId is unique. If this is what you are trying to do then you might need to use query layer or view layer. Let me know if this is the case. Khaled
... View more
01-09-2019
02:26 PM
|
0
|
1
|
11406
|
|
POST
|
In feature services, client normally use queryRelated API to find out related rows to an origin or vise versa. Another use case is to define composite relationship between origin layer and its destination layer. Deleting an origin row would delete the related row and if it is not composite the feature service would set null or remove the related rows by setting null in the foreign key. In the top of all these, editing is the main requirement to use relationships. All other solutions in arcgis are read only join. We do offer similar functionality (similar to insight) build in the feature service to do join and combine the two layers into one join layer. If the join layer is what the client needs, it will be good to continue and model it inside the feature service rather than external services like insight since all clients can use the REST API on the feature service join layer as any other non-join layer.
... View more
01-09-2019
01:56 PM
|
0
|
0
|
4947
|
|
POST
|
Eric, Sorry this is not documented well so I could not find the doc for you to use. Will work with the team to get this documented. But you will need to follows the example I have sent you. Only what I have included in my example is needed. Before you do anything, pl. send me the full url (strip the token) and the json used. The json you have used in your last message is not correct. >Also, how am I defining what the 2nd layer is? As in, a pointer to the name of the 2nd layer (table) so it knows which >table is related? I do not see any such reference in your sample. All what you really need to figure out is the followings: - Origin layer Id - Destination layer id - Primary key in the origin layer (field name that acts as a primary key) - Foreign key in the destination layer. You just need to replace these in the example json I sent you. I have added some comments below. https://url/ArcGIS/rest/admin/services/<serviceName>/FeatureServer/addToDefinition { "layers" : [ { "id" : 0, "relationships" : [ { "id" : 1, "name" : "myRel", // <name> for your relationshp. Any name is accepted "relatedTableId" : 1, // (table or related layer Id) "cardinality" : "esriRelCardinalityOneToMany", "role" : "esriRelRoleOrigin", "keyField" : "<PrimaryKey>", // Origin primary key like GlobalId if the relationship based on globalId "composite" : <true | false> // Not sure if you need composite but set it to false if you do not need it } ] }, { "id" : 1, "relationships" : [ { "id" : 1, "name" : "myRel", // use the same name you defined above for the relationship name. "relatedTableId" : 0, // This is the layerId of the origin "cardinality" : "esriRelCardinalityOneToMany", "role" : "esriRelRoleDestination", "keyField" : "<ForignKey>", "composite" : <true | false> // // Not sure if you need composite but set it to false if you do not need it } ] } ] }
... View more
01-09-2019
01:20 PM
|
6
|
6
|
55959
|
|
POST
|
Can you send me the url you are using the also the json used. I will check and let you know.
... View more
01-09-2019
11:39 AM
|
0
|
9
|
11407
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 3 weeks ago | |
| 1 | 10-31-2023 07:04 AM | |
| 1 | 04-13-2023 08:40 AM | |
| 1 | 03-11-2019 03:05 PM | |
| 1 | 02-22-2019 09:06 AM |
| Online Status |
Offline
|
| Date Last Visited |
2 weeks ago
|