i am using two database adapters with sails.
one for mondoDB and second for mysql.whenever i run command \"sails lift\".once it gives an error
error
I realise this is quite an old question, but I also had the same problem. I was convinced it wasn't my connection.
My solution is to change your migration option for your models and you'll have a choice of 3
- safe - never auto-migrate my database(s). I will do it myself (by hand)
- alter - auto-migrate, but attempt to keep my existing data (experimental)
- drop - wipe/drop ALL my data and rebuild models every time I lift Sails
Got to config/models.js and in there put:
migrate: 'safe'
or whatever option from above you want to use.
It is likely best to do this on a per env basis. Under config directory, you will have something like:
Then enter, inside module.exports of each:
module.exports = {
hookTimeout: 40000
}
Notice, there is no need for an underscore in front of the attribute name either.