Skip to content

Select partial column is broken. #459

Answered by billy1624
kev0960 asked this question in Q&A
Discussion options

You must be logged in to vote

For example...

#[derive(FromQueryResult)]
struct CustomModel {
    some_column: String,
}

let custome_model: Vec<CustomModel> = Data::Entity()
      .find()
      .select_only(Data::Column::SomeColumn)
      .all(&db)
      .into_model()
      .await?

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by tyt2y3
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #448 on January 15, 2022 10:20.