May 2005
Intermediate to advanced
352 pages
14h 39m
English
mysql_select_db( )
int mysql_select_db(MYSQL *mysql, const char *database)
Use this to select a different database for the current connection. The name of the new database to use is given as the second argument of the function. It returns 0 if successful, nonzero if unsuccessful.
... mysql = mysql_init(NULL); mysql_connect(mysql,"localhost","hui","shorty"); mysql_select_db(mysql,"workrequests"); ...
Read now
Unlock full access