We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am encountering the following error when trying to open a .db file with READ_WRITE access mode.
READ_WRITE
Error: Opening file test.db failed: cannot open file with both read and write flags set
Is this expected behaviour? I couldn't find any documentation talking about the limitations of the access mode.
import * as duckdb from '@duckdb/duckdb-wasm'; const JSDELIVR_BUNDLES = duckdb.getJsDelivrBundles(); const bundle = await duckdb.selectBundle(JSDELIVR_BUNDLES); const worker_url = URL.createObjectURL( new Blob([`importScripts("${bundle.mainWorker!}");`], {type: 'text/javascript'}) ); const worker = new Worker(worker_url); const logger = new duckdb.ConsoleLogger(); const db = new duckdb.AsyncDuckDB(logger, worker); await db.instantiate(bundle.mainModule, bundle.pthreadWorker); await db.registerFileURL('test.db', 'http://localhost:3000/data/test.db', duckdb.DuckDBDataProtocol.HTTP, true ) await db.open({path: 'test.db', accessMode: duckdb.DuckDBAccessMode.READ_WRITE }) URL.revokeObjectURL(worker_url); const connection = await db.connect(); await connection.query(` INSTALL spatial; INSTALL json; LOAD spatial; LOAD json; `); connection.close();
Chrome 132
MacOS (M2)
1.29.0
Local development
Sparsh Kumar
Nika
The text was updated successfully, but these errors were encountered:
No branches or pull requests
What happens?
I am encountering the following error when trying to open a .db file with
READ_WRITE
access mode.Error: Opening file test.db failed: cannot open file with both read and write flags set
Is this expected behaviour? I couldn't find any documentation talking about the limitations of the access mode.
To Reproduce
Browser/Environment:
Chrome 132
Device:
MacOS (M2)
DuckDB-Wasm Version:
1.29.0
DuckDB-Wasm Deployment:
Local development
Full Name:
Sparsh Kumar
Affiliation:
Nika
The text was updated successfully, but these errors were encountered: