Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

datetime.datetime.now() + 1

Tags:

I would like to add 1 day with 3 hours + datetime.now.

mante = Employee() mante.usercompany = idnamez mante.knowledgelost = datetime.datetime.now()+1 day more 3 hours. mante.seguemplelost = datetime.datetime.now()+1  mante.put() 

Someone knows how to do it?

like image 546
a3rxander Avatar asked Jun 10 '11 18:06

a3rxander


People also ask

What does datetime datetime NOW () do?

now() function Return the current local date and time, which is defined under datetime module.


1 Answers

datetime.datetime.now() + datetime.timedelta(days=1, hours=3) 
like image 174
Sven Marnach Avatar answered Nov 10 '22 02:11

Sven Marnach