Escaping apostrophe/single quote in parameterized sql in asp
I'm new to parametrized SQL. I've got a query in an .asp page that's getting one or more client names from a form. These are held in an array called clientArr and then passed through to SQL server as parameters. I'm escaping the ' as '' but this doesn't appear to be working. If I run the query with a client name like McDonald's , it returns no results. clientArr(y) = Replace(clientArr(y),"'","''" ... if qsClient > "" Then dim booComma booComma = false if mySQLwhere > "" Then mySQLwhere = mySQLwhere& " AND " End if mySQLwhere = mySQLwhere & " (p.client IN ( " for y = 0 to Ubound(clientArr) if