I'm exporting an ERD to SQL Server. The diagram consists of one entity with a 1-to-1 relationship to a second table. Looking at the generated SQL the foreign keys are MISSING. Am I doing something wrong? Any way to fix this other than manually edit the generated SQL I export?
CREATE TABLE `flights_payment` (
`payment_id` int,
`payment_amount` int,
PRIMARY KEY (`payment_id`)
);
CREATE TABLE `users_booking` (
`booking_id` int,
`payment_id` int,
`booking_confirmationCode` VARCHAR(255) NOT NULL ,
PRIMARY KEY (`booking_id`)
);
Additionally, I have noticed that nullability is not defined even though the diagram cardinality is defined
CREATE TABLE `passport` (
`passport_id` int,
`user_id` int,
PRIMARY KEY (`passport_id`)
);
CREATE TABLE `user` (
`user_id` int,
`name` string,
PRIMARY KEY (`user_id`)
);