I have the following query on a page:
$bericht = "SELECT bericht_id, // mesage_id
bericht, // message
verzonden // sended datetime
I don't need these values in a loop, I just need these values for three other queries. So how do I create variables from these values to use in three other queries on the same page?
Thank you in advance
Well, how about create a class.
and inside that class you have three methods and each method has query codes in there.
And you put those values in global scope.
and call them using those three methods.
You have no WHERE clause so without a loop, you must only have 1 row, just hard code it.
Wouldn't is be easier to JOIN the other queries against the values you need?
Makes a lot more sense to me than performing separate queries.
This topic is now closed. New replies are no longer allowed.