finalized sql data stream queries