I have a database which was created by my CMS installation named BlogDB and another database (named dbemp) which I am currently using for my website. My host allows me to use only one database. So, I wanted to create the schema from BlogDB to dbemp. Can this be done?
Also, I do not want to delete the schema from my original DB, neither overwrite it and it must continue working as it is. Just the new new tables etc. have to be added.
You can automagically create tables with a similar structure by using
CREATE TABLE db2.DESTINATION SELECT * FROM db1.SOURCE;
This creates the same structure, but with certain problems. It will not take over indexes, so you need to recreate all constraints in the destination tables again.