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
If I use a bindparam in my view definition, it does not appear to be bound when creating the view. Is there a way to pass through bindparams?
>>> import sqlalchemy as sa >>> from sqlalchemy_views import CreateView >>> engine = sa.create_engine("postgresql:///?service=devrds") >>> table = sa.Table("my_table", sa.MetaData(), sa.Column("col", sa.String(100), nullable=True)) >>> view = sa.table("my_view") >>> definition = table.select().where(table.c.col == sa.bindparam("colval")) >>> create_view = CreateView(view, definition) >>> table.create(engine) >>> engine.execute(create_view, colval="test") /site/venv/lib/python3.8/site-packages/sqlalchemy_views/views.py:72: SAWarning: Bound parameter 'colval' rendering literal NULL in a SQL expression; comparisons to NULL should not use operators outside of 'is' or 'is not' (this warning may be suppressed after 10 occurrences) text += "AS %s\n\n" % compiler.sql_compiler.process(create.selectable, <sqlalchemy.engine.cursor.LegacyCursorResult object at 0x7fdfcd4545b0>
The text was updated successfully, but these errors were encountered:
No branches or pull requests
If I use a bindparam in my view definition, it does not appear to be bound when creating the view. Is there a way to pass through bindparams?
The text was updated successfully, but these errors were encountered: