我有这段代码:
var files = (from f in _fileRep.GetFiles()
where fileID.Contains(f.FileID)
select f.FileName).ToList();
var destFiles = (from f in _fileRep.GetFiles()
where f.FolderID == destFolderID
select f.FileName).ToList();
bool valid = destFiles.Any(x => files.Contains(x));
fileID 是 int [],我正在尝试验证在数据库中移动文件时 FolderID 与 destFolderID 匹配的文件名列表是否存在。
我越来越:
"Unable to create a null constant value of type 'System.Int32[]'.
Only entity types, enumeration types or primitive types are
supported in this context."