Is it also possible to use Calculate Value with the Table Iterator? I have 9000 tables each with a column name that needs altering. So for example, all the tables have a column called 'Rastervalu', I would like to change this name for each column to represent a unique value which is the table name. So again in first table 'RasterValu' will be called 'GP-CodeA82010'.
As I am hoping to eventually join these tables to a master table. Using model builder I would like to truncate/drop the 'GP_Code' part of the name and leave the name as 'A82010' and so forth.
Am very new to Python but have tried different expressions as follows;
Right([FieldName], 6)
"%Name%"[7:13]
"%Name%".replace("GP_Code","")
However the Calculate Value model only tool does not appear to do the job, so instead of slicing the 'GP_Code' bit inorder to give me the reduced name, it is giving me a value of 1 (see attached image)
Any ideas of what I might be doing wrong? or what script I should be using?
Many thanks
Penny