Move select, insert, update, and delete query generation to distinct classes