mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-19 04:18:16 +08:00
- 增加 pgsql 表达式树解析 hstore[""];
This commit is contained in:
@ -118,11 +118,12 @@ namespace FreeSql.Odbc.PostgreSQL
|
||||
if (objType != null || objType.IsArrayOrList())
|
||||
{
|
||||
string left = null;
|
||||
if (objType.FullName == typeof(Dictionary<string, string>).FullName)
|
||||
if (objType == typeof(Dictionary<string, string>))
|
||||
{
|
||||
left = objExp == null ? null : getExp(objExp);
|
||||
switch (callExp.Method.Name)
|
||||
{
|
||||
case "get_Item": return $"{left}->{getExp(callExp.Arguments[argIndex])}";
|
||||
case "Contains":
|
||||
var right = getExp(callExp.Arguments[argIndex]);
|
||||
return $"({left} @> ({right}))";
|
||||
@ -206,7 +207,7 @@ namespace FreeSql.Odbc.PostgreSQL
|
||||
}
|
||||
break;
|
||||
}
|
||||
if (memParentExp.FullName == typeof(Dictionary<string, string>).FullName)
|
||||
if (memParentExp == typeof(Dictionary<string, string>))
|
||||
{
|
||||
var left = getExp(memExp.Expression);
|
||||
switch (memExp.Member.Name)
|
||||
|
Reference in New Issue
Block a user