cwida / duckpgq-extension

DuckDB extension that adds support for SQL/PGQ
https://duckpgq.notion.site/b8ac652667964f958bfada1c3e53f1bb?v=3b47a8d44bdf4e0c8b503bf23f1b76f2
MIT License
69 stars 7 forks source link

Replacement scan for creating and querying SQL/PGQ graphs #21

Closed Dtenwolde closed 8 months ago

Dtenwolde commented 1 year ago

What happens?

The following query does not work:

import pandas as pd
import duckdb
df = pd.DataFrame([1,2,3,4,5])
df2 = pd.DataFrame([[0,1], [1,2], [2,3]])
con = duckdb.connect('')
con.execute('load sqlpgq')
con.execute("""CREATE PROPERTY GRAPH pg VERTEX TABLES ( df LABEL person ) EDGE TABLES ( df2 SOURCE KEY (i) REFERENCES df (j) DESTINATION KEY (i) REFERENCES df (j) LABEL knows);""")

We could add a feature that allows the creation of property graphs from a TableFunction, but we need to add support for the table replacement scan

To Reproduce

See above

OS:

macOs 13 - Apple M1 Pro

DuckDB Version:

latest

DuckDB Client:

python

Full Name:

Daniel ten Wolde

Affiliation:

CWI

Have you tried this on the latest master branch?

Have you tried the steps to reproduce? Do they include all relevant data and configuration? Does the issue you report still appear there?

Dtenwolde commented 8 months ago

Closed as this has been implemented