Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
抱歉,如果有人问过这个但找不到任何东西。我有一个有两个纪元时间戳的表(一个是会话开始,另一个是会话结束),我想查找变量是否位于 x 列和 y 列之间。我用 between 来查看列是否在两个变量之间,但真的想不出其他方式的语法。
为任何帮助而欢呼
BETWEEN应该适用于时间戳。但是,MySQL 中还有一些其他的日期函数应该会有所帮助。查看UNIX_TIMESTAMP()
BETWEEN
UNIX_TIMESTAMP()