oreacle 中 select adjust_date as actime adjust_person as person from uf_adjust_history where adjust_person in + userid1 + 根据 actime 时间取最新的一条
您可以使用以下SQL语句来实现您的需求:
SELECT adjust_date AS actime, adjust_person AS person
FROM uf_adjust_history
WHERE adjust_person IN (" + userid1 + ")
ORDER BY actime DESC
LIMIT 1
这个查询会根据 actime 字段的降序排列结果,并且使用 LIMIT 1 限制结果只返回一条记录,即最新的一条记录。
原文地址: https://www.cveoy.top/t/topic/iheQ 著作权归作者所有。请勿转载和采集!