connecting to mysql
I'm new to both the Netbeans IDE and the gcc compiler and this is the
first time I've taken on a challenge bigger than a homework problem.
I'm reading the book by Dubois and working with his sampdb database.
I created a new C++ project, mysqla, and
I added Dubois's program /sampdb/capi/connect1.c to it.
There were a lot of "can't find header error" so I edited the project's properties
and directed the gcc compiler to /usr/include/mysql and that worked.
But the project still would not compile, get 7 or 8 errors like this one:
/home/rjs/CppProjects/MySQLa/connect1.c:23: undefined reference to
`mysql_server_init'.
`mysql_server_init' and all the other undefined references are names of function declared in /usr/include/mysql/mysql.h, which is properly included in connect1.c.
What am I missing? Thanks and many kind regards - Randy
Subject
Views
Written By
Posted
connecting to mysql
1521
July 06, 2012 02:31PM
671
July 17, 2012 10:44AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.