|
POST
|
No it wont. The task will only make the output zip file. I just assumed because you were using doing a variable number of input layers to clip that your end goal was to actually extract them for download. You're going to need to look at using the iterators inside model builder and build the task yourself. However, at this point I'd say a python script might be more straight forward and give you more flexibility. I'm not entirely sure you can setup a model with an iterator to accept multiple layers and iterator over them. (Because your input will probably be featurelayer:multivalue). Thus in a script you'd accept the multivalue, then split the inputs and iterate over them in a loop. I'll point this out though - GP Services do not like when you have variable numbers of outputs. For example, if your tool accepts 1-5 layers as an input, you could set it up to have 1-5 output featureclasses (after the buffer/clip operation). The problem being, GP Services want well defined scenarios, so if your user only selects 2 layers, but the service expects 5, it doesnt get all the outputs back it was expecting too. So you'll need to come up with a single parameter, passing back a multivalue. (I cant remember off the top of my head if this will work, its been a long time since I've worked with output:multivalue). The take home point here is: you'll have to set your model or script up in a given way to work properly as a gp service and I can't tell you that particular way without knowing your exact requirements. However, this all could be moot if you're just wanting to return the "clip" results as a map image (instead of the features sent back to the client to be drawn). That is a snap shot of the output to be drawn on top of your map. But at this point I'm making a lot of assumptions on your workflow and end goals. Hopefully some of the thoughts above will allow you to move forward with your workflow.
... View more
11-20-2015
08:38 AM
|
1
|
0
|
2081
|
|
POST
|
Look at using the Extract Data Task. It already does what you want (clips multiple layers). The only thing you want to do is pull that model into your own model where you'll have buffer as the first tool and the output of buffer is passed as the selecting features to the extract data task. (Because the EDT is setup to accept a polygon that a user could draw, thus you're just tweaking the front end experience)
... View more
11-19-2015
06:04 AM
|
1
|
2
|
2081
|
|
POST
|
Has anyone tried Project Templates? Start a new project. Add a map or scene, regularly used folder connections or databases and anything else you want direct access to. Next time you make a new project, don't use a blank one, select the template you previously made and give your new project a name/location. You should start with all the items you setup from before. More information here. Please don't consider this a dismissal of the original idea/ enhancement, I'm just offering alternatives that can move you towards your goals, today.
... View more
11-03-2015
08:09 AM
|
2
|
1
|
1867
|
|
POST
|
You say widget, so I assume you're using the WebAppBuilder (WAB)? If so, yes, it is smart enough. If your input parameter is setup as an interactive feature set (like you draw a box inside ArcMap), then when you use the WAB - GP widget against the GP Service you've made, it is smart enough to provide an interactive draw option in the web app itself. So no extra code required.
... View more
10-26-2015
07:27 AM
|
2
|
1
|
1030
|
|
POST
|
You need an input parameter. As is, your model is hardcoded to do the same thing over and over. I'm not sure if you want to select your Land Acquisition or your SDE data - either way, when the model is run that same data is always acted against. If you want to provide a sort of interactive selection against one of those layers, you'll need to make the selecting features a feature set and turn it into a parameter. See this for understanding parameters: Creating model parameters—Help | ArcGIS for Desktop This is a generic select (by attribute) example for GP Services: Geoprocessing service example: Selecting data—Sharing geoprocessing workflows | ArcGIS for Desktop
... View more
10-26-2015
06:55 AM
|
2
|
3
|
1030
|
|
POST
|
You're correct that GP Server considers CAD as a non-transportable type. You'll need to modify your workflow into a script. From there you can either use a FILE or a STRING variable as input. (Sounds more like you want to use STRING). Within the script you're responsible for passing the "cad file path" to the CAD to Geodatabase tool. (I just tried in MB but the CAD to Geo tool seems pretty strict on the inputs, thus you wont be able to make a multi-string variable or a multi-file variable and hook it up to the point the tool will run. A script should get you around the validation requirements of the tool.)
... View more
10-08-2015
07:57 AM
|
0
|
1
|
3701
|
|
POST
|
Could you output 1 featureclass, but have anywhere between 1-4 features/records in that FC? Build a layerfile that has symbology set for 4 features based on a given field. Then in the script, generate those features and in the script tool output parameter symbology, use the layer file. After you publish the service and run it in arcmap, it'll draw the features based on that layerfile.
... View more
08-13-2015
08:23 AM
|
1
|
1
|
2760
|
|
POST
|
Ok, your 2nd problem. GP Services are very strict with their input and output params. Optional output params in a GP Service is well........ not straight forward. Outputs get hardcoded with a gp service. When you run your tool in ArcMap before publishing, this sets up the "footprint" if you will of what the service will be like. So if you had 3 outputs when you ran in AM, once you publish it the service will want 3 outputs. Not 2, not 4, but 3. So anytime you start playing the optional game you're going to get into trouble. For the 1st issue - I dont really understand what you're saying here. I can only guess this is a "tool problem", that is how the tool has been setup/configured. You're having the problem here before publishing? Or this is the published gp service? You're expecting to get the result back from the gp service and it gets added to ArcMap? As long as the output is a featureclass in the tool, yes it should be automatically added.
... View more
08-13-2015
07:49 AM
|
1
|
3
|
2760
|
|
POST
|
What is your end goal? Using arcpy.mapping.MapDocument has pretty limited use in a GP Service. Its mainly good for printing and exporting. If you're trying to use this workflow to update a map you have locally...well I dont see the connection. If you can explain what you want to do (not how you're trying to do it), maybe someone can suggest a workflow.
... View more
08-13-2015
06:22 AM
|
1
|
5
|
2760
|
|
POST
|
You must be using the 10.0 version of the tutorial. Try the 10.1+ version here: Geoprocessing service example: Clip And Ship—Sharing geoprocessing workflows | ArcGIS for Desktop (The steps you mention are telling you to make a "tool layer", a concept that does not exist in 10.1+)
... View more
07-29-2015
08:58 AM
|
2
|
0
|
2311
|
|
POST
|
I'm sorry to report that we did not fix this in 10.3.1. We had attempted a fix but were not happy with the results, as such the issue still present. We are committed to fixing this issue and will try to it addressed in the next release (10.4)
... View more
06-18-2015
09:30 AM
|
1
|
6
|
2066
|
|
POST
|
As Bill Daigle suggests, this is the sure workaround to the problem, its quick and easy and should move you forward. os.path.join("in_memory", "myInMemFeatures") # == "in_memory/myInMemFeatures"
... View more
06-12-2015
06:36 AM
|
1
|
2
|
3646
|
|
POST
|
Without seeing your model or script, it sounds like the input parameter to it is a file (GPDataFile as you reference). Before publishing you'd need to setup the model or script with an input parameter of TABLE. Take special note though, that when publishing the result as a service, depending how you provided input to the parameter it may make a best guess and try to change it. Ensure that the input to your service stays as a "user defined value" (it'll show the schema of the table in the service editor for you to confirm). Once published, it'll be a GPRecordSet. Getting the required input JSON correct can be troublesome. If you go into ArcMap and open the Python window, you can get JSON code from your CSV by putting these lines: rs = arcpy.RecordSet() rs.load("c:/path/to/file.csv") rs.JSON
... View more
06-02-2015
09:56 AM
|
1
|
1
|
1135
|
|
POST
|
What exactly is the question? You've talked about how parameters work in regards to a GPRecordSet, but what exactly is your problem or where are you stuck?
... View more
06-02-2015
07:32 AM
|
0
|
3
|
1135
|
|
POST
|
It's not a ridiculous idea, but you do have to construct the service/web app in a certain way. I'd step back and ask why you're using them as 2 separate tasks in the server environment? Is there some sort of technical limitation that blocks you from either producing a single script, or even adding these 2 script tools into modelbuilder and having the output of 1 be the input to the 2nd? This is going to be the absolute simplest and most straight forward way to get what you want. If you need to keep them as 2 distinct services, it'll be you who is responsible for getting the output from one to the other. Your web application will act as the glue between the two. Since your output is a layer the first service will either need to send the featureclass back to the webapp and the webapp will have to send the features back to the 2nd service or the 1st service will have to send the location the features are on disk (server side) and the webapp would pass this reference to the 2nd service. Both these options arent great. Why? Option 1 = the transfer of features when you dont really need to. (but you do need to because you have 2 services) Option 2 = you're sending paths and information about the server back to the client. Even if its just the webapp getting this information and the user doesn't see it, I'd still consider this a minor security flaw as you're web-exposing information about the server itself. So, again, what you want to do is possible, but I'd strongly suggest pushing both tools into a model and publishing that.
... View more
05-28-2015
10:13 AM
|
0
|
1
|
1284
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 09-20-2023 06:37 AM | |
| 1 | 09-18-2025 07:07 AM | |
| 3 | 09-18-2025 06:52 AM | |
| 1 | 03-23-2023 12:07 PM | |
| 1 | 10-21-2024 12:40 PM |
| Online Status |
Offline
|
| Date Last Visited |
09-30-2025
06:25 AM
|