IBM Support

Querying a Layer in REST for Maximo ArcGISDataSync Spatial Crontask

Question & Answer


Question

How can I get the URL for the Spatial ArcGISDataSync Crontask?

Cause

This will be needed when entering the URL parameter within the crontask

Answer

To get a simple URL for your Crontask URL Parameter, or for otherwise, please follow the following:

We will use the Feature Service layer as an example: http://sampleserver6.arcgisonline.com/arcgis/rest/services/Water_Network/FeatureServer/8

1) Open this link (or your feature service).
2) At the bottom of the page, you will see the "query" option for "Supported operations". Click this.
3) You can now query your map service based on an attribute. Example: activeflag = 1
"activeflag" is a useful attribute for the crontask, since the crontask will filter based on this field to know what to process.





4) In the "Out Fields", enter the value " * ".
5) At the end, change the "Format" to "JSON". HTML is the default.

When you search, you will see the results in JSON format. You can copy the URL. It will seem similar to below:
http://sampleserver6.arcgisonline.com/arcgis/rest/services/Water_Network/FeatureServer/8/query?where=activeflag+%3D+1&objectIds=&time=&geometry=&geometryType=esriGeometryEnvelope&inSR=&spatialRel=esriSpatialRelIntersects&relationParam=&outFields=*&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&gdbVersion=&returnDistinctValues=false&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&multipatchOption=&f=pjson

However, within this are a lot of parameters we don't need. So this can be shortened to the following by removing the parameters that are not queried. Each parameter starts with "&parameterName=":
http://sampleserver6.arcgisonline.com/arcgis/rest/services/Water_Network/FeatureServer/8/query?where=activeflag+%3D+1&outFields=*&f=pjson

To Shorten even further, you can use the link to decode: http://meyerweb.com/eric/tools/dencoder/

After this is completed, your link will look like this:http://sampleserver6.arcgisonline.com/arcgis/rest/services/Water_Network/FeatureServer/8/query?where=activeflag=1&outFields=*&f=pjson

You can use now use the final link within your ArcGISDataSync Crontask.

[{"Product":{"code":"SSG2D3","label":"Maximo Spatial Asset Management"},"Business Unit":{"code":"BU005","label":"IoT"},"Component":"Not Applicable","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"7.6","Edition":""}]

Document Information

Modified date:
17 June 2018

UID

swg21983319