Skip to main content
Question

How do I generate unique ids from existing and future object ids ?


Forum|alt.badge.img

How do I generate unique ids from existing and future object ids within a 50000 range and 30 diffattributeerent s within a 50000 range.There are 30 different attributes and each should be within a set block; i.e pt=10000; rt=20000;st=30000, etc. These are within an ESRI File GDB.Please help.

@useytkaziev

3 replies

danilo_fme
Evangelist
Forum|alt.badge.img+44
  • Evangelist
  • March 9, 2018

Hi @charlesbanks,

I believe that you can compare these values ( if has a not unique ids ) with a temporary data, for example Excel file using the transformer FeatureWriter. After a transformer Tester to compare the Ids from you Reader ( Input ) and your temporary XLS.

Thanks,

Danilo


Forum|alt.badge.img

How do you set them apart in blocks? These are values within a File Geodatabase (Object IDs).


gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • March 12, 2018

fid in shapes are just like row numbers. Delete a row and all is reset.

Generating unique id's from those will only be valid as long as you don't rerun the generation based on these fid's.

If you want to partition your data based on attributes, create a group by attribute based on the required attributes. Usually by concatenation.

GroupBy= @Value(pt) @Value(rt ) @Value(st) @Value(etc.)

Or if string is getting bit long, by using a counter to id each attribute and create Group By of those values

Use the group by value in a counter.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings