Adding up DATETIME field

2003-08-21 Thread M. Bader
Hi, i'm struggling with updating session expire times in my login table. Can you tell me, how to correctly add an amount of seconds (after that the session expires) to a datetime field? when i do the insert for a new login, or an update, the expire field will alway end up containing zeros

Re: Adding up DATETIME field

2003-08-21 Thread Cybot
M. Bader wrote: Hi, i'm struggling with updating session expire times in my login table. Can you tell me, how to correctly add an amount of seconds (after that the session expires) to a datetime field? when i do the insert for a new login, or an update, the expire field will alway end up

Re: Adding up DATETIME field

2003-08-21 Thread Diana Soares
Hi, You're adding 2 different type elements. Try just doing SELECT NOW() + SEC_TO_TIME(6000); and check the result: mysql select NOW() + sec_to_time(6000); +---+ | NOW() + sec_to_time(6000) | +---+ |20030821159528 |

RE: Adding up DATETIME field

2003-08-21 Thread M. Bader
Hi again, From: Diana Soares [mailto:[EMAIL PROTECTED] Sent: Thursday, August 21, 2003 4:05 PM | NOW() + sec_to_time(6000) | That i allready tried, and it's leading to wrong results, as same as From: Cybot [mailto:[EMAIL PROTECTED] Sent: Thursday, August 21, 2003 3:42 PM UPDATE