datetime - How to add one year to timestamp in Tarantool 1.8 using SQL? -


as see in documentation,

i can add 1 year date using datetime() function:

select datetime('2014-01-23 12:33:34', '1 year') 

result 2015-01-23 12:33:34.

but have timestamp in column (int value), example 1390466014. when try add year timestamp using datetime() function obtain null instead of 1422005614 in result:

select datetime(1390466014, '1 year')  -- null 

how add 1 year timestamp obtain new timestamp? tarantool have functions working timestamps?

your problem tarantool 1.8.1 storing , handling datetime strings. so, if want use unix time, thart explicitly, that:

tarantool> select datetime(datetime(1390466014, 'unixepoch'), '1 year') --- - - ['2015-01-23 08:33:34'] ... 

Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -