Edit sql azure database

Hi Guys,

I’ve deployed an app and it works well. now Im looking to upgrade the info to an azure database.
I’ve setup an azure database on a free trial; I’ve allowed my subnet to access the database.
When I create the new test appsheet app I am able to connect the datasource to the database I created in azure.
But im not able to edit or add any new data into the database. I get the error Unable to add/edit/delete row in table ‘dbo.‘Asset Register’’. → The _RowNumber column is not a valid key column as it does not exist in the database

I opened sql managament studio on the same pc just to ensure im able to login to the database with the same credentials and I am able to edit the same column.

The table is set to update, add or edit does anyone know why im not able to edite this database from the app please.

Please see screenshots on my goolge drive for more clarity.

usp=sharingscreenshots

0 5 384
5 REPLIES 5

aeastham
Participant II

This means you have to set a different column to be the Key. Does your data have an obvious ID (eg something like “Asset Id”) that is unique within the table? If it does, just go in and edit the columns to change the Key to be that column.

Usually you also set the key column to be the primary key in the SQL table.

Andy

Steve
Participant V

I don’t believe the _RowNumber column is present in SQL tables; I think AppSheet only provides it for spreadsheet-based data.

@Steve
_RowNumber is present in SQL and in general it’s set as the PK by-default unless you state otherwise.

Good to know! Thanks, @LeventK!

You’re welcome

Top Labels in this Space