CHECK constraint in MySQL is not working

后端 未结 8 2048
Happy的楠姐
Happy的楠姐 2020-11-21 05:15

First I created a table like

CREATE TABLE Customer (
  SD integer CHECK (SD > 0),
  Last_Name varchar (30),
  First_Name varchar(30)
);

8条回答
  •  伪装坚强ぢ
    2020-11-21 05:25

    As mentioned by joanq MariaDB now seems to support CHECK constraints among other goodies:

    "Support for CHECK CONSTRAINT (MDEV-7563)."

    https://mariadb.com/kb/en/mariadb/mariadb-1021-release-notes/

提交回复
热议问题