I have a linq query in which i want to include those record which are not null or empty in database field but when i use string.isNullorEmpty it gives me error. How can i achieve this task my query is
from post in PostIdPostMeta1
join pstmt in postrepository.GetAllPostMetas() on post.int_PostId equals pstmt.int_PostId
where string.IsNullOrEmpty(pstmt.vcr_MetaValue) == false
select post
If i change string.IsNullOrEmpty(pstmt.vcr_MetaValue) == false to pstmt.vcr_MetaValue != string.Empty it give me SQL Server does not handle comparison of NText, Text, Xml, or Image data types error