add query with timestamp section