Dynamic queries successfully implemented