Is this by design - compare CHAR BINARY with CHAR

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jens Schreiber

    Is this by design - compare CHAR BINARY with CHAR

    Helo,

    I'm using 4.1.8-standard on linux and get this:

    CREATE TABLE test (field1 CHAR(20) BINARY NOT NULL, field2 CHAR(20)
    NOT NULL) TYPE=MyISAM;
    INSERT INTO test VALUES('xxx','y yy')
    SELECT * FROM test WHERE field1=field2

    ERROR 1267 (HY000): Illegal mix of collations (latin1_bin,IMP LICIT)
    and (latin1_swedish _ci,IMPLICIT) for operation '='

    Thanks
    Jens
Working...