From 6746d063d4216ab32baf22fe6475e2f3aa233b00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B4=AA=E5=8D=8E=E5=85=B5?= <455982533@qq.com> Date: Sat, 9 Nov 2024 13:41:42 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=B9IN=E5=8D=95=E7=8B=AC=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Hadoop/ZKLT.Hadoop/TableService.cs | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/Hadoop/ZKLT.Hadoop/TableService.cs b/Hadoop/ZKLT.Hadoop/TableService.cs index 6bc4552..dc7c077 100644 --- a/Hadoop/ZKLT.Hadoop/TableService.cs +++ b/Hadoop/ZKLT.Hadoop/TableService.cs @@ -99,6 +99,10 @@ namespace ZKLT.Hadoop _wherestr.AppendLine(@$"AND `{_item.Name}` {_Itemv[k]} @{_guid}"); param.Add(_guid, $@"%{((JValue)_Colv[k]!).Value!}%"); break; + case HDP_WhereType.IN: + _wherestr.AppendLine(@$"AND `{_item.Name}` {_Itemv[k]} @{_guid}"); + param.Add(_guid, _Colv[k]!); + break; case HDP_WhereType.QUERYIN: var _Command = JsonConvert.DeserializeObject(_Colv[k].ToString())!; var _Query = QueryString(_Command.SourceId!, _Command.TableId!, _Command.Where, _Command.Data, _Command.Order, _Command.Col, param); @@ -110,18 +114,10 @@ namespace ZKLT.Hadoop case HDP_WhereType.LESS: case HDP_WhereType.MORETHEN: case HDP_WhereType.LESSTHEN: - case HDP_WhereType.IN: case HDP_WhereType.BETWEEN: default: _wherestr.AppendLine(@$"AND `{_item.Name}` {_Itemv[k]} @{_guid}"); - if (_Colv[k]!.Type == JTokenType.Object || _data[_item.Name]!.Type == JTokenType.Array) - { - param.Add(_guid, _Colv[k]!); - } - else - { - param.Add(_guid, ((JValue)_Colv[k]!).Value!); - } + param.Add(_guid, ((JValue)_Colv[k]!).Value!); break; } }