-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Labels
bugSomething isn't workingSomething isn't workingpythonPull requests for the Python Semantic KernelPull requests for the Python Semantic Kerneltriage
Description
The Postgres connector's lambda-to-SQL flow builds predicate strings but then inserts them into queries in a way that treats them as SQL literals (quoted strings) rather than expressions. This results in queries like WHERE '"content_type" = 'course'' which Postgres rejects as an invalid boolean. The fix is to pass parsed clauses into psycopg.sql as sql.SQL(...)/sql.Composed objects (or better: return parameterized clauses + params). I'm attaching a small patch that converts where_clauses to sql.SQL before formatting; I'd be happy to open a PR that returns parameterized clauses and params for safer construction.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingpythonPull requests for the Python Semantic KernelPull requests for the Python Semantic Kerneltriage