原文:The cast to value type 'System.Decimal' failed because the materialized value is null. Either the result type's generic parameter or the query must use a nullable type.

investmentRepository.Table.Where t gt t.CustomerId customerId amp amp t.InvestmentStatus tempStatus .Sum t gt t.Amount 查詢結果存在NULL值,在嘗試將它轉換成System.Int 時出了錯,解決方法如下 investmentRepository.Table.Where t gt ...

2016-10-18 13:09 0 1474 推薦指數:

查看詳情

 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM