After spending hours on this task, I'm still struggling to find a solution.
I have a mean stack application that caters to multiple clients, and I am looking to assign each client their own database. Is this possible?
For Example
var client_name = Client 1 or Client 2;
Backend
mongoose.connect('mongodb://localhost:27017/' + client_name, function(err){
if(err){
console.log("Connection failed " + err);
} else {
console.log("Connected successfully");
}
});