Geoprocessing Widget Ouput Parameter

3285
7
Jump to solution
05-02-2013 12:37 PM
IsaiahAguilera
Occasional Contributor II
I am currently trying to make the geoprocessing widget output a table.  I have published the geoprocessing service and when I set up the widget the way I think it is suppose to work I can hit run and it creates the table on the server ( I can see it if i remote in ). But it just throws an error in flex instead of downloading the dbf.  I am not sure if I need to do something on the model side or the flex side.

XML output params
 <outputparams>         <param name="task_dbf"                label="Output dbf file"                required="true"                type="datafile"                visible="true"/>     </outputparams>


I did notice that if I go to the service through a browser and look at the output param in rest services the type is "GPRecordSet". I don't know how to make the type "file" or even if that's what is causing the issue. I know its vague but any help where to start would be great! My goal is to download the dbf upon completion. Thanks
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
IsaiahAguilera
Occasional Contributor II
I found a solution on arcgis desktop help. It is a python script that Zips your workspace and makes it available for download. Now I am able to get my dbf and just unzip it after its downloaded.
http://resources.arcgis.com/en/help/main/10.1/index.html#/Input_modes_and_parameter_data_types/00570...

Its about mid way down the article.

View solution in original post

0 Kudos
7 Replies
Juan_CarlosFranco
Esri Contributor
In order to download the DBF file, you need to change the GP task's task_dbf output parameter type to GPDataFile instead of GPRecordSet. Otherwise, the only option available is to display the table in the widget:

<outputparams>
  <param name="task_dbf"
              label="Output dbf file"
              required="true"
              type="recordset"
              visible="true"/>
</outputparams>
0 Kudos
IsaiahAguilera
Occasional Contributor II
Thanks for your response.  I was thinking that but I am not sure how I am suppose to do this.  This is coming from a model that is being published and when I publish it makes it "GPRecordSet" without me doing anything. How do I go about changing it to "GPDataFile"? I am not sure if the model has to be changed or this is a publishing option.

Thanks,
0 Kudos
GISDev1
Occasional Contributor III
Thanks for your response.  I was thinking that but I am not sure how I am suppose to do this.  This is coming from a model that is being published and when I publish it makes it "GPRecordSet" without me doing anything. How do I go about changing it to "GPDataFile"? I am not sure if the model has to be changed or this is a publishing option.

Thanks,


It is changed in the actual model in ArcMap. ArcGIS Server just reads the parameters of the model.
0 Kudos
IsaiahAguilera
Occasional Contributor II
Thanks, my issue is my parameter in model builder is listed as "Table" and not as "File" and I can't really find a tool that can give me a parameter type "File" from my output table.  I know I must be missing something but any help to this specific issue would be great.
0 Kudos
GISDev1
Occasional Contributor III
Thanks, my issue is my parameter in model builder is listed as "Table" and not as "File" and I can't really find a tool that can give me a parameter type "File" from my output table.  I know I must be missing something but any help to this specific issue would be great.


Right click your tool in ArcCatalog and go to properties, then go to the parameters tab.
0 Kudos
IsaiahAguilera
Occasional Contributor II
Right click your tool in ArcCatalog and go to properties, then go to the parameters tab.


My problem isn't finding a list of the parameters it is changing the data type from table to file.  I can create a variable with data type "file" but I am not sure how to link it in to the model since that data type won't seem to connect to anything.
0 Kudos
IsaiahAguilera
Occasional Contributor II
I found a solution on arcgis desktop help. It is a python script that Zips your workspace and makes it available for download. Now I am able to get my dbf and just unzip it after its downloaded.
http://resources.arcgis.com/en/help/main/10.1/index.html#/Input_modes_and_parameter_data_types/00570...

Its about mid way down the article.
0 Kudos