Skip to content

Instantly share code, notes, and snippets.

@corasaurus-hex
Last active July 5, 2025 07:30
Show Gist options
  • Select an option

  • Save corasaurus-hex/a6a4b47acd047e4def359931b5714a2b to your computer and use it in GitHub Desktop.

Select an option

Save corasaurus-hex/a6a4b47acd047e4def359931b5714a2b to your computer and use it in GitHub Desktop.
use datafusion::{execution::options::ArrowReadOptions, prelude::*};
#[tokio::main]
async fn main() {
let ctx = SessionContext::new();
ctx.register_arrow("my_table", "file.arrow", ArrowReadOptions::default())
.await
.unwrap();
ctx.sql("SELECT * FROM my_table LIMIT 10")
.await
.unwrap()
.show()
.await
.unwrap();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment