MCPcopy Create free account
hub / github.com/apache/datafusion / exec_from_commands

Function exec_from_commands

datafusion-cli/src/exec.rs:54–64  ·  view source on GitHub ↗

run and execute SQL statements and commands, against a context with the given print options

(
    ctx: &dyn CliSessionContext,
    commands: Vec<String>,
    print_options: &PrintOptions,
)

Source from the content-addressed store, hash-verified

52
53/// run and execute SQL statements and commands, against a context with the given print options
54pub async fn exec_from_commands(
55 ctx: &dyn CliSessionContext,
56 commands: Vec<String>,
57 print_options: &PrintOptions,
58) -> Result<()> {
59 for sql in commands {
60 exec_and_print(ctx, print_options, sql).await?;
61 }
62
63 Ok(())
64}
65
66/// run and execute SQL statements and commands from a file, against a context with the given print options
67pub async fn exec_from_lines(

Callers 1

main_innerFunction · 0.85

Calls 1

exec_and_printFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…