-
-
Notifications
You must be signed in to change notification settings - Fork 26
Open
Labels
Description
Hello, here is a MySQL script below. Can Telesys-cli create classes with Hibernate annotations based on this script? How to launch it during the build of the Java Maven project?
CREATE TABLE IF NOT EXISTS orders (
order_id INT PRIMARY KEY,
order_number VARCHAR(128),
order_data VARCHAR(4096),
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
)ENGINE=INNODB;
CREATE TABLE IF NOT EXISTS invoices (
invoice_id INT PRIMARY KEY,
order_id INT UNIQUE,
INDEX ord_id (order_id),
FOREIGN KEY (order_id)
REFERENCES orders(order_id)
ON DELETE CASCADE,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
)ENGINE=INNODB;