List:MySQL++« Previous MessageNext Message »
From:Arlis Rose Date:June 30 2005 6:09pm
Subject: C++ query to backup table from database
View as plain text  
Hey guys, hopefully someone can help me out here.  Just started using mySQL
with C++ and I need to know how to do a more advanced query.  Okay so far I
can query to get data out of the database:
querry.Format("SELECT FromUser, Subject, Body, Unread, DataID from
and I can put data in the database as well:
querry.Format("INSERT INTO receivedemail (ToUser, Subject, FromUser, Body)
VALUES(\"%s\", \"%s\", \"%s\", \"%s\")", receive_from, receive_sub,
"aticket@stripped", MessageReceived);

Now what I want to be able to do is 2 things,

First: what query could I pass that would create a backup of the database
(database is myEMAIL and TABLE is receivedEmail) by date, so for example

Second: (this one I think I know already but don't hurt to ask :) to then
delete all entries from that database
(I'd assume it would just be:
querry.Format("DELETE * From receivedemail");

So is it possible to send a command (via a MYSQL query) that will backup my
Thanks a lot for all help.

C++ query to backup table from databaseArlis Rose30 Jun
  • Re: C++ query to backup table from databaseWarren Young1 Jul