Moved more to use test-for-re, left only 1 sql test function