A
A
AstonMartin2016-02-24 13:40:51
MySQL
AstonMartin, 2016-02-24 13:40:51

SQL query for subtraction?

Hello!
Tell me, plz, on a simple sql query for mysql?
The table has two fields (timestamp) and you need to select rows where one field is 1 more than the other.
It should be something simple, but it doesn't work ;)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
Rsa97, 2016-02-24
@AstonMartin

WHERE `timestamp2` = `timestamp1`+1

A
Aleksej, 2016-02-24
@Shwed_Berlin

...
where (timestamp1-timestamp2) = 1

not knowing MySQL - subtraction operation may be different

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question