Splitted query handling example from the basic example