Duplicate entry warning appsheet

Our team is scanning labels, and on the backend I ref a table to match the label with qr value.

I want to build a virtual column to warn users of possible duplicate entry. of scanned QR code., but make it just that a warning, that can either be ignored or acted upon. -

this was when someone is going down a line, if they accidentally scan the same qr twice they will get a warning (already done) or something.

I don’t know where to start?

It is depending on how you set the definition of ”possible duplicate", but it could normally be compaing with previous entry. In other words, throw the alert if the current scanned value is matching with previous row value.

2 Likes

If scanning the QR code is just one step among several in a single form, you could use a column of type Show to display an appropriate message. The downside here is it would be easy for the user to overlook the message.

Whether the scan is the only input or one of several in a form, you could attach an action as the Form Saved event action that checks the scanned code and handles a duplicate if found.

See also:

the issue, its 39 questions this having that - its been entered already message would help aid that process.

Sorry, I wanted to say 39 questions - I would rather stop warn the user the entry has been made already - but I don’t want to take away the possibly for them to redo it if they like.

I just can’t get it to show a warning after scanning that the entry has already been found with (qr id) in the completed forms tabs.

Did you try a column of type Show?

Could you provide me an example? because everything I try gives me Y/N if the field has been filed but never referenced the inspections sheet.

What have you tried? Screenshots?

That does not appear to be a Show column, as I suggested.

I honestly can’t figure out the ‘Show_If’ expression to use so I decided on that other route that led to no success.

In the Show? expression for the Show column, put the inverse expression you’d otherwise use as the Valid If expression for the column you’re validating. The expression should produce TRUE if the column value is invalid. You’ll need to adjust the expression slightly so it doesn’t use [_THIS]:

In([Scan QR], SELECT(Inspections[Shortcode], [shortcode] <> [_ThisRow].[shortcode]))

Note that I removed the enclosing NOT() so that the expression produces TRUE if the scanned code is a duplicate.

Then, in the Show column’s Content expression, simply put whatever text you want displayed when a duplicate code is scanned:

"Duplicate value!"

image

I don’t know what I am doing wrong here.

I have entered that expression in different ways for the last hour and I can’t get it to work.

Fleet Table * where all the ref information lives
Inspections Table - Where form inputs go.