Sorgu PDO'de hazırlamak ifadesi tarafından oluşturulan almak için nasıl

0 Cevap php

Biz PDO'de çoklu zaman kullanılmak üzere hazırlanan sorgu almak için yöntemi hazırlamak kullanabilirsiniz.

But i want to know that can we see all the queries executed at the DB. For e.g see below:

<?php

    // Cosidering DB connection already set here. With $db.
    // using named placeholder

    $db->prepare("select * from user where id=:id");
    $db->bindParam(':id',$id);

    for($i=1;$i<=5;$i++)
    {
       $id=$i;
       $db->execute();
    }

?>

OK now we can see that this code will run 5 queries.
So how can i get these queries which is executed by this execute() statement???

Ben tüm açık duyuyorum umuyoruz.

0 Cevap