UpdateUser Service and Apostrophe
Posted: February 14th, 2024, 12:30 pm
The 'update user' service from the Authentication Workshop runs a query that has a non-parameterized query to update the user info. If the UserId has an Apostrophe then it fails with the following message:
Incorrect syntax near 'D'. Query:Select PropertyName from EP_Platform_DV.Cantex_EASYCommerceMVC_Base.User_Property_Values where UserId = 'R'D.f'ss' and PropertyName = 'BaseCurrency'
Incorrect syntax near 'D'. Query:Select PropertyName from EP_Platform_DV.Cantex_EASYCommerceMVC_Base.User_Property_Values where UserId = 'R'D.f'ss' and PropertyName = 'BaseCurrency'