Re: How can I run '.sql' script from vc++

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Hi,
Somebody please help me how can i rum a .sql file from vc++. Iam using
MFC with MySQL as backend.

Use CreateProcess or ShellExecute to launch the following:

mysql my_db_name -umy_user_name -pmy_password my_script.sql

If you need to get access to the database instead of just running a script, a good place to start would be the C++ wrapper around the mysql C API, called MySQL++.

Find it here: http://tangentsoft.net/mysql++/

Eric
.



Relevant Pages

  • Re: pro- foreign key propaganda?
    ... I had built the DB backend using postgresql. ... reasons decided to switch to MySQL and created his own tables (as well as ... They'd also never leave foreign keys out of their designs, too, I guess. ...
    (comp.databases.theory)
  • Re: Non GUI DB System
    ... you can normally always use different front-ends as long as you have a connection to the backend. ... you could certainly implement the backend with mysql. ... As for a front-end, take your pick. ... Really, any type of programming front-end that has connection functions to databases would work, so it would really just be whatever you are most comfortable with. ...
    (comp.os.linux.misc)
  • Re: Zugriff auf ODBC-verknüpfte Tabelle in anderer MDB
    ... Von einem Access Frontend aus sollen nun per VBA Daten in diese ... mySQL Tabelle geschreiben werden. ... Das ganze klappt solange die Backend MDB auf dem gleichen Rechner ...
    (microsoft.public.de.access)
  • Re: Is PhP/mySQL right for this project?
    ... Handle request to logon from the frontend (requires backend to ... Implement chatroom and forum server services for use by the frontend ... Triggers and Views are only available in MySQL v 5.*. ...
    (comp.lang.php)
  • How can I run .sql script from vc++
    ... Iam using ... MFC with MySQL as backend. ...
    (microsoft.public.vc.language)