Re: help improving 'join' efficiency in sub-querys
> the problem is that I now have to add other "questions"
> so where frm_req.id = 336, 337, 338 etc as their own columns
> without creating additional rows.
The desired result is multi-column with each column the result of a query like the one for req_id=335?
You could pivot on req_id to build the Select list. Without aggregation, that's easier to write in the app language. The query would be a lot faster than correlated subqueries, which have to repeat all those joins for each row.
Plan B: save such single column results to a result table, and display the whole thing at the end. Assuming this query is needed often, you could keep the result table and building updating of it into the database and/or into the apps.
Subject
Written By
Posted
September 15, 2016 07:43AM
September 15, 2016 12:13PM
September 16, 2016 06:19AM
September 16, 2016 11:42AM
September 19, 2016 03:24AM
September 19, 2016 03:55AM
Re: help improving 'join' efficiency in sub-querys
September 19, 2016 08:00AM
September 19, 2016 08:49AM
September 19, 2016 09:45AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.