This commit is contained in:
2018-12-06 00:36:30 +00:00
parent 260f302633
commit 96b18a8a27

View File

@@ -779,12 +779,20 @@ namespace AyaNova.Biz
}
break;
}
case AyDataType.Tags:
case AyDataType.Tags:
{
//Build tags filter fragment
//for initial release a tag filter is inclusive of all tags only
//in other words all tags presented must be in record to match (simple AND)
//Build tags filter fragment
//for initial release a tag filter is inclusive of all tags only
//in other words all tags presented must be in record to match (simple AND)
//select * from awidget where awidget.tags @> array['blah','blah3'::varchar(255)]
StringBuilder sbTags = new StringBuilder();
sbTags.Append("@> array[");
foreach (string s in sTags)
{
sbTags.Append($"'{s}',");
}
sb.Append(sbTags.ToString().TrimEnd(','));
sb.Append("::varchar(255)]");
}
break;
default: