Skip to content

Commit

Permalink
tweak human readable bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
fuziontech committed Aug 22, 2023
1 parent 660e02f commit 71b2d43
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions housewatch/clickhouse/backups.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@

def get_backups(cluster=None):
if cluster:
QUERY = """SELECT * FROM clusterAllReplicas(%(cluster)s, system.backups) ORDER BY start_time DESC"""
QUERY = """SELECT id, name, status, error, start_time, end_time, num_files, formatReadableSize(total_size) total_size, num_entries, uncompressed_size, compressed_size, files_read, bytes_read FROM clusterAllReplicas(%(cluster)s, system.backups) ORDER BY start_time DESC"""
else:
QUERY = """SELECT * FROM system.backups ORDER BY start_time DESC"""
QUERY = """SELECT id, name, status, error, start_time, end_time, num_files, formatReadableSize(total_size) total_size, num_entries, uncompressed_size, compressed_size, files_read, bytes_read FROM system.backups ORDER BY start_time DESC"""
res = run_query(QUERY, {"cluster": cluster}, use_cache=False)
return res

Expand Down

0 comments on commit 71b2d43

Please sign in to comment.