数据湖探索 DLI-去重:示例

时间:2024-12-27 10:34:29

示例

根据order_id对数据进行去重,其中proctime为事件时间属性列

SELECT order_id, user, product, number
  FROM (
     SELECT *,
         ROW_NUMBER() OVER (PARTITION BY order_id ORDER BY proctime ASC) as row_num
     FROM Orders)
  WHERE row_num = 1;
support.huaweicloud.com/sqlref-flink-dli/dli_08_0328.html