Can you prevent duplicate records. I have looked at distinct, but that only allows one column. And I would need two. Plus the examples are for retrieving information ?
Can you prevent duplicate records. I have looked at distinct, but that only allows one column. And I would need two. Plus the examples are for retrieving information ?
Hello!
Yes, distinct only allows one column. You can filter data in service results (on success service event) or do request through server code and filter data in server code.
Just seen a Webinar on Server Code. If I do anything on success, it will be to late, as I am creating a row, not collection from it. Just don't want the same two columns to be placed twice in the database.
Thanks though.
Then you need to use server code to implement this app logic.
An example please?
Hi Panagiotis,
Here is a brief plan:
On create item you should:
1.1. Query db collection on the same value.
1.2. If there is items (with same fields) - you return to user validation error.
1.3. If there is not items (with same fields) - you create an item and tell user "OK".
Regards.