Select to view content in your preferred language

Can't create field indexes on feature layer with related table

359
2
Jump to solution
02-04-2026 08:11 AM
MattCashen
Regular Contributor

I have a feature layer in AGO that is published every day with a related table.  I have a script set up that creates new field indexes on the feature layer after it is republished.  I noticed today that the field indexes weren't being created.  When I run the script, I get the error "Exception: Unable to add feature service layer definition. A full-text index cannot be created on the table or indexed view because duplicate column 'FIELDNAME' is specified" I assumed this was a problem with the script, but when I go into AGO and try and manually create the field index it tells me that an index can't be created.  I'm guessing this may have been happening since the last AGO update and I only just noticed.  I'm fairly certain it is being caused by the related table as I don't have this issue with other layers that don't have related tables.  Is this a bug within AGO or is this just a limitation I'm going to have to deal with going forward? 

0 Kudos
1 Solution

Accepted Solutions
RPGIS
by MVP Regular Contributor
MVP Regular Contributor

One thing you can try as a simple test is to create a very small copy of the datasets/tables and run the script on that small sample to see if it is the script trying to match a field that might be duplicating. If it doesn't then it might be a potential issue with the layer possibly.

Another option is to overwrite the layer and see if that republished dataset/tables fixes the indexing issues.

View solution in original post

0 Kudos
2 Replies
RPGIS
by MVP Regular Contributor
MVP Regular Contributor

One thing you can try as a simple test is to create a very small copy of the datasets/tables and run the script on that small sample to see if it is the script trying to match a field that might be duplicating. If it doesn't then it might be a potential issue with the layer possibly.

Another option is to overwrite the layer and see if that republished dataset/tables fixes the indexing issues.

0 Kudos
MattCashen
Regular Contributor

@RPGIS 

Thanks for the suggestion to overwrite the layer.  The layer gets overwritten every day via a script and after reading your comment I noticed that it took over twice as long to run this morning than usual.  So I went ahead and ran the script again.  The indexes are now working.  There must've just been an issue when the script originally ran this morning.  

0 Kudos