-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
We hear a lot about duck db these days, and people say it is fast. Let's provide some examples of using duck db.
https://duckdb.org/2021/05/14/sql-on-pandas
TL;DR: DuckDB, a free and open source analytical data management system, can efficiently run SQL queries directly on Pandas DataFrames.
AI generated example:
import pandas as pd
import duckdb
df = pd.DataFrame({'A': [1, 2, 3], 'B': [4, 5, 6]})
# Connect to DuckDB and run an SQL query directly on the DataFrame
duckdb_result = duckdb.query("SELECT A, AVG(B) as avg_b FROM df WHERE A > 1 GROUP BY A").to_df()
print(duckdb_result)
Metadata
Metadata
Assignees
Labels
No labels