How do I create a unique index on a Collection to prevent duplicates, and a non unique index on a Collection to improve search performance?
How do I create a unique index on a Collection to prevent duplicates, and a non unique index on a Collection to improve search performance?
Every record has a unique id that's automatically generated -- you can use that. You can also create a new column and generate the number any way you want.
If I create an e-mail address column, and I want the column to be unique, how do I specify that?
Can I specify the value of the _id column, instead of using the value that is automatically generated?
You would need to enforce the email uniqueness on the app level. The _id is generated by the database.
MongoDB supports indexes - http://docs.mongodb.org/manual/indexes/. It would be nice if the Collections Maintenance UI allowed indexes to be defined and maintained.
Yes, it's a good feature to add.
Has this been implamented
All that Appery.io has appeared to support is Non-Unique Single Field indexes. How about Compound Indexes, and specifying Unique?
http://docs.mongodb.org/manual/core/i...
http://docs.mongodb.org/manual/core/i...
Hi David,
You would need to create a service for reading this data.
If there is no such record - add it.