finishing correctness test database data retrieval