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
First of all, thank you for great work!
So, I am working with google clound sql and it performs very poor on sql connection, so I try to optimize my query amount, so, for example I have following data model:
@entity
interface Racer : Persistable { @get:Key @get:Generated @get:JsonView(Views.Rating::class)
var id: Int
@get:JsonView(Views.Rating::class)
var name: String
@get:JsonView(Views.Rating::class)
var number: Int
}
@entity
interface Rating : Persistable { @get:Key @get:Generated
var id: Int
@get:ManyToOne
@get:Column(name = "racer_id")
var racer: Racer
}
Then, I want to retrieve full list of ratings with racers and it is clear for me that we can retrieve full list by one select with join, but how?
Another way that I can imagine is to select full list on Racers and when we select Ratings, racers should already be loaded from cache.. but they don't
Otherwise I got 1 + n selects, that's to crappy
The text was updated successfully, but these errors were encountered:
First of all, thank you for great work!
So, I am working with google clound sql and it performs very poor on sql connection, so I try to optimize my query amount, so, for example I have following data model:
@entity
interface Racer : Persistable {
@get:Key
@get:Generated
@get:JsonView(Views.Rating::class)
var id: Int
}
@entity
interface Rating : Persistable {
@get:Key
@get:Generated
var id: Int
}
Then, I want to retrieve full list of ratings with racers and it is clear for me that we can retrieve full list by one select with join, but how?
Another way that I can imagine is to select full list on Racers and when we select Ratings, racers should already be loaded from cache.. but they don't
Otherwise I got 1 + n selects, that's to crappy
The text was updated successfully, but these errors were encountered: