I am extending existing query functionality that I have added to the ArcGIS Flex Viewer. I would like to extract the results from a query--which consists of a FeatureSet--into a .gdb. In order to do so, on the Flex side (not on the arcgis server), I package the FeatureSet which contains various fields such as DEPTH, NAME, OBJECTID, Shape_Area, Shape_Length, SQKM, SQMI, and SURF_ELEV into an object and send that object in the gp.submitJob(..) method.
However, when I debug in the python script, all fields other than the default ESRI fields are missing. But when I run the same geoprocessing task via ArcMap from a computer that is connected to said arcgis server, all the fields "make it" to the python script.
What am I missing? Do I need to create a schema for the feature set? If so, I need a way to signify that I want all of the fields in a given feature set to be extracted into a .gdb, not just the default fields. Thus, I need to at-runtime determine that all fields in a selected feature set should be extracted.
Using Fiddler on the client workstation, I verified that the client is in fact sending all of the fields using ESRI's REST interfacen (I apologize for longevity of this text--I do not know how to wrap this text in a scroll bar):
{"geometryType":"esriGeometryPolygon","fields":[{"editable":false,"type":"esriFieldTypeOID","name":"OBJECTID","alias":"OBJECTID","length":0},{"editable":false,"type":"esriFieldTypeString","name":"NAME","alias":"NAME","length":40},{"editable":false,"type":"esriFieldTypeInteger","name":"SURF_ELEV","alias":"SURF_ELEV","length":0},{"editable":false,"type":"esriFieldTypeInteger","name":"DEPTH","alias":"DEPTH","length":0},{"editable":false,"type":"esriFieldTypeDouble","name":"SQMI","alias":"SQMI","length":0},{"editable":false,"type":"esriFieldTypeDouble","name":"SQKM","alias":"SQKM","length":0},{"editable":false,"type":"esriFieldTypeDouble","name":"Shape_Length","alias":"Shape_Length","length":0},{"editable":false,"type":"esriFieldTypeDouble","name":"Shape_Area","alias":"Shape_Area","length":0}],"displayFieldName":"Name","features":[{"geometry":{"rings":[[[-102.00125454546075,58.03430000004511],[-102.02916363639258,58.014445454993904],
..many more points of the same format...
[-102.06139090936284,57.97054545490898],[-102.06470909115149,57.96471818169891],[-101.99665454557066,58.05915454544606],[-101.99804545413424,58.05359999974035],[-102.00125454546075,58.03430000004511]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":1106,"mx_internal_uid":"BBF9CA8C-BD0A-525E-E313-161A941F052E","DEPTH":720,"Shape_Area":1.027507492553979,"SQMI":2650.35826,"Shape_Length":11.08318803767113,"OBJECTID":8,"SQKM":6864.42385,"NAME":"Reindeer Lake"}},{"geometry":{"rings":[[[-98.04324545471383,51.95830000024501],[-98.0452727271545,51.959990909153305],[-98.04749999982499,51.963609091286685],[-98.04722727232057,51.96888181824147],[-98.0394454548437,51.99027272730467],[-98.03889090948775,52.00054545460921],[-97.5291727276391,51.953327272735635],[-97.53110909121142,51.94777272702987],
..many more points of the same format...
[-97.90889090938782,51.89221818142408],[-98.02055454505609,51.9408272727606],[-98.02555454540578,51.94360000043986],[-98.04324545471383,51.95830000024501]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":713,"mx_internal_uid":"71F4CD7B-942E-B02A-46E8-161A9442FDEE","DEPTH":92,"Shape_Area":3.4024591797563333,"SQMI":9868.1025,"Shape_Length":17.96255474055849,"OBJECTID":10,"SQKM":25558.37043,"NAME":"Lake Winnipeg"}},{"geometry":{"rings":[[[-99.3278090910166,53.15415454589572],[-99.36220909097659,53.15359999964045],[-99.42528181780148,53.14804545483406],[-99.4399909088532,53.14360909108683],[-99.4424909090281,53.13999090895345],[-99.44444545419418,53.130545454509274],
..many more points of the same format...
[-99.35972727239556,53.19054545420949],[-99.34916363599285,53.184718181898745],[-99.34527272725438,53.1799909090534],[-99.3278090910166,53.15415454589572]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":831,"mx_internal_uid":"13856FA4-A0CE-34F0-F568-161A94454A36","DEPTH":-999,"Shape_Area":0.6357356264323402,"SQMI":1802.86813,"Shape_Length":9.32114504990166,"OBJECTID":11,"SQKM":4669.42571,"NAME":"Cedar Lake"}},{"geometry":{"rings":[[[-99.63074545423916,51.845199999780334],[-99.62805454508106,51.84304545438437],[-99.62360909098663,51.83416363654277],[-99.6199909088532,51.81388181819153],[-99.62416363634259,51.80277272767938],[-99.62999090865338,51.79694545446933],
..many more points of the same format...
[-99.66944545464389,51.86999090915333],[-99.66221818162364,51.86666363611806],[-99.63361818203333,51.84749090937811],[-99.63074545423916,51.845199999780334]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":830,"DEPTH":39,"Shape_Area":0.7438702242148675,"SQMI":2159.28717,"Shape_Length":8.405120389115407,"OBJECTID":12,"SQKM":5592.55047,"NAME":"Lake Winnipegosis"}},{"geometry":{"rings":[[[-98.16574545428915,51.78261818138412],[-98.1666545456706,51.78082727236091],[-98.16860909083671,51.77832727308533],
..many more points of the same format...
[-98.16444545459393,51.79527272715478],[-98.16139090906307,51.79277272697993],[-98.1597272729951,51.78999090895342],[-98.16574545428915,51.78261818138412]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":-9999,"DEPTH":-999,"Shape_Area":0.045076073227527845,"SQMI":133.41622,"Shape_Length":1.1857234795218847,"OBJECTID":13,"SQKM":345.5478,"NAME":"Lake St. Martin"}},{"geometry":{"rings":[[[-99.53015454589541,51.7502363635175],[-99.48611818160862,51.78582727271066],[-99.44388181849098,51.807209090527294],
..many more points of the same format...
[-99.5675090912714,51.68138181791676],[-99.56277272717949,51.6927636359332],[-99.53528181830116,51.746100000115064],[-99.53015454589541,51.7502363635175]]],"spatialReference":{"wkid":4326}},"attributes":{"SURF_ELEV":813,"DEPTH":92,"Shape_Area":0.6366848837080259,"SQMI":1915.78797,"Shape_Length":7.857276273220617,"OBJECTID":14,"SQKM":4961.88793,"NAME":"Lake Manitoba"}}],"fieldAliases":{"SURF_ELEV":"SURF_ELEV","DEPTH":"DEPTH","Shape_Area":"Shape_Area","SQMI":"SQMI","Shape_Length":"Shape_Length","OBJECTID":"OBJECTID","SQKM":"SQKM","NAME":"NAME"},"spatialReference":{"wkid":4326}}
How do I do this?
