I have a query and a loop where I output the results. Something like this:
SELECT
t1.var1,
t1.var2,
t2.var1,
t2.var2
FROM t1
LEFT JOIN t2 ON (t1.id= t2.id)
WHERE
t1.var1 = $value
I need to count what's the total number of rows I output.
I've tried adding COUNT (t1.id) AS TOTALCOUNT but it doesn't seem to work...
😕