阅读背景:

Linq使用字符串查询int

来源:互联网 

I'm trying to query the unique reference number of a table using Linq to Entities. The ID is provided via a textbox and hence a string in my code. Obviously in the database table the field is an integer so I have tried using .ToString first and then .Contains in the same way you would with a varchar(). This doesn't seem to work, with the error coming from the .ToString method. I'm trying to query the unique reference number




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: