To update database method to automatically set the time

Signed-off-by: Manasa <manasagopal.93@gmail.com>