diff --git a/src/meta/model/migration/src/m20241025_062548_singleton_vnode_count.rs b/src/meta/model/migration/src/m20241025_062548_singleton_vnode_count.rs index eb276099e24bf..bd2b12bd0724c 100644 --- a/src/meta/model/migration/src/m20241025_062548_singleton_vnode_count.rs +++ b/src/meta/model/migration/src/m20241025_062548_singleton_vnode_count.rs @@ -12,8 +12,16 @@ impl MigrationTrait for Migration { UpdateStatement::new() .table(Table::Table) .values([(Table::VnodeCount, Expr::value(1))]) - .and_where(Expr::col(Table::DistributionKey).eq(Expr::value("[]"))) - .and_where(Expr::col(Table::DistKeyInPk).eq(Expr::value("[]"))) + .and_where( + Expr::col(Table::DistributionKey) + .cast_as(Alias::new("varchar")) + .eq(Expr::value("[]")), + ) + .and_where( + Expr::col(Table::DistKeyInPk) + .cast_as(Alias::new("varchar")) + .eq(Expr::value("[]")), + ) .and_where(Expr::col(Table::VnodeColIndex).is_null()) .to_owned(), )