连续重复值选最后一个记录

连续重复值,选最后一个记录,用什么语句

请先 登录 后评论

1 个回答

peter
n=10
id=stretch(`a`b`c, n)
val=stretch(7 8 9, n)
t=table(id, val)

select * from t context by id limit -1

select * from t context by id having isDuplicated(val, LAST)=0

参考上述代码,可以用context by + limit -1 OR isDuplicated去重 

请先 登录 后评论
  • 1 关注
  • 0 收藏,392 浏览
  • wfHuang 提出于 2023-10-13 09:37

相似问题