首页新闻找找看学习计划

EF Core 报错 "The multi-part identifier \"t.__RowNumber__\" could not be bound"

0
悬赏园豆:50 [待解决问题]

ASP.NET Core 3.0 应用日志中出现下面的错误,EF Core 版本是 3.0 preview 5 ,请问这个问题是什么原因引起的?

System.Data.SqlClient.SqlException (0x80131904): The multi-part identifier \"t.__RowNumber__\" could not be bound.
The multi-part identifier \"t.__RowNumber__\" could not be bound.
   at System.Data.SqlClient.SqlCommand.<>c.<ExecuteDbDataReaderAsync>b__126_0(Task`1 result)
   at System.Threading.Tasks.ContinuationResultTaskFromResultTask`2.InnerInvoke()
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location where exception was thrown ---
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location where exception was thrown ---
   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteAsync(IRelationalConnection connection, DbCommandMethod executeMethod, IReadOnlyDictionary`2 parameterValues, IDiagnosticsLogger`1 logger, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Query.Internal.AsyncQueryingEnumerable`1.AsyncEnumerator.BufferlessMoveNext(DbContext _, Boolean buffer, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Storage.ExecutionStrategy.ExecuteImplementationAsync[TState,TResult](Func`4 operation, Func`4 verifySucceeded, TState state, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Storage.ExecutionStrategy.ExecuteImplementationAsync[TState,TResult](Func`4 operation, Func`4 verifySucceeded, TState state, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Query.Internal.AsyncQueryingEnumerable`1.AsyncEnumerator.MoveNext(CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Query.Internal.AsyncLinqOperatorProvider.ExceptionInterceptor`1.EnumeratorExceptionInterceptor.MoveNext(CancellationToken cancellationToken)
dudu的主页 dudu | 高人七级 | 园豆:41029
提问于:2019-09-02 10:39
< >
分享
所有回答(1)
0

MS SQL错误:无法绑定由多个部分组成的标识符 "xxxxx"
sql语句单独拿出来跑一下就知道了。
https://blog.csdn.net/Alone5256/article/details/88659338

DbContext.Database.Log = (c) => { Console.WriteLine(c); };

张朋举 | 园豆:1253 (小虾三级) | 2019-09-09 12:04
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册