- make sql version tester more robust
- fix missing "dml" in code for old sql version