[SQL] Using 'Like' operator for prepared statement
-
Hi all~ E.g "Select * from table_A where firstName Like '%" + string + "%'"; How to change the ad-hoc sql to prepared statement using operator 'like' and '%'? Thanks
Your question belongs in the SQL / ADO / ADO.NET forum. This forum is for questions related to C# only. Forums more specific to ADO.NET and ASP.NET exist for questions about such topics despite what language you use, since all managed languages compile down to pure or mixed Intermediate Language (IL) and have access to the Base Class Library (BCL; at least what is CLS-compliant as dictated by the Common Language Infrastructure (CLI)). This posting is provided "AS IS" with no warranties, and confers no rights. Software Design Engineer Developer Division Sustained Engineering Microsoft [My Articles] [My Blog]