From 9e08ec4659cd7e1a5184b2b9187f6681df53a568 Mon Sep 17 00:00:00 2001 From: ljl <17743125563@163.com> Date: Wed, 7 Aug 2024 11:24:28 +0800 Subject: [PATCH] spi-search:fix adv query is not null. --- backend/spi/spi-search/src/serv/pg/search_pg_item_serv.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/spi/spi-search/src/serv/pg/search_pg_item_serv.rs b/backend/spi/spi-search/src/serv/pg/search_pg_item_serv.rs index a6b052655..8cbe4c2d3 100644 --- a/backend/spi/spi-search/src/serv/pg/search_pg_item_serv.rs +++ b/backend/spi/spi-search/src/serv/pg/search_pg_item_serv.rs @@ -583,7 +583,7 @@ pub async fn search(search_req: &mut SearchItemSearchReq, funs: &TardisFunsInst, } else if ext_item.op == BasicQueryOpKind::IsNull { sql_and_where.push(format!("ext ->> '{}' is null", ext_item.field)); } else if ext_item.op == BasicQueryOpKind::IsNotNull { - where_fragments.push(format!( + sql_and_where.push(format!( "(ext ->> '{}' is not null or ext ->> '{}' != '' or ext ->> '{}' != '[]')", ext_item.field, ext_item.field, ext_item.field ));