Sorry for bad title, I don't know how do describe better if you have a better one please tell me ;)
Please look at these small sql fiddle: http://ift.tt/1M93WZ6
I need the "Value" from a specific "Title" in a new column ("Age"). But I need the "Value" in any row for the same "SN_Main". The first query was my first try. It is fast and ok but I get the "Value" only for the row with the same "Title".
The second query is wat I want but the subquery is to slow, so I wanna solve this without subquery. The productive tables are bigger and I need this like 10 times and with subquery it become incredible slow.
So is there any way to get this output with other sql statements???
I hope you understand me, I'm so sorry about bad explanation :)
Regards Martin
Aucun commentaire:
Enregistrer un commentaire