How do I escape SQL Server keywords using Spring-test-dbunit framework?
In my @DatabaseSetup("sampleData.xml")
file, I have a table called File
which is a reserved keyword in SQL Server. In order for the queries to run successfully on SQL Server, the reserved keyword would need to be encapsulated with square brackets ([File]
).
From Expoting Dataset to a xml file giving error in DBunit, I see that this can be done in dbunit by setting a pattern escape config. I don't know where or how to put this config when using Spring-test-dbunit.
Where/how do I tell the spring-test-dbunit framework to properly escape database keywords when inserting the test data into the db using the provided xml feed?
If you would like to see code, let me know what excerpts I should post and i would be happy to do so.