4 messages in com.mysql.lists.plusplusRe: closing connection to a database
FromSent OnAttachments
aldrin30 May 2004 12:36 
Sinisa Milivojevic01 Jun 2004 03:15 
aldrin02 Jun 2004 10:50 
Sinisa Milivojevic03 Jun 2004 03:12 
Subject:Re: closing connection to a database
From:Sinisa Milivojevic (sin@mysql.com)
Date:06/03/2004 03:12:31 AM
List:com.mysql.lists.plusplus

aldrin wrote:

I tried using query << sCommand.c_str(); only, but it doesn't work....and if I'll go with query.execute(); only, then it won't work coz there's no command that would be queried....

do I need to use query.update(x,x2); query.execute(); instead of doing query << sCommand.c_str(); query.execute(); ?

Thanks! -aldrin

Please read the manual.

Things are much simpler.

If you want to run query that returns a result set, you just do:

query << "SELECT ..."

or if it does not return result set:

query.execute("UPDATE...");

Sincerely,