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
Postgres querybuilder #315
Comments
Looks like the issue is that it is compiling as |
Should just be a fix inside the |
@girardinsamuel thoughts? |
@josephmancuso I've searched in QueryBuilder class and I didn't found... Shouldn't we implement in which schema the table should be applied? like: qb = QueryBuilder(schema="information_schema").table("columns") or should we split the content ( "information_schema.tables" ) by dot and apply into select_format method.. |
@egwald this is fixed in version 1.0.5 |
Hi, I use masonite3 with the new ORM with PostgreSQL 13.1 on x86_64-pc-linux-musl, compiled by gcc (Alpine 9.3.0) 9.3.0, 64-bit.
Now I try:
and the I have the error:
#1 ..lNG/venv/lib/python3.9/site-packages/masoniteorm/connections/PostgresConnection.py:162
if "SELECT" in cursor.statusmessage:
return cursor.fetchall()
return {}
except Exception as e:
raise QueryException(str(e)) from e
finally:
if self.get_transaction_level() <= 0:
self.open = 0
self._connection.close()
')
Python
self <masoniteorm.connections.PostgresConnection.PostgresConnection object at 0x7f3097829be0>
query 'SELECT "information_schema.columns"."table_name", "information_schema.columns"."column_name", "information_schema.columns"."is_nullable", "information_schema.columns"."data_type",
"information_schema.columns"."character_maximum_length" FROM "information_schema.columns" WHERE "information_schema.columns"."table_name" = %s ORDER BY "information_schema.columns"."column_name" DESC'
bindings ('users',)
results '*'
RealDictCursor <class 'psycopg2.extras.RealDictCursor'>
cursor <cursor object at 0x7f309a66de40; closed: -1>
QueryException('relation "information_schema.columns" does not exist\nLINE 1: ...n_schema.columns"."character_maximum_length" FROM "informati...\n ^\n')
Can you help me?
This works fine:
The text was updated successfully, but these errors were encountered: