Field Mapping in script tool

4664
3
08-03-2014 11:18 PM
RiyasDeen
Occasional Contributor III

I'm trying to create a script tool with field mapping, similar to append tool in in data management.

I want user to be able to specify two layers, one source and one destination. Once source layer and destination layer are specified populate common fields to populate source and destination layer as field map.

 

When i specify Field mapping parameter, i have to manually specify output field manually, still it won't let me establish relation between two fields from these two layers.

 

Untitled.png

Tags (2)
0 Kudos
3 Replies
DuncanHornby
MVP Notable Contributor

Riyas,

Have a look at these pages:

From your question it sounds like you want to be running custom code in the validation section of the script tool? This page talks about making a choice list but it shows how you get in and out of the validation part of the tool. Other people have scripted this and here too.

0 Kudos
RiyasDeen
Occasional Contributor III

Hi Duncan,

Thanks for your reply.

What i'm actually looking for is to establish join between two layers using more than one field. Users should be able to specify the field combinations.

0 Kudos
HenryColomb
New Contributor II

Hello Riyas

   Did you ever find a solution to this? I am able to populate the Field Map control in the validation script ok but when I try to access the shortcut menu there is no "Add input field" item like there is in the merge tool for example.

Thanks

0 Kudos