[MDEV-15460] Docu Bug Check Constraints Created: 2018-03-04  Updated: 2018-03-14  Resolved: 2018-03-14

Status: Closed
Project: MariaDB Server
Component/s: Documentation
Affects Version/s: 10.2.13
Fix Version/s: N/A

Type: Bug Priority: Minor
Reporter: Oli Sennhauser Assignee: Ian Gilfillan
Resolution: Fixed Votes: 0
Labels: None
Environment:

Linux, n.a.



 Description   

Documentation here:
https://mariadb.com/kb/en/library/constraint/
seems to be wrong:
ALTER TABLE t1 ADD CHECK a_greater (a>b);
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'a_greater (a>b)' at line 1
Correct is IMHO:
ALTER TABLE t1 ADD CONSTRAINT a_greaterx CHECK (a>b);
Query OK, 0 rows affected (0.10 sec)
Records: 0 Duplicates: 0 Warnings: 0



 Comments   
Comment by Ian Gilfillan [ 2018-03-14 ]

Docs have been updated with working example

Generated at Thu Feb 08 08:21:29 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.