MySQL, mingw, and C++.

Hi all,

I am trying to run Mingw 3.4.5 (vista special r3, this is the output I get when
I type: g++ --version), with MySQL 5.0.

Read all the documentation. C++ compiler is working fine, MySQL is working.

I followed all the steps here as suggested by guestgulkan,

http://www.cplusplus.com/forum/windows/5259

The problem is when I try to run the resetdb.exe, simple1.exe programs as described in the read-mingw file in mysql++, I get:

Connecting to 'USERNAME@localhost', without password...
Connection failed: Access denied for user 'ODBC'@'localhost' (using password: NO)

I have set PATH variables for:

C:\Program Files\Bakefile;

C:\Program Files\MySQL\MySQL Server 5.0\include;

C:\Program Files\MySQL\MySQL Server 5.0\lib;

C:\MinGW\bin;C:\mysql++-3.0.9;

C:\MySQL++\lib;

C:\MySQL++\include;

C:\windows\system32\mysqlpp.dll


I created an MySQL ODBC 3.51 Driver connection using: user = root, password = myPw and so on and tested it and it works also.


Could be some missing PATH for logging into the MySQL server.

Thing is I can't find the source code for the resetdb or simple1 exe's. If the source code for these was available, I might be able to tinker with it.

Is ODBC connector even needed?

Should there be a ; here or none C:\windows\system32\mysqlpp.dll

(this is the last PATH variable)

It's been a while since using PATH variables and ODBC.
Any help would be very much appreciated.





Woot, I got it working, the problem was that I forgot to do exrun.bat resetdb -u user - p pw and pass in my info. Yes, I know... :)

I would still like to see the code for resetdb and simple1 if possible. Tried to open the .O file and .O.D but no joy.
Ok so i got to see the code of the resetdb and other files.

I tried to compile the code from this thread:

http://www.cplusplus.com/forum/windows/5259

It won't work for me either, errors:

cmdline.h: No such file or directory.
printdata.h: No such file or directory.
mysql++: No such file or directory.

All settings and PATH vars are as above in original post. I am obviously doing something wrong.

The resetdb and simple1 examples are working np. Just can't get my own connection working.

Soz for posting 3 times, unnecessary I know.

Using mingw, mysql 5.0, and mysql++ api. Not using Dev-CPP.
Topic archived. No new replies allowed.