PDO query with php variables -
this question has reply here:
can php pdo statements take table or column name parameter? 6 answerswhy line doesn't work:
$db_table = "mytable"; $pdo->prepare("insert :db_table values (... $query->execute(array( ':db_table' => $db_table,
whereas 1 works:
$pdo->prepare("insert mytable values (...
how can solve ?
tablenames can not replaced in pdo query.
further info can find in next thread can php pdo statements take table name parameter?
php pdo
No comments:
Post a Comment