From 85571a59b527e409b7896d6b3a093cab5cf19b92 Mon Sep 17 00:00:00 2001 From: Jia-Xuan Liu Date: Thu, 14 Nov 2024 15:16:50 +0800 Subject: [PATCH] add boolean alias --- wren-core/core/src/logical_plan/utils.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wren-core/core/src/logical_plan/utils.rs b/wren-core/core/src/logical_plan/utils.rs index c6316c6d7..439d28ee9 100644 --- a/wren-core/core/src/logical_plan/utils.rs +++ b/wren-core/core/src/logical_plan/utils.rs @@ -44,7 +44,7 @@ pub fn map_data_type(data_type: &str) -> DataType { } match data_type { // Wren Definition Types - "bool" => DataType::Boolean, + "bool" | "boolean"=> DataType::Boolean, "tinyint" => DataType::Int8, "int2" => DataType::Int16, "smallint" => DataType::Int16, @@ -253,6 +253,7 @@ mod test { pub fn test_map_data_type() -> Result<()> { let test_cases = vec![ ("bool", DataType::Boolean), + ("boolean", DataType::Boolean), ("tinyint", DataType::Int8), ("int2", DataType::Int16), ("smallint", DataType::Int16),