Aadir Clave foranea mysql
1
ALTER TABLE `miTabla` ADD FOREIGN KEY (campodemiTabla) REFERENCES `otraTabla` (`Id`) ;
Important Ibis
1
ALTER TABLE `miTabla` ADD FOREIGN KEY (campodemiTabla) REFERENCES `otraTabla` (`Id`) ;