NorthwindSetOperationsQuerySqlServerTest.Intersect_nested failed
- Dominant language
- C#
- Stars
- 14.8k
- Forks
- 3.4k
- PR merge metrics
- PR metrics pending
Description
Failed twice in the last week, each time on a different machine.
```
Summary
Tests run: [47384](https://github.com/dotnet/efcore/issues/new#all) — Failures: [1](https://github.com/dotnet/efcore/issues/new#failures), Skipped: [170](https://github.com/dotnet/efcore/issues/new#skipped), Run time: 427.577s, Finished: 01/27/2024 22:06:07
Failed tests
1.0485053s✘ Microsoft.EntityFrameworkCore.Query.NorthwindSetOperationsQuerySqlServerTest.Intersect_nested(async: True)
Microsoft.Data.SqlClient.SqlException : Incorrect syntax near ')'.
at Microsoft.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, SqlCommand command, Boolean callerHasConnectionLock, Boolean asyncClose)
at Microsoft.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at Microsoft.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
at Microsoft.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
at Microsoft.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean isAsync, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
at Microsoft.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry, String method)
at Microsoft.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior)
at Microsoft.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior)
at Microsoft.EntityFrameworkCore.TestUtilities.RelationalQueryAsserter.ExecuteReader(DbCommand command) in C:\local\code\efcore\test\EFCore.Relational.Specification.Tests\TestUtilities\RelationalQueryAsserter.cs:line 72
at Microsoft.EntityFrameworkCore.TestUtilities.RelationalQueryAsserter.ExecuteOurDbCommand(Int32 expectedCount, IQueryable queryable) in C:\local\code\efcore\test\EFCore.Relational.Specification.Tests\TestUtilities\RelationalQueryAsserter.cs:line 30
at Microsoft.EntityFrameworkCore.TestUtilities.RelationalQueryAsserter.AssertRogueExecution(Int32 expectedCount, IQueryable queryable) in C:\local\code\efcore\test\EFCore.Relational.Specification.Tests\TestUtilities\RelationalQueryAsserter.cs:line 19
at Microsoft.EntityFrameworkCore.TestUtilities.QueryAsserter.AssertQuery[TResult](Func`2 actualQuery, Func`2 expectedQuery, Func`2 elementSorter, Action`2 elementAsserter, Boolean assertOrder, Boolean assertEmpty, Boolean async, String testMethodName, Boolean filteredQuery) in C:\local\code\efcore\test\EFCore.Specification.Tests\TestUtilities\QueryAsserter.cs:line 93
at Microsoft.EntityFrameworkCore.Query.NorthwindSetOperationsQuerySqlServerTest.Intersect_nested(Boolean async) in C:\local\code\efcore\test\EFCore.SqlServer.FunctionalTests\Query\NorthwindSetOperationsQuerySqlServerTest.cs:line 1270
--- End of stack trace from previous location ---
Output:
Compiling query expression:
'DbSet()
.Where(c => c.City == "México D.F.")
.Intersect(DbSet()
.Where(s => s.ContactTitle == "Owner"))
.Intersect(DbSet()
.Where(e => e.Fax != null))'
Generated query execution expression:
'queryContext => new SingleQueryingEnumerable(
(RelationalQueryContext)queryContext,
RelationalCommandCache.QueryExpression(
Projection Mapping:
EmptyProjectionMember -> Dictionary { [Property: Customer.CustomerID (string) Required PK AfterSave:Throw MaxLength(5), 0], [Property: Customer.Address (string) MaxLength(60), 1], [Property: Customer.City (string) Index MaxLength(15), 2], [Property: Customer.CompanyName (string) Required Index MaxLength(40), 3], [Property: Customer.ContactName (string) MaxLength(30), 4], [Property: Customer.ContactTitle (string) MaxLength(30), 5], [Property: Customer.Country (string) MaxLength(15), 6], [Property: Customer.Fax (string) MaxLength(24), 7], [Property: Customer.Phone (string) MaxLength(24), 8], [Property: Customer.PostalCode (string) Index MaxLength(10), 9], [Property: Customer.Region (string) Index MaxLength(15), 10] }
SELECT i0.CustomerID, i0.Address, i0.City, i0.CompanyName, i0.ContactName, i0.ContactTitle, i0.Country, i0.Fax, i0.Phone, i0.PostalCode, i0.Region
FROM (
SELECT i.CustomerID, i.Address, i.City, i.CompanyName, i.ContactName, i.ContactTitle, i.Country, i.Fax, i.Phone, i.PostalCode, i.Region
FROM (
SELECT c.CustomerID, c.Address, c.City, c.CompanyName, c.ContactName, c.ContactTitle, c.Country, c.Fax, c.Phone, c.PostalCode, c.Region
FROM Customers AS c
WHERE c.City == N'México D.F.'
INTERSECT
SELECT c0.CustomerID, c0.Address, c0.City, c0.CompanyName, c0.ContactName, c0.ContactTitle, c0.Country, c0.Fax, c0.Phone, c0.PostalCode, c0.Region
FROM Customers AS c0
WHERE c0.ContactTitle == N'Owner'
) AS i
INTERSECT
SELECT c1.CustomerID, c1.Address, c1.City, c1.CompanyName, c1.ContactName, c1.ContactTitle, c1.Country, c1.Fax, c1.Phone, c1.PostalCode, c1.Region
FROM Customers AS c1
WHERE c1.Fax != NULL
) AS i0
),
ReaderColumn[] { ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn, ReaderColumn },
Func,
TestModels.Northwind.NorthwindSqlServerContext,
False,
True,
True
)'
Creating DbCommand for 'ExecuteReader'.
Created DbCommand for 'ExecuteReader' (0ms).
Initialized DbCommand for 'ExecuteReader' (0ms).
Closing data reader to 'Northwind' on server 'avickers420w'.
A data reader for 'Northwind' on server 'avickers420w' is being disposed after spending 198ms reading results.
```
Contributor guide
Assessment
This issue has not been assessed yet.