-1
SELECT scanlators.* FROM lista_de_capitulos
INNER JOIN scanlators ON JSON_CONTAINS(lista_de_capitulos.scanlator, scanlators.id)
GROUP BY scanlators.url ORDER BY COUNT(lista_de_capitulos.id_manga) DESC LIMIT 100
How can I improve the execution speed of this query? It’s taking about 15 seconds to complete the execution currently.
Evaluate the implementation plan and if, by chance, the implementation of any index can improve the performance of your query.
– anonimo
this json_contains seems costly, I don’t understand why it’s doing so
– Lucas Miranda
@Lucasmiranda and because the column is an object.
– Gabriel Henrique
but does it have to be? it will look at the whole object just to see if it has the id, this is nothing performatic, if you could normalize this guy in another table, you could index
– Lucas Miranda