Zum Hauptinhalt gehen

domain values for subtypes

Kommentare

10 Kommentare

  • Permanently deleted user

    Jeff,

     

    Could you elaborate little more since I can't follow?

    (1) a table with subtypes? What do you mean by that? Do you mwan that you have a table which contains a column named 'subTypes'? Do you want to use the SqlQuery to get the DataTable, and set from it to the input Data source for the combobox?

    (2) I may not understand fully your situation. I have used mostly the 'Get Coded Value Domain' WF Acitvity which takes FeatureLayerUrl, FieldName etc. to return either DataItem List or Dictionary<object, value>.

    Munhwan

    0
  • Permanently deleted user

    ok, lets try this again

     

    i have a table with a field that has subtypes.  how do i retrieve the domains of the subtypes?  i want to derive a list to put in a listbox or autocombo box.

    Subtype is an integer with domains that are dependant on the value within the field.  

     

    For example our field (land ownership) has two values "federal" and "non-federal."  federal has subtype "1" and non-federal has subtype 2.  the domains for federal ,subtype 1, are: "blm","park service", "BIA", etc.

    the domains fro non-federal, subtype 2, are: "private","county","state", etc.

    So when the user pics "federal" in an autocombobox selection for "land ownership", then the next autocombobox should display the domains for "federa.l"

    if the user picks "non-federal" in the autocombobox selection for "land ownership", then the next autocombobox should display the domains for "non-federal."

    I want to know, then, how to retrieve the domains of a given subtype for a value in a field that has defined subtypes.

    does that help??

    Jeff

     

    0
  • Nico Burgerhart

    As far as I know this is not possible, unfortunately.

    0
  • Permanently deleted user

    Jeff,

    (1) Cascading among two Auto-Completeboxes is not possible, while cascading among parent combobox and child combobox (or Auto-completebox) should be possible.

    (2) re: Datasource for the cascading, I can see little the better. If possible, could you take a screenshot which shows the Fields definition of the layer to hightlight to fields in the layer?

    Let me summerize what I understand in my word (my background is not GIS, but pure SW developer. Please understand not to grab easier what you said since when you use the term 'table', 'field', I see them as pure db term.

    If we can figure out how cascading controls works, it does not matter if we are dealing with the Code Value Domain or not. It is because it is matter of a value of the combobox control (or Listbox) is Code (1, or 2) or Value (Federal of Non-federal). An activity 'Get-Code-Domain- Value) will return 'List<object, string>' or List<DataItem> which contains List<code, value> or a single DataItem of the list will be (code / value).

    Having said. this is what I understood based on what you describe in my word.

    You have a layer i.e.   'Land ' which contains two fields: (1) LandOwnership which is CodeValueDomain field and its values are either Federal with code 1, or Non-Federal with code 2, (2) SubType, which contains a value from a set blm","park service", "BIA", etc when 'LandOwnership' is 'Federal', or a value from a set of  "private","county","state", etc when 'LandOwnership' is 'non-Federal'.

    is it right what you have as the datasource you want to set two cascading controls? (Once again, it will be helpful to show the datasource in Screenshot as I requested above).

    If my understanding is correct, I think you can set the cascading controls by follwing the way that we can set mostly three cascading controls  for 'Township - Range -County', but using Code value domain as the value of the control.

    You may use the Gcx Support ticket for the further help.

    Munhwan

     

    0
  • Berend Veldkamp

    Well, it looks like the information you need is in the json returned from the mapservice, e.g. http://[SERVER]/arcgis/rest/services/[SERVICENAME]/MapServer/0?f=pjson (search for the text "types": [ ). You could probably use regular expressions to extract what you want, or maybe convert the json to a dictionary first, YMMV.

    However, if you want cascading controls on one displayform, I don't think that can be done with standard functionality. But if you are a developer (or know one), you could write a custom REST endpoint that returns the domain list for a given subtype in the form of a json featureset (I once did something similar).

    0
  • Permanently deleted user

    Are typoes and subtypes now supported in workflow queries and workflow forms?  here is any example from our rest service:

    Type ID Field: FET_TYPE

     

    Fields:

    OBJECTID ( type: esriFieldTypeOID , alias: OBJECTID )

     

    FET_TYPE ( type: esriFieldTypeInteger , alias: Feature Type )

     

    FET_SUBTYPE ( type: esriFieldTypeString , alias: Feature Subtype , length: 50 )

     

    FET_NAME ( type: esriFieldTypeString , alias: Feature Name , length: 50 )

     

    ADM_UNIT_CD ( type: esriFieldTypeString , alias: Administrative Unit Code , length: 8 , Coded Values: [AK000000: ALASKA] , [AK996000: FAIRBANKS FIELD STATION] , [AK997000: VALDEZ FIELD STATION] , ...248 more... )

     

    ADMIN_ST ( type: esriFieldTypeString , alias: Administrative State , length: 2 , Coded Values: [AK: Alaska] , [AZ: Arizona] , [CA: California] , ...9 more... )

     

    LATITUDE ( type: esriFieldTypeDouble , alias: Latitude )

     

    LONGITUDE ( type: esriFieldTypeDouble , alias: Longitude )

     

    QC_REVIEWER ( type: esriFieldTypeString , alias: QC Reviewer Name , length: 50 )

     

    QC_DATE ( type: esriFieldTypeDate , alias: QC Date , length: 36 )

     

    QC_DELETE_FEATURE ( type: esriFieldTypeString , alias: QC Delete Feature Flag , length: 50 )

     

    QC_COMMENTS ( type: esriFieldTypeString , alias: QC Comments , length: 255 )

     

    DATA_SOURCE ( type: esriFieldTypeString , alias: Data Source , length: 50 )

     

    ORIG_STATE_FET_TYPE ( type: esriFieldTypeString , alias: Original Feature Type from State Data , length: 255 )

     

    SHAPE ( type: esriFieldTypeGeometry , alias: SHAPE )

    Types:

    ID: 4

     

    Name: DAY USE SITE

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Interpretive Site: Interpretive Site] , [Picnic Area: Picnic Area] , [Point of Interest: Point of Interest] , ...5 more...

    ID: 9

     

    Name: AIRPLANE LANDING STRIP

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Airplane Landing Strip: Airplane Landing Strip]

    ID: 3

     

    Name: OVERNIGHT SITE

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Campsite - Developed - Reservable - Fee: Campsite - Developed - Reservable - Fee] , [Campsite - Developed - Reservable - No Fee: Campsite - Developed - Reservable - No Fee] , [Campsite - Developed - Non Reservable - Fee: Campsite - Developed - Non Reservable - Fee] , ...17 more...

    ID: 7

     

    Name: TRAIL HEAD

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Staging Area: Staging Area] , [Access Point: Access Point]

    ID: 8

     

    Name: PARKING AREA

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Parking Area: Parking Area]

    ID: 2

     

    Name: WATER BASED SITE

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Boat Launch: Boat Launch] , [Boat Ramp: Boat Ramp] , [Boat Takeout: Boat Takeout] , ...3 more...

    ID: 1

     

    Name: INFORMATION CENTER SITE

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Visitor Center: Visitor Center] , [BLM Ranger Station/Field Office/Contact Station: BLM Ranger Station/Field Office/Contact Station]

    ID: 5

     

    Name: TOILET

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Toilet: Toilet] 

     

     

    so how do i query the id to get the Name and coded values for the fet_subtype

    JEff

    0
  • Permanently deleted user

    I am now able to get the types and the names of the types and the domain name for each type, but what i really need to know how to get is this:

    example from rest service, we have a subtype 4 with a name of day use site and a domain of fet_subtype.  how to I retrieve the coded values from that domain. since its in a subtype i cannot use the get coded value domains activity.

    you can use the getfeaturelayerinfo activity to get a list of "types" and the names of the types to put in a pick list. 

    after you use the getfeaturelayerinfo activity the following strings will display the id and name of the type using (type id 4)

    featureLayerInfo1.FeatureTypes.Item(4).Id.ToString + ":" + featureLayerInfo1.FeatureTypes.Item(4).Name.tostring

    This string displayes the domain field of the individual types   

     

    featureLayerInfo1.FeatureTypes.Item(4).Domains.Keys(0).tostring

     

    what i am stuck on is how to retrieve the coded values from the domain of the subfeature as shown in the rest site clip sample below:

    ID: 4

     

    Name: DAY USE SITE

     

    Domains:

    FET_SUBTYPE:

     

    Coded Values: [Interpretive Site: Interpretive Site] , [Picnic Area: Picnic Area] , [Point of Interest: Point of Interest] , ...5 more...

     

    any help would be good.

    Jeff

     

     

    0
  • Permanently deleted user

    Hi Jeff,

    The "Feature Type Name" input argument for the Get Coded Value Domain activity might be what you're looking for here.

    Setting this value to the name of your subtype should cause the activity to only return coded domains for that subtype.

    Give it a try with "DAY USE SITE" and see if you get what you want.

    Regards,

    -Malcolm

    0
  • Permanently deleted user

     

    Malcom--

     

    I believe that the getcodedvaluedomain activity has a bug, it does not work with featurelayers with subtypes:  (i have tried it in 4.2.1 and 4.2.2)

    This is the error I am getting:

    Error: Unhandled exception: 'One or more errors occurred.' in activity '1.62: GetCodedValueDomain'.

     

      One or more errors occurred.

     

        Unable to find coded value domain information for layer 'http://ilmorso3gi7vm.blm.doi.net/arcgis/rest/services/NLCS_QC/MapServer/0', field 'FET_TYPE', and feature type 'DAY_USE SITE'.

     

    External Activity: 10836 bytes received by client

    Here are the parameters i used in the getcodedvaluedomain activity in my workflow

    featurelayerurl: "http://ilmorso3gi7vm.blm.doi.net/arcgis/rest/services/NLCS_QC/MapServer/0"

     

    feature type name: "DAY_USE SITE"

     

    field name:   "FET_TYPE"

     

    dataitemlist:  iList1

    Here is the pertinent info from the esri rest api for the featurelayer i am using:

    Type ID Field: FET_TYPE

    Fields: 

     

    OBJECTID ( type: esriFieldTypeOID , alias: OBJECTID ) 

     

    FET_TYPE ( type: esriFieldTypeInteger , alias: Feature Type ) 

     

    FET_SUBTYPE ( type: esriFieldTypeString , alias: Feature Subtype , length: 50 ) 

     

    FET_NAME ( type: esriFieldTypeString , alias: Feature Name , length: 50 ) 

     

    ADM_UNIT_CD ( type: esriFieldTypeString , alias: Administrative Unit Code , length: 8 , Coded Values: [AK000000: ALASKA] , [AK996000: FAIRBANKS FIELD STATION] , [AK997000: VALDEZ FIELD STATION] , ...248 more... ) 

     

    ADMIN_ST ( type: esriFieldTypeString , alias: Administrative State , length: 2 , Coded Values: [AK: Alaska] , [AZ: Arizona] , [CA: California] , ...9 more... ) 

     

    LATITUDE ( type: esriFieldTypeDouble , alias: Latitude ) 

     

    LONGITUDE ( type: esriFieldTypeDouble , alias: Longitude ) 

     

    QC_REVIEWER ( type: esriFieldTypeString , alias: QC Reviewer Name , length: 50 ) 

     

    QC_DATE ( type: esriFieldTypeDate , alias: QC Date , length: 36 ) 

     

    QC_DELETE_FEATURE ( type: esriFieldTypeString , alias: QC Delete Feature Flag , length: 50 ) 

     

    QC_COMMENTS ( type: esriFieldTypeString , alias: QC Comments , length: 255 ) 

     

    DATA_SOURCE ( type: esriFieldTypeString , alias: Data Source , length: 50 ) 

     

    ORIG_STATE_FET_TYPE ( type: esriFieldTypeString , alias: Original Feature Type from State Data , length: 255 ) 

     

    SHAPE ( type: esriFieldTypeGeometry , alias: SHAPE ) 

     

    Types: 

     

    ID: 4 

     

    Name: DAY USE SITE 

     

    Domains: 

     

    FET_SUBTYPE:

     

    Coded Values: [Interpretive Site: Interpretive Site] , [Picnic Area: Picnic Area] , [Point of Interest: Point of Interest] , ...5 more... 

     

    So it would be great if this bug was fixed, or if it is not a bug, please help me through putting in the right parameters. 

    is there a work around for this function, which i sorely need?

    Jeff

     

    0
  • Hugues Morenne
    Hi Jeff,

     

    did you finally find a solution ? 

     

    Regards,

     

    Hugues
    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.