04-03-2008, 04:57 PM
|
#5 (permalink)
|
|
The Acquainted
Join Date: Nov 2007
Posts: 166
Thanks: 0
|
Quote:
Originally Posted by delayedinsanity
I tried yours serversphere and I got an error 1064 (42000) from MySQL. So I tried this, based off an example in the MySQL documentation at MySQL :: MySQL 5.0 Reference Manual :: 12.2.1 DELETE Syntax, but...
Code:
DELETE FROM contact, contact_additional USING contact, contact_additional WHERE contact.ticket=contact_additional.ticket AND contact.ticket=`mm1234.1234`;
and get...
Code:
ERROR 1054 (42S22): Unknown column 'mm1234.1234' in 'where clause'
|
You put backticks around mm1234.1234 so it thinks that is a column and not a string. I think you want something like this.
sql Code:
DELETE FROM contact, contact_additional USING contact, contact_additional WHERE contact.ticket = contact_additional.ticket AND contact.ticket = 'mm1234.1234';
That will delete where contact.ticket's value is mm1234.1234.
__________________
Eric
|
|
|
|