edit query to get timestamp for DDI sets