Added additional messages and added time check to where clause.