ClickHouse: Fix list of tables (bug #1176)

This commit is contained in:
Marcus
2025-09-24 10:16:02 +01:00
committed by Jakub Vrana
parent 57c5370c67
commit 240c8fc5e7
2 changed files with 2 additions and 4 deletions

View File

@@ -274,7 +274,7 @@ if (isset($_GET["clickhouse"])) {
function table_status($name = "", $fast = false) {
$return = array();
$tables = get_rows("SELECT name, engine FROM system.tables WHERE database = " . q(connection()->_db));
$tables = get_rows("SELECT name, engine FROM system.tables WHERE database = " . q(connection()->_db) . ($name != "" ? " AND name = " . q($name) : ""));
foreach ($tables as $table) {
$return[$table['name']] = array(
'Name' => $table['name'],