put (mysql) db statements where they belong