You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For example, when I'd like to search the books that publisher's name is something, what is the best practice ?
@Table
classPublisher {
@PrimaryKey
val id:Long
@Column
val name:String
}
@Table
classBook {
@PrimaryKey
val id:Long
@column
val title:String
@Column
val publisher:Publisher
}
My way is here.
val searchWord ="hogehoge"
orma.selectFromBook()
.where(Publisher_Schema.INSTANCE.name.name +""" like "$searchWord" """)
.executeAsObservable()
.toList()
.subscribeOn(Schedulers.io())
The text was updated successfully, but these errors were encountered:
After updated to v5.1.2, I couldn't use this way, but I found the solution. The target column requires @Column(index = true).
@Table
classPublisher {
@PrimaryKey
val id:Long
@Column(index =true)
val name:String
}
@Table
classBook {
@PrimaryKey
val id:Long
@column
val title:String
@Column(index =true)
val publisher:Publisher
}
For example, when I'd like to search the books that publisher's name is something, what is the best practice ?
My way is here.
The text was updated successfully, but these errors were encountered: