Escaping double quotes inside XML spring config file
formatting, java, oracle, spring, xml
Solution
try this
<authentication-manager>
<authentication-provider>
<jdbc-user-service data-source-ref="dataSource"
users-by-username-query="select USERNAME as "username",PASSWORD as "password",1 as "enabled" from USER_APP where username = 'a'"
/>
</authentication-manager>
Problem
I have an SQL Query and i want to put it in the XML spring config File, but i'm getting formatting errors so how can i escape double quotes in this case ? Here is my property : ``` <authentication-manager> <authentication-provider> <jdbc-user-service data-source-ref="dataSource" users-by-username-query="select USERNAME as "username",PASSWORD as "password",1 as "enabled" from USER_APP where username = 'a'" /> </authentication-provider> </authentication-manager> ``` I've tried the \ and it's not working ! Thanks in advance !