28.4.2 Executing SQL Statements
- Use mysql_query to issue commands (even updates)
- Assemble command in a string object
- Then use c_str:
string new_value = ...;
string query = "INSERT INTO Test VALUES ('" + new_value + "')";
mysql_query(query.c_str());
prev
|top
|next