-
-
Notifications
You must be signed in to change notification settings - Fork 535
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
Cascade #540
Comments
Hey @Ilqjx, you can select related models via lazy loading or eager loading. |
Hello @billy1624, I know these two apis exist, what I want to know is can pub struct Model {
#[sea_orm(primary_key, auto_increment = false)]
pub id: i32,
pub name: String,
pub animals: Vec<Animal>,
} This will make it more convenient to obtain animals, such as |
Similar feature is under development, see #415 for details |
Ok, thanks for your reply. |
Table Person
Table Animal
The generated model is like this, I mean a person has many animals, but I don't see anything similar to the generation of
animals: Vec<Animal>
. If I want to get the animals under the person, how should I do it?The text was updated successfully, but these errors were encountered: