MySQL Lists are EOL. Please join:

List:MySQL++« Previous MessageNext Message »
From:John Heinig Date:June 7 2005 10:54pm
Subject:Query Problems
View as plain text  
All my select queries seem to work fine.  However, when I want to
write something to the database it doesn't actually write to the
database.  If I type in this at the command line or through the mysql
Query Browser, the command will actually write to the database.

Here are the snipits of my code that are in question here:

             1, 5,              // explained in the user manual
	int, id,
	string, source,
	int, owner, 
	string, name,
	string, announce,
	string, infohash,
	string, file_link,
	int, category,
	int, subcatagory,
	string, language,
	long int, size,
	mysqlpp::Date, added,
//	enum, type,
	string, type,
	int, numfiles,
	string, delete_reason,
	string, nuke_reason,
//	enum, deleted,
	string, deleted,
	int, strike,
	mysqlpp::Date, checked,
	int, downloaded

int main(int argc, char *argv[]) {

	int downloads=0;


	new_releases updatedRow = mainRows;
	new_releases origRow = mainRows;

	updatedRow.downloaded = downloads;
	cout << "Original Row: " << origRow.downloaded << " Updated Row: "
updatedRow.downloaded <<"\nMax Downloads: " << downloads << endl;
	//writeQuery.update(origRow, updatedRow);
	cout << "Write Query: " << writeQuery.preview() << endl<<flush;
	ResNSel a = writeQuery.execute();
	cout << a.success << " " << a.insert_id << " " << a.rows
<< " " << << endl;


return 0;


The output from this segment of code:

Original Row: 600 Updated Row: 6
Max Downloads: 6
Write Query: REPLACE INTO new_releases
1 33281 2
Query ProblemsJohn Heinig8 Jun
  • Re: Query ProblemsWarren Young8 Jun
Re: Query ProblemsWarren Young8 Jun
Re: Query ProblemsWarren Young8 Jun
Re: Query ProblemsWarren Young8 Jun