Solved Beginner question Second Time (1 Viewer)

wanzi

New member
Local time
Today, 14:41
Joined
Dec 24, 2023
Messages
9
I want to increase the seconds display of a DateTime field by 30 seconds. I dont get any further. My update query is not working:
"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAct + (second(DateAct)+1) where IDMit = 2;"
Where is the mistake? Thanks for help
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 20:41
Joined
May 7, 2009
Messages
19,245
use DateAdd() function:

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAdd('s', 30, DateAct) where IDMit = 2;"

you can also use Constant:

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAct + #00:00:30# where IDMit = 2;"

or

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAct + 0.000347222222222222 where IDMit = 2;"
 
Last edited:

wanzi

New member
Local time
Today, 14:41
Joined
Dec 24, 2023
Messages
9
use DateAdd() function:

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAdd('s', 30, DateAct) where IDMit = 2;"

you can also use Constant:

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAct + #00:00:30# where IDMit = 2;"

or

"UPDATE tblMitglieder SET tblMitglieder.DateAct = DateAct + 0.000347222222222222 where IDMit = 2;"

Many Thanks, works wonderfully :):):)
 

Users who are viewing this thread

Top Bottom