Skip to content

Conversation

@jc4x4
Copy link
Contributor

@jc4x4 jc4x4 commented Aug 16, 2024

#7306

Which issue does this PR close?

Closes #7306.

Rationale for this change

New user doc for translating logical plan to physical plan

What changes are included in this PR?

  • doc change
  • sample rust code
  • tokio dependency to support async create_physical_plan

Are these changes tested?

Run test and pasted output into md.

Are there any user-facing changes?

Only doc

@github-actions github-actions bot added the documentation Improvements or additions to documentation label Aug 16, 2024
@jc4x4 jc4x4 requested a review from edmondop August 16, 2024 22:13
@alamb
Copy link
Contributor

alamb commented Aug 18, 2024

Thank you for this PR @jc4x4 and @edmondop -- I plan to review / help with it early next week

Ok(())
}

#[tokio::test]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is confusing -- i don't think it is used anymore --- I added #12081 to remove it

TableScan: person [id:Int32;N, name:Utf8;N]
```

## Translating Logical Plan to Physical Plan
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @jc4x4 -- I have some ideas on improving this example -- I will push some suggestions to this branch

library_user_guide_sql_api
);

#[cfg(doctest)]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added this block which means the examples in the library guide are now run as part of cargo test --doc


// print the plan
println!("{}", plan.display_indent_schema());
use datafusion::common::DataFusionError;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated these examples so they compile as standalone examples

Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much @jc4x4 -- I hope you don't mind I pushed several commits to your branch to get the examples compiling and running. Your PR showed there were some issues with our current testing methodology.

@github-actions github-actions bot added logical-expr Logical plan and expressions core Core DataFusion crate labels Aug 20, 2024
@jc4x4
Copy link
Contributor Author

jc4x4 commented Aug 20, 2024

Thank you very much @jc4x4 -- I hope you don't mind I pushed several commits to your branch to get the examples compiling and running. Your PR showed there were some issues with our current testing methodology.

I dont mind at all. Thanks for improving it. Let me know if I need to do anything on my end.

@alamb
Copy link
Contributor

alamb commented Aug 21, 2024

Thanks again @jc4x4 and @edmondop

@alamb alamb merged commit 78f58c8 into apache:main Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Core DataFusion crate documentation Improvements or additions to documentation logical-expr Logical plan and expressions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Library Guide: Building LogicalPlans

3 participants