添加ClickHouse数据库支持

This commit is contained in:
chenbo
2021-11-25 17:40:00 +08:00
parent e6f05aa24e
commit d085acc4e9
29 changed files with 2631 additions and 12 deletions

View File

@@ -157,7 +157,7 @@ namespace FreeSql.Internal.CommonProvider
return this;
}
public string ToSql()
public virtual string ToSql()
{
if (_whereTimes <= 0) return null;
var sb = new StringBuilder().Append("DELETE FROM ").Append(_commonUtils.QuoteSqlName(TableRuleInvoke())).Append(" WHERE ").Append(_where);

View File

@@ -445,7 +445,7 @@ namespace FreeSql.Internal.CommonProvider
_set.Append(", ").Append(_commonUtils.QuoteSqlName(col.Attribute.Name)).Append(" = ");
var colsql = _noneParameter ? _commonUtils.GetNoneParamaterSqlValue(_params, "u", col, col.Attribute.MapType, val) :
_commonUtils.QuoteWriteParamterAdapter(col.Attribute.MapType, $"{_commonUtils.QuoteParamterName("p_")}{_params.Count}");
_commonUtils.QuoteWriteParamterAdapter(col.Attribute.MapType, _commonUtils.QuoteParamterName($"p_{_params.Count}"));
_set.Append(_commonUtils.RewriteColumn(col, colsql));
if (_noneParameter == false)
_commonUtils.AppendParamter(_params, null, col, col.Attribute.MapType, val);