Milesian111 commented on code in PR #29033:
URL: https://github.com/apache/flink/pull/29033#discussion_r3889921546


##########
flink-python/pyflink/dataframe/dataframe.py:
##########
@@ -542,6 +542,85 @@ def drop_duplicates(
     distinct = drop_duplicates
     unique = drop_duplicates
 
+    # ======================== Slicing ========================
+
+    @PublicEvolving()
+    def limit(self, n: int) -> "DataFrame":
+        """
+        Keep at most the first ``n`` rows.
+
+        This is a lazy transformation. Row order is deterministic only when 
the underlying table
+        has an explicit ordering.

Review Comment:
   I have pushed a follow-up commit that clarifies the lazy transformation
   semantics and the ordering behavior for limit, offset, and head.
   
   Sorting support remains tracked separately by FLINK-40421, so I did not add a
   separate DataFrame.order_by() API to this PR.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to