Christine Stringfield
Posts: 0
Joined: Wed Apr 03, 2013 4:35 am

Prevent Duplicate Entries

Is there a way to prevent duplicate entries in a collection?

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Prevent Duplicate Entries

Yes, it would need to be implemented in your app logic. For example, you could check if such record already exists in the database.

Christine Stringfield
Posts: 0
Joined: Wed Apr 03, 2013 4:35 am

Prevent Duplicate Entries

I thought that I might be able to invoke a query service and then if the query results were empty, then I could invoke a create service.

However, even if the query results are empty, the query is successful, so I cannot then conditionally invoke a create service if the query errors. Any other suggestions?

Christine Stringfield
Posts: 0
Joined: Wed Apr 03, 2013 4:35 am

Prevent Duplicate Entries

I was able to accomplish what I needed by using some custom JavaScript and calling the create service in my JavaScript. :)

Return to “Issues”