mysqlÖв»¼´ÊǵÄд·¨
mysql ²»µÈʽµÄд·¨ÓÐÁ½ÖÖ£º²»¼´ÊǺţ¨£©ºÍ²»¼´ÊÇÒªº¦´Ê£¨not equal to£©£¬Á½ÖÖд·¨µÄ¹¦Ð§Ïàͬ¡£¿ÉÒÔʹÓà ½ÏÁ¿Á½¸öÖµÊÇ·ñ²»¼´ÊÇ£¬È磺select from table_name where column_name value£»Ò²¿ÉÒÔʹÓà not equal to£¬È磺select from table_name where column_name not equal to value¡£
MySQL Öв»¼´ÊǵÄд·¨
MySQL Öв»¼´ÊÇÔËËã·ûÓÐÁ½ÖÖд·¨£º
²»¼´ÊǺţº
ÀýÈ磺
SELECT * FROM table_name WHERE column_name value;
²»¼´ÊÇÒªº¦´Ê£ºNOT EQUAL TO
ÀýÈ磺
SELECT * FROM table_name WHERE column_name NOT EQUAL TO value;
ÕâÁ½ÖÖд·¨¹¦Ð§Ïàͬ£¬¿ÉÒÔÓÃÓÚ½ÏÁ¿Á½¸öÖµÊÇ·ñ²»¼´ÊÇ¡£
ʾÀý
ÒÔÏÂÅÌÎʲéÕÒ table_name ±íÖÐ column_name ²»¼´ÊÇ value µÄËùÓмͼ£º
SELECT * FROM table_name WHERE column_name value;
µÇ¼ºó¸´ÖÆ
ÒÔÏÂÅÌÎʲéÕÒ table_name ±íÖÐ column_name ²»¼´ÊÇ value µÄËùÓмͼ£º
SELECT * FROM table_name WHERE column_name NOT EQUAL TO value;
µÇ¼ºó¸´ÖÆ
×¢ÖØ£º
ÓëÆäËû¹ØϵÊý¾Ý¿âÖÎÀíϵͳ£¨Èç Oracle£©²î±ð£¬MySQL ²»Ö§³Ö != ÔËËã·û¡£
ÒÔÉϾÍÊÇmysqlÖв»¼´ÊǵÄд·¨µÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡