fix keys query