Im using the sails-couchdb-orm (cloudant is the final destination for the DB but in this scenario I am using a local couchdb install) - everything is working all right but I can't seem to get the unique property to work....
module.exports ={
migrate: 'drop',
attributes: {
email: {
type: 'email',
required: true,
unique: true
},
....
I'm able to create duplicate entries
I've tried the fixes from the mysql question and the generic "Unique property fails in Sails.js"
To check the schema etc I switched to the sails-mongo module and it worked as intended
E11000 Duplicate key error
EDIT
Im not sure if this is an edit or a comment....So it looks like this is something that's more related to couchdb than the sails-couchdb-orm module ... sorry am new to CouchDB and only recently introduced to it as company has relationship with cloudant and it looks like to get it to work I'll need more couchdb knowledge as I don't yet understand all of the 'lingo' for the workarounds in this question...Unique constraints in couchdb