Add new row to DataGrid with sequential ID

Hey there, just wondering how I can correctly add new rows to the DataGrid element, where the ID for the newly added row follows sequential order based on ID’s that currently exist.

For example, I have 2 rows in my table with ID #1 and ID #2.

I have my action setup on a button to insert a row in my database when clicked.

In the ID section what formula do I use so that it would create the new row with ID #3?

Currently I have this: rollupSum(Pricelist.Data,‘id’) which doesn’t work well as it calculates all of the ID values found and then adds for example #5 and then #10 to my database.

I tried to use the build in AI but it keeps outputting things that end up with “max is undefined” etc.

It’s probably so simple, but I am not really familiar with formulas like this. Any help will be so appreciated :pray: