* Fix bug #34564,SQL error in constructing query statement.

This commit is contained in:
tanghucheng
2023-05-29 07:19:38 +00:00
parent 07642d3c83
commit fb25ce18bf
+5 -1
View File
@@ -43,7 +43,11 @@ class zdb
global $config;
$allTables = array();
$stmt = $this->dbh->query("show full tables");
$sql = 'show full tables';
if($config->db->driver == 'dm') $sql = "select OBJECT_NAME AS Tables_in_{$config->db->name}, OBJECT_TYPE as Table_type from all_objects where owner='{$config->db->name}' and OBJECT_TYPE in('TABLE','VIEW');";
$stmt = $this->dbh->query($sql);
while($table = $stmt->fetch(PDO::FETCH_ASSOC))
{
$tableType = strtolower($table['Table_type']);