MySQL Forums
Forum List  »  Connector/C++

Re: (Language C++) Variables in mysql_query???
Posted by: William Visnich
Date: April 02, 2008 08:34AM

You need to provide a C string for the second argument:

if (!mysql_query(&db_conn, create_table3.c_str() ) == 0)
{
fprintf(stderr, "Could not create the table. Error %s\n", mysql_error(&db_conn));
}

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: (Language C++) Variables in mysql_query???
5112
April 02, 2008 08:34AM


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.