Hi using this query with asp.net2 web app and getting the error
select * from openquery(GHWPRD, 'select isnull(first_given_name,'') as first_name, isnull(surname,'') as surname, isnull(home_phone,'') as phone, isnull(address1,'') as street, isnull(address4,'') as city from ORACARE.K_CPIREG where pt_code = '" & snhi & "' and death_date is null ')Msg 102, Level 15, State 1, Line 1
Incorrect syntax near ' & snhi & '.