diff --git a/Hadoop/ZKLT.Hadoop.API/Program.cs b/Hadoop/ZKLT.Hadoop.API/Program.cs index abe13e2..98637bc 100644 --- a/Hadoop/ZKLT.Hadoop.API/Program.cs +++ b/Hadoop/ZKLT.Hadoop.API/Program.cs @@ -39,13 +39,35 @@ namespace ZKLT.Hadoop.API #region Cors¿çÓò app.UseCors("all"); #endregion - app.UseHadoop((c) => { - c.Host = "172.17.0.1"; + + //app.UseHadoop((c) => + //{ + // c.Host = "127.0.0.1"; + // c.Account = "root"; + // c.PassWord = "root"; + // c.Key = "devdb"; + // c.Port = 3306; + //}); + + + //app.UseHadoop((c) => + //{ + // c.Host = "172.17.0.1"; + // c.Account = "root"; + // c.PassWord = "root"; + // c.Key = "testdb"; + // c.Port = 4000; + //}); + + app.UseHadoop((c) => + { + c.Host = "118.195.165.218"; c.Account = "root"; c.PassWord = "root"; c.Key = "testdb"; c.Port = 4000; }); + // Configure the HTTP request pipeline. if (app.Environment.IsDevelopment()) { diff --git a/Hadoop/ZKLT.Hadoop.Model/HDP_ColumnDataType.cs b/Hadoop/ZKLT.Hadoop.Model/HDP_ColumnDataType.cs index f49a18f..caa710f 100644 --- a/Hadoop/ZKLT.Hadoop.Model/HDP_ColumnDataType.cs +++ b/Hadoop/ZKLT.Hadoop.Model/HDP_ColumnDataType.cs @@ -40,5 +40,10 @@ namespace ZKLT.Hadoop.Model /// 布尔值 /// public const string BOOL = "BOOL"; + + /// + /// 大文本 + /// + public const string LONGTEXT = "LONGTEXT"; } } diff --git a/Hadoop/ZKLT.Hadoop/TableService.cs b/Hadoop/ZKLT.Hadoop/TableService.cs index 26c4dcd..99c1ed5 100644 --- a/Hadoop/ZKLT.Hadoop/TableService.cs +++ b/Hadoop/ZKLT.Hadoop/TableService.cs @@ -611,7 +611,7 @@ namespace ZKLT.Hadoop switch (where[_column.Key!]) { case HDP_WhereType.LIKE: - _wherestr.Append($@" AND `{_column.Key!}` {where[_column.Key!]} '%' + @{_column.Key!} + '%'"); + _wherestr.Append($@" AND `{_column.Key!}` {where[_column.Key!]} CONCAT('%',@{_column.Key!},'%')"); break; default: _wherestr.Append($@" AND `{_column.Key!}` {where[_column.Key!]} @{_column.Key!}");