MySQL :o(

Hi, I'm trying to connect to my mySQL server through, but no matter what I do, I keep getting the same error:

ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
I've tried installing everything over and over again, and I've used alle kinds of tutorials. But nothing is working.
Here's the code I using on my page:
<%@ Page Language="c#" ContentType="text/html" ResponseEncoding="iso-8859-1" %>
<%@ Import namespace = "System.Data"%>
<%@ Import namespace = "System.Data.Odbc"%>
<script language="C#" runat="server">
protected void Page_Load(Object sender, EventArgs e)
string mySQLConnStr = "driver={MySQL};";
mySQLConnStr = mySQLConnStr + "server=localhost;";
mySQLConnStr = mySQLConnStr + "uid=root;";
mySQLConnStr = mySQLConnStr + "pwd=;";
mySQLConnStr = mySQLConnStr + "database=mysql;";
mySQLConnStr = mySQLConnStr + "OPTION=17923";

OdbcConnection myConnection = new OdbcConnection
string SQL = "select * from user";
OdbcDataAdapter myCommand = new OdbcDataAdapter(SQL,
DataSet ds = new DataSet();
myCommand.Fill(ds, "user");
<h3><font face="Verdana">Please Help Me!!</font></h3>
<ASP:DataGrid id="MyDataGrid" runat="server"
5/31/2003 3:28:30 PM 1929 articles. 0 followers. Follow

9 Replies

Similar Articles

[PageSpeed] 45

MAKE ABSOLUTELY CERTAIN your "Driver={}" string is CORRECT.

To check go to:
Control Panel > Admin Tools > Data Sources (ODBC) > [Tab] Drivers
Scroll down until you see the MySQL driver, and see what the NAME is. Use that EXACT name in your string.
If you can't find it, your page won't work, you need to install the MyODBC drivers...if you're using MyODBC 3.51 your string should look like:

DRIVER={MySQL ODBC 3.51 Driver}

If it's localhost, don't bother adding the "server=" automatically assumes that. And what is the "option" for? Don't use it unless you need it
:) Hope that helped.
Kamran A

Web Developer

ASP / .NET / JavaScript / CSS / XHTML

6/1/2003 2:40:39 PM
Thank you, It really helped me a bundle!!
6/2/2003 12:04:35 PM
Another option is to get the CoreLab.MySql.dll from Core Labs ...

1. Install the driver
2. Add it to Web Matrix
3. Create a "bin" directory in you web folder
6/30/2003 7:00:59 PM
i am having trouble getting the namespace.

any idea why? i am able to connect to MySQL via ASP and now i am trying to access the database via ASP.NET.
i've tried downloading and installing the MDAC but to no avail.
appreciate any kind of help. thank you in advance.
8/7/2003 4:45:02 PM
Hi Shaheed,

The ODBC provider is not part of MDAC, which is COM-based ADO.
You can get the provider here.
Don Kiely, MCP, MCSD
In the Last Frontier, Interior Alaska
Please post questions and replies to the forum! And remember to MARK AS ANSWER when someone definitively answers a question or resolves a problem!
8/7/2003 5:48:32 PM
i downloaded the provider and install it. but i m still not getting the name space

can u please help?
8/11/2003 3:43:46 AM
Okay, how do you know you're not getting the namespace? What development tools are you using? What code are you trying to write?

Don Kiely, MCP, MCSD
In the Last Frontier, Interior Alaska
Please post questions and replies to the forum! And remember to MARK AS ANSWER when someone definitively answers a question or resolves a problem!
8/11/2003 4:57:33 AM
You need to reference the Microsoft.ODBC.Data namespace just like the other namespace references.  Even if the DLL's have been added to the gac, you have to do this reference.  I keep forgetting myself.

8/12/2003 12:28:49 PM
ok igot it .

8/18/2003 2:50:21 AM

Similar Artilces:

Currently have a site coded in PHP but the customer wants to go to .NET. Can I use the existing MySQL DB or am I required to use MSSQL? Thanks, Ken Check out this forum which is specialized for this kind of questions: ASP.NET MySQL forumBart De Smet [MVP] Visit,

mysql php5-mysql
Hi, i have installed mysqk from binaries itworks!!! but now how can i install php5-mysql and dependencies? Many thanks Thierry -- trazomtg ------------------------------------------------------------------------ When you say from the binaries, do you mean you installed via Yast and the Suse repositories?? It is always best to install via Yast-Software-Software Management if you can. This way all dependencies are done for you. -- gogalthorp ------------------------------------------------------------------------ gogalthorp's Profile: http://forums.opensuse....

mysql and .net
Hi there, i am new to .net and i am trying to setup a simple form. I am an open source person and what i am asking can be done easily using php and mysql; but i need to know how to do this in .net project asap. i have three forms; form1 submit to the database and redirect to form2 and form2 submit to the database and redirect to form3. i want to grab mysql last inserted id from form1 to form2 while redirecting and pass it via the url. i am able to select from the database, but i don't know how to assign it to a variable; here is what i have so far: str2 = "select last_ins...

linked server MySql to Mysql
Can i make linked server from MySql to another Mysql server?...

------=_NextPart_000_0026_01C30A6E.486AE070 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Anyone run into this problem=20 $mysql->query(q{ INSERT INTO dbname (table_name) VALUES ( $var ) }); The problem is, when I assign a value to a $var that value is ignored in = the SQL statement. Ive tried every operator I know to get it to look at = it and accept the value as input into the DB. Ive tried=20 ( '$var' ) ("$var") ("\$var") ([$var]) ({$var}) Any ideas ? Kind regards...

Suse MySQL and MySQL workbench
I am looking at the downloads here 'MySQL :: Download MySQL Workbench' ( and 'MySQL :: Download MySQL Community Server' ( As one is source code and the other is suse enterprise linux, are these the best downloads for MySQL on suse 11.3? Is there a best source for the install? Suse specific rpm's? -- flebber ------------------------------------------------------------------------ Try zypper or YAST first to look at the OpenSuSE repositories. If those aren't "latest" enough for you, consider looking at the OpenSuSE Build Service. By installing using a package manager like YAST/zypper, your system can automatically maintain and update your app. Tony -- tsu2 ------------------------------------------------------------------------ tsu2's Profile: View this thread: > are these the best downloads for MySQL on suse 11.3? No. Use yast to install the package and it will come from the official openSUSE OSS repo. The openSUSE package contains a lot of patches to fix some issues and integrate it nicely with your 11.3 OS. Anything else is not recommended unless you know exactly what you are doing, but then you wouldn't have asked ... -- Technology is 'stuff that doesn�t w...

Perl Mysql
Hi all, I am installing Bugzilla3 on a windowsXP box together with Mysql5.0.45 and ActivePerl- It passed the checksetup and created the database. However, when I point my Firefox to http://localhost/ I got the following error: install_driver(mysql) failed: Can't load 'C:/Perl/site/lib/auto/DBD/mysql/mysql.dll' for module DBD::mysql: load_file:The specified module could not be found at C:/Perl/lib/ line 230. at (eval 34) line 3 Compilation failed in require at (eval 34) line 3. Perhaps a required shared library or dll isn't installed...

DBD::mysql bad auto/DBD/mysql/mysql.bundle file on OS X
Howdy group :) Having a bit of trouble getting DBD::mysql installed on OS X I get this error: root# perl -e 'use DBD::mysql;' Can't load '/Library/Perl/5.8.1/darwin-thread-multi-2level/auto/DBD/mysql/mysql.bundle' for module DBD::mysql: /Library/Perl/5.8.1/darwin-thread-multi-2level/auto/DBD/mysql/mysql.bundle(2): Not a recognisable object file at -e line 1 Compilation failed in require at -e line 1. BEGIN failed--compilation aborted at -e line 1. root# Here is what is in the directory: root# ls /Library/Perl/5.8.1/darwin-thread-multi-2level/au...

Hi Guys I've been thinking (bad move for this time of day) would it be possible to run DNN from a win2K server then connect to MySQL running on a RaQ2 server? If this were possible how would you go about setting this up? reason for asking is I have a RaQ2 and rather than thinking about MSSQL licensing thought this might be a better option. Any thoughts? Pat MySQL is MySQL regardless of the host. Just create your DB on your Sun box and alter your DNN connection string to point at that box/port/DB... Have fun...~ChrisNet Data Hello, Yes that is possia...

------=_NextPart_000_0007_01C0BDBA.E56BFC40 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello All I down load MySQL I installed it but I can not bring it up on my = computer. What did I do wrong. Paul ------=_NextPart_000_0007_01C0BDBA.E56BFC40-- Did you install the MySQL-client rpm (if you installed through an RPM)? If you did not install MySQL through an RPM, are you trying the absolute location of the mysql binary (i.e. /usr/local/bin/mysql). If I am not mistaken, I think (unless you specified otherwise) th...

Is it possible to view a MySQL Service running on my computer with Visualr Studio.NET as it does with MSDE(Microsoft SQL Desktop Engine)?...

Anyone using PB with MySQL as their database? Just about everything is going fine except the current ODBC driver doesn't support cursors which we're having some difficulty getting around for one function of our program. Terrill ...

Hi, Well, I'm about to take the plunge and begin to learn MySQL. I have Apache and Perl all running great (stock installs), but I'm not sure how to get started with installing MySQL. I guess what I'm asking is, can some one share some good links/pointers on installing MySQL. As well, links on USING MySQL with Perl. I'm not planning on doing any huge things with multiple databases, just some basic info to be stored and then searched through when needed. I could do what I need in a flat file DB, but want to learn how to use MySQL. Any pointers anyone could ...

Hello, i have MYSQL running on the OES-Linux server. Now i know thwere i an config file i have to edit before i can manage the MYSQl from another host. does anyone know where i can find that file ??? if i now trey to log in from another server the MYSQL cluietn say: Host is not allowed to connect to this MYSQL server Hope someone knows the fix. Thanx Dave I don't know that much if there is something special with MySQL on SuSE/OES, but in an ordinary MySQL installation, this is restricted in the mysql database itself, user table and Host column. Creat...

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib service mysql start Starting service MySQL warning: /var/lib/mysql/mysql.sock didn't appear within 3 need help thanks -- ansonelliott ------------------------------------------------------------------------ Have you ensured both mysqld and apache are running? YaST > System > System services (if I remember correctly) allows you to set both to start automatically on boot. -- john_hudson -----------------------------------------------------------------------...

Hi it is possible to connect to MySQL using PB ? I dont want use ODBC. Milos PB only supports ODBC to connect to MySQL. Sorry. "sula" <> wrote in message news:4002631b@forums-1-dub... > Hi > it is possible to connect to MySQL using PB ? I dont want use ODBC. > > Milos > > Does MySQL support JDBC or OLE? Those would be the only other options. -- Terry Dykstra (TeamSybase) product enhancement requests:

My mail got all deleted by accident can someone please tell me the site that had info on Databases (mysql) and accesing them from perl. RYan On 04 Jul 2001 01:45:23 -0400, Ryan Gralinski wrote: > My mail got all deleted by accident can someone please tell me the site > that had info on Databases (mysql) and accesing them from perl. > > RYan > > > Luckily for you there is an archive of the list on the web: -- Today is Prickle-Prickle, the 38th day of Confusion in the YOLD 3167 P'tang! ...

Greetings, I'm a webserver newbie, my experience to date has been strictly pc support and network administration. We're in the process of exploring Apache (currently running Netware 6 and NCS) as a replacement for our aging IIS server. I've been asked if MySQL is available. I'm pretty sure it is as I've seen posts related to it but I've got no idea where to get it or what to do once I have it. Can anyone point me in the right direction, especially where training/manuals/getting started advice is concerned? Thanks, Travis -- Travis Montgomer...

Anybody has comparative review of mysql on OES with MS SQL on Windows? thanks. wrote: > Anybody has comparative review of mysql on OES with MS SQL on Windows? thanks. Just google for mysql "sql server" comparison and you'll get a ton. The jist of them all pretty much is: MySQL works great, but still lacks some business features like true transactions and low-level locking. It's getting better tho. You might want to look into PostGreSQL for any real demanding applications, but if you're just doing a small database (unde...

I have PowerDesigner 6.1.3 and need to generate a script for MySQL. Does anyone know where I can get the def file for MySQL 3.23.36? Thanks! I'm pretty confident that you would be much better off evaluating the latest version (9.5), which includes a book full of new features and functionality. I know you are probably quite happy with 6.1.3, but that version isn't being supported anymore. -- Michael F. Nicewarner [TeamSybase] <TomJoyal> wrote in message news:599EB5D529577B850081808A85256C30.008180...

Please, Mobilink support the SGBD MySQL ??? thanks MySQL is not an officially supported (nor tested) consolidated database. The issue is that the ODBC drivers available for MySQL do not support the level of ODBC functionality or aren't stable enough for ML's needs. Some people have reported different levels of success using MySQL as a consolidated either directly using different ODBC drivers or by using ASA as the consolidated and proxy tables to the MySQL backend. -- Liam Cavanagh Certified ASA Developer Version 8 iAnywhere Solutions - Sybase Product Managem...

Are there any plans in the future to add MySQL as a supported DB for ZCM 10? Nick, nothing published AFAIK -- Shaun Pond Any idea why since products like IDM support MySQL and it comes with SLES? I just can't get over Novell still uses Sybase and MSSQL well you know its MS :) "Shaun Pond" <> wrote in message > Nick, > > nothing published AFAIK > > -- > > Shaun Pond > > If I remember correctly, someone at Brainshare 2007 told me that there i...

Hi, Recently installed opensuse. I would like to install a new version of MySQL - and not use the one that comes installed through Yast by clicking. How do i "shut-off" or remove completely all MySQL references / processes / files - so that i know my install is not being effected by any original MySQL install. Its hard to know what parts are my install and what parts are the old install. Thanks for any help. Regards, Sam -- samwootton ------------------------------------------------------------------------ This is not recommended because the ve...

Ok, I made a table in phpMyAdmin and now I want to add stuff into it from my perl script, but for some reason nothing is added. Code Sample: #!/usr/bin/perl print "Content-type: text/html\n\n"; use DBI; $dbh = DBI->connect("DBI:mysql:database='homewebewebin';host='localhost'", "usernametakenout","passwordtakenout", {'RaiseError' => 1}); $query = "INSERT INTO browse (username, password) VALUES ('Kittyf', '5521f') LIMIT 0, 30 "; $sth = $dbh->prepare($query); $sth->execute(); ...

Web resources about - MySQL :o( -

MySQL :: The world's most popular open source database
“MySQL's reliability and speed have helped us develop software that maximizes the availability and performance of enterprise telephony networks, ...

MySQL :: Il database open source più diffuso al mondo
Skip navigation links Il database open source più diffuso al mondo Contatta un rappresentante MySQL Login - Registrazione Download (GA) ...

MySQL Performance Blog
Percona's blog about MySQL performance optimization and scalability, InnoDB, XtraDB, and XtraBackup

MySQL - Wikipedia, the free encyclopedia
5.5.27 / August 2, 2012 ; 29 days ago ( 2012-08-02 ) The MySQL development project has made its source code available under the terms of the ...

It is that time of the year, again: Percona Live is the name of this years MySQL conference in the Santa Clara Hyatt Regency. is ...

MySQL Consulting and NoSQL Consulting: MySQL DBA
... to the problem that doesn't include companies having to buy new software tools or even an all-new database: With the right expertise, MySQL ...

MySQL Bugs
Portions of this website are copyright © 2001, 2002 The PHP Group Page generated in 0.013 sec. using MySQL 5.5.16-enterprise-commercial-advanced-log ...

MySQL :: Developer Zone
"The Documents contained within this site may include statements about Oracle's product development plans. Many factors can materially affect ...

MySQL Forge :: Dashboard
© 1995-2008 MySQL AB, 2008-2010 Sun Microsystems, Inc., 2012, Oracle Corporation and/or its affiliates. Content reproduced on this site is the ...

Facebook, Google, LinkedIn, Twitter Team Up On WebScaleSQL To Tackle MySQL Challenges
Facebook, Google , LinkedIn , and Twitter face similar challenges in working with open-source database MySQL , and Thursday, the four companies ...

Resources last updated: 3/7/2016 1:18:30 AM