From f582b489bbd44fe00f58966f0f262a385b02c14a Mon Sep 17 00:00:00 2001 From: Patrick Huang Date: Tue, 19 Mar 2024 14:00:42 +0000 Subject: [PATCH] fix: show sub_level_id for level 0 --- .../src/catalog/system_catalog/rw_catalog/rw_hummock_version.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend/src/catalog/system_catalog/rw_catalog/rw_hummock_version.rs b/src/frontend/src/catalog/system_catalog/rw_catalog/rw_hummock_version.rs index 48e2dcfd5361b..8332cc4d1d453 100644 --- a/src/frontend/src/catalog/system_catalog/rw_catalog/rw_hummock_version.rs +++ b/src/frontend/src/catalog/system_catalog/rw_catalog/rw_hummock_version.rs @@ -123,7 +123,7 @@ fn version_to_sstable_rows(version: HummockVersion) -> Vec { object_id: sst.object_id as _, compaction_group_id: cg.group_id as _, level_id: level.level_idx as _, - sub_level_id: (level.level_idx > 0).then_some(level.sub_level_id as _), + sub_level_id: (level.level_idx == 0).then_some(level.sub_level_id as _), level_type: level.level_type as _, key_range_left: key_range.left, key_range_right: key_range.right,