A friend of mine has asked me a question which i do not know how.
The problem is he wants to use a result set of a query more than one time. Whenever he wants.
There is example tables and example output attached.
I will query two times only:
Select * from ornek1_ust
Select * from ornek1_alt
Is it possible to roam in a result set we already have with PHP to have some output like example output. I want to query database with full data for once. Then i want to use it wherever i want whenever i want.
Example Tables:


Example Output:

You’d want to “cache” the results within PHP. To fetch the data, you’d do a simple join query:
and within PHP, do something like:
which will build an array that looks like your desired data: