This repository has been archived on 2024-10-02. You can view files and clone it, but cannot push or open issues or pull requests.
smart-tag/db/db.sql

14 lines
447 B
SQL

CREATE TABLE vn.smartTag (
code varchar(100) NOT NULL,
shelvingFk varchar(10) NULL,
`level` int(11) NULL,
CONSTRAINT `PRIMARY` PRIMARY KEY (code)
)
ENGINE=InnoDB
DEFAULT CHARSET=utf8
COLLATE=utf8_unicode_ci;
ALTER TABLE vn.smartTag MODIFY COLUMN shelvingFk varchar(10) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL NULL;
ALTER TABLE vn.smartTag ADD CONSTRAINT smartTag_FK FOREIGN KEY (shelvingFk) REFERENCES vn.shelving(code);