You can use ```$this->db->sql_query($sql, 300)``` to set a 5min cache. https://wiki.phpbb.com/Database_Abstraction_Layer#sql_query