Hi all, I am building client program on MySQL 4.0.16 with C API. But I always get error like:
make all-recursive gcc -I. -I/usr/home/vpopmail/include -I/usr/local/include/mysql -g -O2 -c user.c user.c: In function `delalert': user.c:357: syntax error before `*' user.c:358: `conn' undeclared (first use in this function) user.c:358: (Each undeclared identifier is reported only once user.c:358: for each function it appears in.) user.c:360: syntax error before `*' user.c:365: `res_set' undeclared (first use in this function) user.c:366: syntax error before `unsigned' user.c:367: `numrows' undeclared (first use in this function) user.c:372: `row' undeclared (first use in this function) user.c:382: syntax error before `char' user.c:384: `token' undeclared (first use in this function) . Here is my piece of code: #include "/usr/local/include/mysql/mysql.h" . MYSQL *conn; conn = mysql_init(NULL); mysql_real_connect(conn,host,username,password,database,0,NULL,0); MYSQL_RES *res_set; MYSQL_ROW row; unsigned int i; sprintf(mysqlquery,"SELECT fromDomain,fromAddress FROM user WHERE userName=\'[EMAIL PROTECTED]'",Username,Domain); mysql_query(conn,mysqlquery); res_set = mysql_store_result(conn); . Can anyone tell me, how can I compile this code. BR, Baynaa.