Forums

In case of double entry message

Fredolino 25 Feb, 2020
Hi,
I have a repeater area with a dropdown in the form.I don't want me to save a selection from the dropdown box twice in the database when I save the form.A message should be displayed.
The form structure is on the screen.I have a loop for the repeater with a SaveData44 and a switch (check_species_duplicate) for the message.
If I have not selected "Species" twice in the repeater in the dropdown box, the entries are saved by the repeater and a success message (message33) is displayed.
The error message from the switch is also displayed, which is wrong.

If I accidentally double-selected a "species" in the dropdown box, I get a system error message that I have to intercept with a message:
1062 Duplicate entry '475-1527-o. A.-Imago 'for key' FundArtGeschlechtStadiumIdx '
This message is correct because I have e.g. B. 2 double entries.And also only one entry is saved in the database and not two entries.

How can I correctly display the messages in the form?

Thanx for help
F.

This topic is locked and no more replies can be posted.