Solved

AP MySQL [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

Posted on 2004-10-25
430 Views
Last Modified: 2013-12-03
hi, I am getting
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
 error, while tring to connect MySQL from asp.
This is the code I am using
Set oConn = Server.CreateObject("ADODB.Connection")
stroConn = "Driver={mySQL};Server=localhost;Port=3306;Option=131072;Stmt=;Database=mydb;Uid=root;Pwd="
oConn.Open stroConn
Thanks in advance
- Kani
0
Question by:str_kani
    4 Comments
     
    LVL 8

    Accepted Solution

    by:
    Try this:

    stroConn = "Driver={MySQL ODBC 3.51 Driver};Server=localhost;Port=3306;Database=mydb"
    0
     
    LVL 12

    Author Comment

    by:str_kani
    Thanks mate. It's ok now. Could you please tell me what was wrong there?

    Thanks a lot
    0
     
    LVL 8

    Expert Comment

    by:hendridm
    Sure thing, the "Driver=" setting must match an actually name of a driver on your system.  To see a list of drivers, go to 'Administrative Tools' then 'Data Sources (ODBC)' then 'Drivers' tab.  The latest MyODBC driver from mysql.com installs itself as "MySQL ODBC 3.51 Driver".  Simple putting "Driver={mysql}" did not work because you apparently don't have a driver installed named 'mysql'.

    Cheers,
    Daniel
    0
     

    Expert Comment

    by:helpdeskmckinstry
    This is years later but this solved my problem. Fantastic!
    0

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Find Ransomware Secrets With All-Source Analysis

    Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

    I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:  The Exchange of information …
    Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
    Want to pick and choose which updates you receive? Feel free to check out this quick video on how to manage your email notifications.
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    884 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

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now