extract search query