Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#9 MySQL multi table deletions.

closed
nobody
None
5
2003-12-05
2003-06-17
Ryan Gregg
No

I've been developing a front end in C# using MyOLEDB,
but I kept running into annoying problems, for example
last_insert_id() would never work for whatever reason.
So I decided to give MySQLDriverCS a try. Everything’s
going great and everything seems to be working with
minimal alterations (ExectureScalarQuery() isn’t
implemented?) except I can't seem to get multi table
deletions to work, here’s a sample:

string sSQL = "delete from table1, table2, using table1
as t1, table2 as t2 where t1.id = t2.id and t1.id = 1";

MySQLCommand Command = new MySQLCommand
(sSQL, Connection);
Command.ExecuteNonQuery();

ExecuteNonQuery returns 0 and no tables have been
removed when they should be...

Discussion

  • Logged In: YES
    user_id=406263

    Well that kind of things are sent directly to the MySQL native
    client, if it doesn't make the job then MySQL native driver
    cannot do this job. Try simpler queries.

     
    • status: open --> closed