Solved

Connect to SQL server using MySQL

Posted on 2007-12-06
7
727 Views
Last Modified: 2012-08-14
Hi,
 the company i work for has a SQL server to which i only have read access. Is there a way to connect to the sql server using mysql?
I was trying to use Toad for MySQL, but i dont even see a option to remotely connect to the SQL server.

Thanks in advance,

Mooks
0
Comment
Question by:mooklander
7 Comments
 
LVL 25

Expert Comment

by:imitchie
ID: 20423030
TOAD is for MySQL only.
Your best option is probably to download the free SQL Server 2005 Express Management Studio (free) which can connect to SQL Server.
0
 
LVL 25

Expert Comment

by:imitchie
ID: 20423032
0
 
LVL 8

Accepted Solution

by:
digital_thoughts earned 200 total points
ID: 20423071
Not sure about going from MySQL tools to SQL Server, but if you can request a linked server to be added, you could have your MySQL box added and then access data using the OPENQUERY method.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 

Author Comment

by:mooklander
ID: 20423143
thanks for the quick response experts. Is there no other alternative to do this with MYSQL. I had already created the database using sql server express, but was asked to try and recreate it in MYSQL.

Digital thoughts,
 Did you mean that i need the MySQL server connected as a linked server in the MS SQL server to achieve this?

thanks,
Mooks
0
 
LVL 25

Assisted Solution

by:imitchie
imitchie earned 200 total points
ID: 20423188
Assuming you have installed the MySQL connection drivers, then yes, you can link from MSSQL to MySQL.
If you still have the create script (and not much data), then it's probably easier to recreate it from the script.
0
 
LVL 2

Assisted Solution

by:stavrama
stavrama earned 100 total points
ID: 20426564
If you dont have installed sql server on your pc and assuming that you have access, you can do the following in order to export the tables to the new db on mysql.

First of all go and dl the odbc driver for mysql from this link:
http://dev.mysql.com/downloads/connector/odbc/3.51.html

You need to create 2 odbc connections. The first one will be in order to link the sql server tables from mssql to access and the 2nd will be in order to export the tables from access to mysql.

Go to administrative tools-> data sources(ODBC) and click add on the dbase files there. Choose sql server from the list and then click finish. On the new window that will appear, choose a name for your odbc driver and the server in which the sql db is. Click next and then next again. On the new window choose the database you want to use and then click next until it is finished.

The same thing you will do in order to create the odbc connection for mysql. Go again to data sources(ODBC) but this time choose mysql ODBC 3.51 Driver. On the new window fill  the following:

name: The name of the driver
server: Where mysql is
user: root
pass: password
database: the db in which you want to migrate the sql db.

Now open your access, click open file and choose the ODBC databases on file of type. On the new window, go to machine data source and from there choose the odbc driver we created for the access.
Choose the number of tables you want to link and click ok.

Now, left click to a table and choose export. On the new window choose again odbc databases to save as type and then specify the name of the new table that will be exported on your mysql db. Choose again after that the machine data source and this time pick the odbc driver for mysql. Do that for every table and your new db will be ready. I hope that this will help
0
 

Author Closing Comment

by:mooklander
ID: 31413251
was unable to try and implement this because of changes to the project. Just wanted to thank you experts for taking your time out for this.
cheers!
Mooks
0

Featured Post

Guide to Performance: Optimization & Monitoring

Nowadays, monitoring is a mixture of tools, systems, and codes—making it a very complex process. And with this complexity, comes variables for failure. Get DZone’s new Guide to Performance to learn how to proactively find these variables and solve them before a disruption occurs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL 2012 AOG and SQL2014 AOG 76 61
sql server cross db update 2 21
SQL Distinct Question 3 15
Need to find substring in SQL 3 13
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
This article shows the steps required to install WordPress on Azure. Web Apps, Mobile Apps, API Apps, or Functions, in Azure all these run in an App Service plan. WordPress is no exception and requires an App Service Plan and Database to install
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Viewers will learn how the fundamental information of how to create a table.

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question