Good morning!
I have 2 tables that are stored on different databases - different mySQL hostnames.
How to I join them?
Is there a way to open a connection to a database, being connected to another, using commands at the MYSQL Workbench GUI interface (not command prompt) and then query it?
Many thanks,
Related
I have three servers. I want to copy MySQL database data from 2 servers to third server.
All servers have some or the other data in MySQL server instance running on them.
I didnt have spacy left on the servers so rather than doing mysqldump i just copied database folders i.e. /var/lib/mysql/dbname
Now its showing me names of databases and tables in server where I aggregated all this data (for commands like show databases, show tables) but when I access tables its giving me "Table doesn't exist error"
I am guessing it has something to do with not handling ibdata files in /var/lib/mysql . Given my case what can be done to merge them properly
These two threads effectively solve your issue:
If you have the consistent schemas for the three: How to merge two MySQL databases of same structure
If you don't have the same schema: How to merge two mySQL database into one?
For my current environment, I am running 2 separate Linux boxes each running MySQL. Each server should have the exact same db (one of the servers should host the db and the other one points to it). I know this could be possible using "federated tables" but the application that the database supports has hundreds of tables. It would be very recursive to point each table to the other db.
Does anyone have any suggestions how this could be possible? I have looked all over and have not found anything quite like this scenario.
I have many db's from customers and many own db's, all of them in mysql and I'd like to have different mysql connections (Customers, Own).
My trouble is I can't. When I create a second mysql connection, is taking all db I got in my localhost.
Any advice?
Thanks
I haven't tried Navicat but I have been using SQLyog, where you can have separate connection for each database.
In SQLYog while creating new connection it ask me for database also, along with other details such as username,password etc.
Please tell me how to connect to mysql database server from another mysql database server running in two different locations and access all the tables and update them ?
afaik there is no direct "database link" in mysql like there is in oracle. what you can do is master-master replication of two databases and then update locally. similar question with more info:
Oracle Database Link - MySQL Equivalent?
You could pop a MySQL Proxy client between the two servers and send your queries to it and let it do all the talking backwards and forwards between the other boxes.
Just created a database in my own MySQL server. Now I want to transfer the data from my MySQL server to one of my friend's MySQL server.
Any idea how this can be done?
Also, how would I do this if I use oracle server?
If you have an access to his database - you can create dblink
Otherwise you have to export a dump and send it to your friend.
I have had to copy full databases (as well as just selected tables) between servers before and a SQL dump can be cumbersome if you have a lot of data. If you have access to both servers you might consider an application called "Navicat". It is a MySQL GUI interface to manage databases.
You can have multiple databases on separate servers open at the same time, and can even "drag and drop" tables between databases and databases between servers.