Hi,
I use TMySql and need get current_time in server mysql. anyone know how?
Hi,
I use TMySql and need get current_time in server mysql. anyone know how?
MySql functions:
CURDATE() or CURRENT_DATE // date
CURTIME() or CURRENT_TIME // time
NOW(), SYSDATE() or CURRENT_TIMESTAMP // date and time
Please try using them
Thank you,
But I not found the definition of these functions in TmySQL !
You cam open a table with sql query 'SELECT SYSDATE()'
You get the required value in first row, first column of the table
   oQuery := TMySQLTable():New(oServer:nSocket,"SELECT curtime()","Teste",.t.)
   cHora := oQuery:FieldGet(1)
   oQuery := TMySQLTable():New(oServer:nSocket,"SELECT curdate()","Teste",.t.)
   dData := oQuery:FieldGet(1)good.
you can make them as your personal library functions.