Sql tests.