Thanks Frans, that worked great.
One last question on the parsing of the ToQueryText value. When I use the following code to implement the ToQueryText method:
return string.Format("DIFFERENCE({1},'{0}')", _value, base.ToQueryText(ref uniqueMarker, inHavingClause));
}
, it emits the following SQL:
WHERE ( DIFFERENCE([IHHP360].[dbo].[tblUser].[ftxtLastName],''Part'') >= @LastName1)
The single apostrophe's are getting doubled up. If I remove the single apostrophe's from the ToQueryText method:
return string.Format("DIFFERENCE({1},{0})", _value, base.ToQueryText(ref uniqueMarker, inHavingClause));
}
it does not encapulate the string literal in single apostrophe's at all and of course, SQL Server reports a syntax error.
Any thoughts?
Thanks,
Can1