Hello I am trying to compile a simple program that connects to a running mySql server database.
Problem is that the err
C:\Documents and Settings\Durango\code\C\mySqlTest.c:3: mysql.h: No such file or directory
C:\Documents and Settings\Durango\code\C\mySqlTest.c:5: error: `MYSQL' does not name a type
C:\Documents and Settings\Durango\code\C\mySqlTest.c:: In function `int main()':
C:\Documents and Settings\Durango\code\C\mySqlTest.c:10: error: `mysql' undeclared (first use this function)
C:\Documents and Settings\Durango\code\C\mySqlTest.c:10: error: (Each undeclared identifier is reported only once for each function it appears in.)
C:\Documents and Settings\Durango\code\C\mySqlTest.c:10: error: `mysql_init' undeclared (first use this function)
:: === Build finished: 5 errors, 0 warnings ===
In my Global compiler settings section, in the "linker settings" tab I have added the required libraries for compiling the code.
E:\MySQL\MySQL Server 5.0\lib\opt\libmysql.lib
E:\MySQL\MySQL Server 5.0\lib\opt\mysqlclient.lib
E:\MySQL\MySQL Server 5.0\lib\opt\mysys-nt.lib
Under the "Search Directories" -> "linker" tab I have added
E:\MySQL\MySQL Server 5.0\lib\opt
Here is the code (I have minimized it to practically nothing):
#include <stdlib.h>
#include <stdio.h>
#include <mysql.h>
MYSQL mysql;
int main(void)
{
mysql_init(&mysql);
return 0;
}
Any help would be appreciated.
