Casting to Decimal is not supported in LINQ to Entities queries

前端 未结 4 1582
后悔当初
后悔当初 2021-02-14 01:58

I have a database table Transaction (transactionID, LocalAmount...). where datatype for Localamount property is float. ON the UI I am trying to return a

4条回答
  •  春和景丽
    2021-02-14 02:41

    I would suggest you make the cast after your query has finished

    var somevar = (decimal)transactions.YourValue
    

提交回复
热议问题