Allow duplicate entries in appsheet form

I have created an app/form on AppSheet to record sales orders. The form consists of three things barcode, Product Name, and Qty. The problem is when I scan the same barcode which was already submitted before an error pops up that "There is already a row with the key 'xxxxxxxxx (barcode number)'"

 

Could anyone suggest me a workaround to allow duplicate entries in AppSheet forms? Note that I'm on a free plan and not using a subscription. 

Solved Solved
0 7 1,299
1 ACCEPTED SOLUTION

@dhaval if added in the following field of the auto compute section, the "initial value" field, it should work fine.

View solution in original post

7 REPLIES 7

Hi @dhaval 

Have you tried adding a new column, such as IdOrder, and set it as a Key instead of the barcode?

Your key column must be unique

Let me know if it works out

Yes! this works! 
But, is there any way to automate the entries in Key Column? Like, every time user opens the app, the first/key field should be prefilled with the current date and time.  

Yes, you can automatically create a unique value in the auto compute section of your key column, similar to what is described here

https://www.googlecloudcommunity.com/gc/AppSheet-Q-A/Can-AppSheet-auto-generate-the-Unique-ID-column...

Instead of UniqueID you can create your own combination of dates and time, using CONCATENATE() https://support.google.com/appsheet/answer/10107400?hl=en

or you can simply use NOW() https://support.google.com/appsheet/answer/10108119 which returns the date-time of the current date and time (DateTime value).

franc_0-1659969567501.png

 

You could also add an additional unique number to your date-time if many people use the APP at the same time, similar to what is described here

https://support.google.com/appsheet/answer/10105828?hl=en

Please let me know if you need any further assistance, if you like the answer and if it solves your question.

 

@franc @Steve I tried to add now() in the auto compute section but it says "Key column 'ID' in Schema 'Sheet1_Schema' cannot use an app formula. The app formula will be removed". is it that we can't automate key column using formula?

@dhaval if added in the following field of the auto compute section, the "initial value" field, it should work fine.

Yes! it's working, thanks!

Top Labels in this Space