-
-
Notifications
You must be signed in to change notification settings - Fork 515
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[sea-orm-cli] Unique key handling #191
Comments
constraint_name
column_name
referenced_table_name
referenced_column_name
update_rule
delete_rule Which of these column is null in your If you know which table caused it to panic, we can query the |
and if i reduce it to be not |
Seems like all of those are |
Well, nice info. |
Seems to be a grown problem of the existing database, i cannot reproduce it with a minimal sample at the moment |
Oh then may be the only thing we can do is to modify the query such that these columns will not be NULL. |
Ok i got it: USE sea_error;
CREATE TABLE `table_2` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `table_1` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
`table_2_id` bigint(20) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `table_2_id` (`table_2_id`),
CONSTRAINT `table_2_id` FOREIGN KEY (`table_2_id`) REFERENCES `table_2` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8; |
Cool! That is really helpful. |
The crash has been fixed, at least for the schema in question.
There is still an inaccurancy (the |
I will try it later and give feedback. Thanks |
Added on 360436c. For expanded format, it already annotated |
Works as expected. Thanks |
Released in |
`driver/postgres` handle non-exhaustive `Value`
Even with verbose mode i'm not sure why this
sea-orm-cli generate entity
fails:I know that i had problems with this database also with diesel but the error and the verbose log are not very helpful in this case.
The text was updated successfully, but these errors were encountered: