11-10-2016, 06:24 AM
Hi
i'm totally new with PDO but i'm thinking it might be good to reuse the userspice connection. so if anyone could give a hint in how i loop out the data i got with below query i would be grateful.
works just fine but i cant figure out how get that to a foreach or while loop...
does not work...
i'm totally new with PDO but i'm thinking it might be good to reuse the userspice connection. so if anyone could give a hint in how i loop out the data i got with below query i would be grateful.
Code:
$clist = DB::getInstance()->query("SELECT * FROM company")
Code:
echo $clist->count()
Code:
foreach ($clist as $row) {echo $row["xyz"];}