I'm converting a batch of shp from one MCD to another. I can easily map 80% of the fields without any problem. But for the output MCD I need to generate a new primary key based on a concatenation of a string and a three digit increment. I've tried modifying the value (in the feature type dialog box) using the text editor, and 'string_'@Count() - this sort of works it produces 'string_1' etc but i need 'string_001' etc. Also, I already use Count() in another field which seems to confuse FME - This is probably very easy, but I'm new FME...
Solved
Generating a new primary key based on a concatenation of a string and a three digit increment
Best answer by redgeographics
You can add a Format function to it, like this:
string_@Format(%03d,@Count())
This will left-pad the count with zeroes to 3 characters.
Reply
Rich Text Editor, editor1
Editor toolbars
Press ALT 0 for help
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.