I would like to know if it's possible in InnoDB in MySQL to have a table(db:3306 with password) with foreign key that references another table in a different port database(db:3307 with no password)? And if so, how this can be done ?
I have tried this one
ALTER TABLE `treat_well`.`tw_venue` ADD CONSTRAINT `FK_tw_venue_user_id` FOREIGN KEY (`user_id`)
REFERENCES `bitnami_dreamfactory`.`user` (`id`) ON DELETE CASCADE ON UPDATE CASCADE;
It throws error as follows
Error Code : 1215 Cannot add foreign key constraint
Advanced Thanks..