Key reverts back to _rownumber

Hi,

One of my tables will not allow me to change the key. It keeps reverting back to _rownumber each time I save no matter which column I choose.

I have similar tables and it lets me change the key on those…

Cheers

Troy

Possibly your column, trying to be a key column, has something like

  1. Spreadsheet formula

  2. Long text typ column,

which are not allowed to be key column. That s could be a reason.

3 Likes

Thanks for the reply!

I have even tried creating an ID column with pure numbers in it 1,2,3 etc.

Still wont let me use as key.

I have similar tabs in my sheet and have no problems using other columns as key.

Did you check there is no spreadsheet formula ?

4 Likes

Yep. I just plugged numbers in manually. Still won’t work.

Please contact AppSheet Support for help with this.

1 Like

No help from Appsheet support.
My problem is, I need to delete the empty rows in my app, but all rows are showing up.
I don’t want to have to add another number to the ID column each time I input more data.
But this seems to be the only way.
I have another table that has pretty much the same ARRAYFORMULA, and I am able to use this as a key.
Wondering why this only happens on one table??

Does your key column have a formula or not? It’s not clear for me..

Also, are there any errors shown on the editor when the key column checkbox is changed to _RowNumber?

Finally, make sure that the values of any column you want yo use as Key are unique, the best practice for 99% of people is to just leave one real column on their dataset and populate it with UNIQUEID() or UNIQUEID(“UUID”)

2 Likes

Hi TJK,

Were you able to resolve this problem? I have the same issue even after having applied the recommendations in this thread?

Is your key column of Text column type? LongText won’t work. Also check my previous comment

Thanks for that, had to add another column and populate with UNIQUE(). Works wonders.

I had been facing the same issue. What has worked for me is to regenerate the schema and then try to set the desired field as KEY. Mostly it has worked for me.