Controlling the timing of an execution of a database query for test purposes includes: receiving the database query, the database query comprising control code; the control code causing a database management system to control the timing of the execution of the database query within the database management system; executing the database query within the database management system.