Comments - How to escape backslash in an insert statement

11 years, 9 months ago Vladislav Vaintroub
This comment has the status of 'removed' and can only be seen by you.

2) is correct. The string needs to be escaped in java (so backslash gets doublebackslash) and in SQL (so doublebackslash gets 4-backslash)

you also can use hex. constants , e.g 0x5C

 
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.