开发者

MySQL epoch time between two column epochs

开发者 https://www.devze.com 2023-01-20 13:40 出处:网络
Sorry if this has been ask开发者_如何转开发ed but can\'t find anything. I have a table that has two epoch timestamps (one is start of a session, other is end of a session), I want to find if a variabl

Sorry if this has been ask开发者_如何转开发ed but can't find anything. I have a table that has two epoch timestamps (one is start of a session, other is end of a session), I want to find if a variable is in between column x and column y. I've used between to see if a column is between two variables but can't really think of the syntax for the other way.

Cheers for any help


BETWEEN should work for timestamps. However, there are a handful of other date functions in MySQL that should be helpful. Check out UNIX_TIMESTAMP()

0

精彩评论

暂无评论...
验证码 换一张
取 消