Update buildDSRetrievalSQL call. Fixes #47