Test Query Created