首页 > 代码库 > 时间序列排序选择

时间序列排序选择

用in失败,可以用inner join代替。

use solardb;
select * from data as v
inner join
(
select distinct Timestamp from data order by unix_timestamp(str_to_date(Timestamp,"%d.%m.%Y %H:%i")) desc limit 10) as v2
on v.Timestamp = v2.Timestamp;

时间序列排序选择