JohnOmernik / sqlalchemy-drill

Apache Drill Dialect for SQL Alchemy
Other
53 stars 35 forks source link

substitute_in_query method doesn't working fine #86

Open Maegor opened 1 year ago

Maegor commented 1 year ago

The "substitute_in_query" method should substitute parameters in SQL queries but it does not. The problem seems to be in line 36 of the _drillapi.py file: "query.replace('?', param, 1)" . The replace method returns a new string, it does not modify the original one. This causes the method to return the original query, without modifying the original string.

sqlalchemy-drill version is 1.1.2