mkleen commented on code in PR #18298:
URL: https://github.com/apache/datafusion/pull/18298#discussion_r2465670378


##########
datafusion/functions-table/src/generate_series.rs:
##########
@@ -396,7 +401,11 @@ impl<T: SeriesValue> LazyBatchGenerator for 
GenericSeriesState<T> {
 
         let array = self.current.create_array(buf)?;
         let batch = RecordBatch::try_new(Arc::clone(&self.schema), 
vec![array])?;
-        Ok(Some(batch))
+        let projected = match self.projection.as_ref() {

Review Comment:
   I noticed that the `MemoryStream` projects in 
https://github.com/apache/datafusion/blob/main/datafusion/physical-plan/src/memory.rs#L103
 while the `LazyMemoryStream` used in `generate_series` doesn't. An alternative 
approach could be to project generically in the `LazyMemoryStream` instead 
inside of the generator.



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