renato2099 commented on code in PR #1492:
URL: 
https://github.com/apache/datafusion-python/pull/1492#discussion_r3075222068


##########
crates/core/src/dataframe.rs:
##########
@@ -707,7 +707,15 @@ impl PyDataFrame {
     /// Print the result, 20 lines by default
     #[pyo3(signature = (num=20))]
     fn show(&self, py: Python, num: usize) -> PyDataFusionResult<()> {
-        let df = self.df.as_ref().clone().limit(0, Some(num))?;
+        let mut df = self.df.as_ref().clone();
+        df = match self.df.logical_plan() {
+            LogicalPlan::Explain(_) | LogicalPlan::Analyze(_) => {
+                // Explain and Analyzer require they are at the top
+                // of the plan, so do not add a limit.

Review Comment:
   👍 



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to