DuckDB: load multiple remote parquet files dinamically

Hi! Pretty new to Observable and JavaScript!
I’m trying to load multiple parquet files hosted on Github dinamically in a single table in a DuckDB instance. I’m following DuckDB’s documentation, using list parameter:

-- use list parameter to read 3 parquet files and treat them as a single table
SELECT * FROM read_parquet(['file1.parquet', 'file2.parquet', 'file3.parquet']);
dataFiles = array of urls
dataList = JSON.stringify(dataFiles)
db = DuckDBClient.of()
db.query(`CREATE TABLE data AS SELECT * FROM read_parquet(${dataList});`)

I’m getting the following error: “Error: Binder Error: TABLE FUNCTION parameter cannot contain column names”

If I remove the read_parquet command and keep only a single url it works. using read_parquet even with a single url gets me the same error.

How should I proceed to load multiple files in a single table?

Have a look at this example for a wrapper that you can import into your notebook:

However, this example might be closer to what you’re looking for:

Thank you! The second link solved it. And I had to change the double quotes to single quotes inside the SQL statement.