Skip to content
New issue

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

Documentation & Jupyter notebook support? #27

Open
jvanveen opened this issue Dec 3, 2024 · 2 comments
Open

Documentation & Jupyter notebook support? #27

jvanveen opened this issue Dec 3, 2024 · 2 comments

Comments

@jvanveen
Copy link

jvanveen commented Dec 3, 2024

Hi,

Thanks for creating BemiDB. Very interesting solution for analytics! I was wondering whether there is some documentation on how to connect to it, besides using the psql client. My use-case is that I would like to have access to BemiDB from a PretzelAI notebook, using psycopg2 to connect to BemiDB. However, when I try to connect, it returns a warning/error:

 Unsupported SET  datestyle : kind:VAR_SET_VALUE name:"datestyle" args:{a_const:{sval:{sval:"ISO"} location:17}}

Any idea what I'm doing wrong, or is that client not supported yet? Seems to be related to #21?

@arjunlol
Copy link
Member

arjunlol commented Dec 5, 2024

Thanks for submitting this issue, @jvanveen! We'll be testing and ensuring that this gets supported. While it is related to #21, the fix here will involve different queries that need to be supported. You're not doing anything wrong—this is just a compatibility gap we’ll address.

@jvanveen
Copy link
Author

Just FYI; when I try a different psql driver (asyncpg), I get a different kind of error:

import asyncio
import asyncpg

async def main():
    conn = await asyncpg.connect('postgresql://[email protected]:54321/bemidb')
    tables = await conn.fetchval("SELECT COUNT(*) FROM item")
    print(f"Tables:\n {tables}")
    await conn.close()

asyncio.run(main())
2024/12/12 10:55:26 [INFO] BemiDB: Accepted connection from 127.0.0.1:43566
2024/12/12 10:55:26 [ERROR] Statement mismatch: __asyncpg_stmt_1__ instead of SELECT count(*) FROM item

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants