laresistance2
11-19-2011, 08:10 PM
Hello,
I wonder how I can make a SHOW TABLES with PDO.
I tried this but it displays only the first table.
$allTable = $pdo->query('SHOW TABLES', PDO::FETCH_NUM);
foreach($allTable->fetch() as $db=>$tableName) {
echo $tableName . '<br />';
}
Can you help me?
Thank you.
I wonder how I can make a SHOW TABLES with PDO.
I tried this but it displays only the first table.
$allTable = $pdo->query('SHOW TABLES', PDO::FETCH_NUM);
foreach($allTable->fetch() as $db=>$tableName) {
echo $tableName . '<br />';
}
Can you help me?
Thank you.