All,
I am trying to connect to the database and write the enteries of a field in a file but when trying to bind to the database I am getting the following error.
/tmp/ccgppbh8.o(.text+0x28): In function `main': : undefined reference to `bind_dbmod'
The code is written within the PA module
#include <stdio.h> #include <stdlib.h> #include "../../db/db.h"
#define DB_URL "mysql://user:pass@127.0.0.1:3306/dbname"
int main() {
FILE *fp; db_con_t* h; db_res_t* res; db_func_t* dbf;
if (bind_dbmod(DB_URL, dbf)) { printf("Error while binding database module, did you forget to load a database module ?\n"); return -1; }
Please let me know. Any help will be highly appreciated.
Thanks, Salony
"...Live a good, honorable life. Then, when you get older and think back, you'll be able to enjoy it a second time."