0

就像标题所说,我收到了错误:

The column name is not valid. [ Node name (if any) = Extent1,Column name = marketplace ]

“市场”没有出现在代码中的其他任何地方,并且是表中列的名称。

给出错误的 SQL 语句是:

SELECT [Extent1].[id] AS [id], 
[Extent1].[marketplace] AS [marketplace], 
[Extent1].[c1] AS [c1], 
[Extent1].[name] AS [name], 
[Extent1].[description] AS [description], 
[Extent1].[c2] AS [c2], 
[Extent1].[c3] AS [c3], 
[Extent1].[c4] AS [c4], 

无论订单如何,它都会在列市场上给出错误。

另外一件事是市场列必须为 NOT NULL,但在数据库中满足此条件。

我使用 EF 使用“逆向工程代码优先命令”来生成它,并在尝试将实体类转换为列表时出现错误结果。

有人有想法么?

4

0 回答 0