Comments (4)
Possibly related: #7871
from arrow-datafusion.
Possibly related: #7871
@alamb Thank you for the reply!
I've read discussion in #7871 and think that this case is different.
I don't want to say that MySourceExec can do sort better than DF does.
I'd like to tell to MySourceExec how it should be load an external batches of data: from the beginning or from the tail (in reverse order).
How can I do that without knowing about sorting?
from arrow-datafusion.
It the example TableProvider may know that it needed to provide only last record batch (or the latest parquet file from folder).
The provider can tell DataFusion it produces data in some pre-existing order via
https://docs.rs/datafusion/latest/datafusion/physical_plan/trait.ExecutionPlan.html#tymethod.properties
which can then communicate the sortedness via https://docs.rs/datafusion/latest/datafusion/physical_plan/struct.PlanProperties.html#method.output_ordering
However, that usecase is for data that is already always sorted. It doesn't permit DataFusion to say "I won't use the sort order you reported so you don't have to honor the contract" 🤔
from arrow-datafusion.
(BTW @NGA-TRAN and I worked on a very similar feature in InfluxDB IOx -- and we implemented a special operator that knows how to do this "read only the most recent file" for queries very much like your example above
SELECT * FROM Events
ORDER BE event_time DESC
LIMIT 1000
There is additional discussion / links on #10313
I think we would be interested in collaborating / pushing some of this logic upstream to datafusion. @matthewmturner and @suremarc may also be interested
from arrow-datafusion.
Related Issues (20)
- Move optimizer rule that has aggregate function out of core HOT 3
- Apply guarantee rewriter to sql workflow HOT 8
- Add to_date function to scalar functions doc
- Add to_unixtime function to scalar functions doc
- bug: `CAST(<array>)` causes internal error HOT 3
- Implement `LogicalPlanBuilder::from` for `Arc<LogicalPlan>` HOT 5
- to_date with a date string and format fails with error parsing timestamp
- Docker CLI build fails in WSL2 - "Ubuntu 22.04.4 LTS"
- Seperate out common types from Datafusion Proto HOT 1
- Connection reset by peer on AWS S3 object store. HOT 3
- Document committer / PMC process
- Create presentation for DataFusion SIGMOD 2024 paper
- Keynote presentation for SiMoD workshop at SIGMOD 2024 HOT 3
- DataFusion weekly project plan (Andrew Lamb) - May 13, 2024 HOT 1
- Convert internal representation of LogicalPlanBuilder from `LogicalPlan` to `Arc<LogicalPlan>` HOT 3
- [Regression] Query using ARRAY_AGG(DISTINCT) causes panic HOT 5
- Add `ProgressiveEval` operator for optimize `SortPreservingMerge` HOT 3
- SortMergeJoin: The query stuck when join filter is set and more matched rows than batch size
- API to get all `Column` references in an `Expr` without cloning `Columns`
- Strengthen TypeSignature and Coercion rule.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arrow-datafusion.