mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-19 12:28:15 +08:00
- 补充 Expression IEnumerable<T>.Contains 的支持,之前只能数组或IList<T>;
This commit is contained in:
@ -23,6 +23,8 @@ namespace FreeSql.Tests.PostgreSQLExpression {
|
||||
|
||||
[Fact]
|
||||
public void Array() {
|
||||
IEnumerable<int> testlinqlist = new List<int>(new[] { 1, 2, 3 });
|
||||
var testlinq = select.Where(a => testlinqlist.Contains(a.testFieldInt)).ToList();
|
||||
|
||||
var sql1 = select.Where(a => a.testFieldIntArray.Contains(1)).ToList();
|
||||
var sql2 = select.Where(a => a.testFieldIntArray.Contains(1) == false).ToList();
|
||||
|
Reference in New Issue
Block a user