Update Errors

URL:
https://<root>/<serviceName>/ValidationServer/updateErrors
Methods:
POST
Version Introduced:
10.7

Description

Using the specified version and session id, update an error feature's attributes, which are stored in the GDB_Validation*Errors tables. This is a generalized API that supports extensions to the core validation framework (for example, the ArcGIS Data Reviewer extension that contains additional metadata on each persisted error feature).

Request Parameters

ParameterDetails

f

Specifies the output format of the response. The default response format is html.

Values: html | json | pjson

gdbVersion (Optional)

Specifies the name of the geodatabase version (default is DEFAULT).

Syntax: gdbVersion=<version>

sessionId (Optional)

Specifies the sessionId (guid) used to lock the version. A client can use the sessionId to enable long transaction (undo/redo) in a version.

If the calling client is editing a named version, the sessionId must be provided; if the client is editing DEFAULT, the version may not be locked and the sessionId should not be specified.

Syntax: sessionId=<guid>

errorFeatures (Required)

The error features to be updated. The structure of each feature in the array is the similar to the structure of the json feature object returned by the ArcGIS REST API.

The ruleType property is introduced at ArcGIS Enterprise 10.8.1 to support topologyRules. The default value is validationRules.

Syntax:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
[
  {
    "ruleType": "validationRules" | "topologyRules",
    "errorType" : "object" | "point" | "line" |
                 "polygon",
    "features" : [
      {
        "globalId" : "<guid>",
        "fields" : {
          "name1" : <value1>,
          "name2" : <value2>
        }
      }
    ]
  }
]

returnEdits (Optional)

Boolean parameter that returns features edited due to errors update. Results returned are organized in a layer by layer fashion. If returnEdits is set to true, each layer may have edited features returned in an editedFeatures object.

The editedFeatures object returns full features including the original features prior to delete, the original and current features for updates and the current rows for inserts which may contain implicit changes (e.g. as a result of a calculation rule).

The response includes no  editedFeatures  and  exceededTransferLimit = true  if the count of edited features to return is more than the  maxRecordCount . If clients are using this parameter to maintain a cache, they should invalidate the cash when   exceededTransferLimit = true   is returned . If the server encounters an error when generating the list of edits is the response ,  exceededTransferLimit = true   is also returned .

Edited features are returned in the spatial reference of the feature service as defined by the services  spatialReferenceobject or by the spatialReference of the layers extent object.

The default for this parameter is false.

Values: true | false

JSON Response Syntax

JSON response:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
{
  "moment" : <datetime>,
  "success" : <true | false>,
  "error" : {                   // only if success is false
    "extendedCode" : <HRESULT>,
    "message" : <error message>,
    "details" : [ <detail> ]
  }
}

Example usages

Example one

Update error features using the updateErrors operation.

Request URL and parameters:

https://myserver.esri.com/server/rest/services/LandUse/ValidationServer/updateErrors

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
f=json
gdbVersion=UNADMIN.CAROLINA
sessionId={6F545D22-8689-4836-B22F-4DF867019DEE}
errorFeatures=
[
   {
      "errorType":"polygon",
      "features":[
         {
            "globalId":"{E1E44DA0-562A-4AE9-BC07-AC105A4A0C2A}",
            "fields":{
               "ISEXCEPTION":1
            }
         },
         {
            "globalId":"{D9DF7E5C-6B10-4517-84FC-10A971DC6899}",
            "fields":{
               "ISEXCEPTION":1
            }
         },
         {
            "globalId":"{498733A2-9561-4BE3-A25F-B356040CB481}",
            "fields":{
               "ISEXCEPTION":0
            }
         }
      ]
   }
]

JSON response:

Use dark colors for code blocksCopy
1
2
3
4
{
 "moment": 1555011525855,
 "success": true
}

Example two

Update Data Reviewer visual review errors to verified and acceptable using the updateErrors operation.

Request URL and parameters:

https://myserver.esri.com/server/rest/services/LandUse/ValidationServer/updateErrors

Update the phase of a polygon error to Verification and its status to Acceptable.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
f=json
gdbVersion=UNADMIN.CAROLINA
sessionId={6F545D22-8689-4836-B22F-4DF867019DEE}
errorFeatures=

[
{
    "ruleType": "validationRules",
    "errorType": "polygon",
    "features": [
      {
        "globalId": "{324335DE-FF1F-42BD-914A-BDD262C23981}",
        "fields": {
          "errorphase": 6,
          "errorstatus": 4
        }
      }
    ]
  }
]

JSON response:

Use dark colors for code blocksCopy
1
2
3
4
{
 "moment": 1710972223,
 "success": true
}

Example three

Update Data Reviewer visual review errors to be reviewed and unacceptable using the updateErrors operation.

Request URL and parameters:

https://myserver.esri.com/server/rest/services/LandUse/ValidationServer/updateErrors

Update the phase of a polygon error to Review and its status to Unacceptable.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
f=json
gdbVersion=UNADMIN.CAROLINA
sessionId={6F545D22-8689-4836-B22F-4DF867019DEE}
errorFeatures=

[
{
    "ruleType": "validationRules",
    "errorType": "polygon",
    "features": [
      {
        "globalId": "{318335DE-FF1F-42BD-914A-BDD53B23981}",
        "fields": {
          "errorphase": 2,
          "errorstatus": 6
        }
      }
    ]
  }
]

JSON response:

Use dark colors for code blocksCopy
1
2
3
4
{
 "moment": 1710972254,
 "success": true
}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.