1
0
mirror of synced 2026-09-12 21:35:02 +00:00
Files
discourse-data-explorer/spec
Alan Guo Xiang Tan 4236689d27 FIX: Errors when running query due to PG template patterns or comments (#189)
Before this fix, the use of PG template patterns containing ":" or the
use of "?" in comments in the SQL will result in an error being raised
because `DB.param_encoder.encode` calls ActiveRecord's `sanitize_sql_array` which is
meant for SQL fragments and not an entire SQL string.

Instead we change data-explorer to use `MiniSql::InlineParamEncoder`
instead which takes into account of template patterns and does not trip
on `?` which is a special param encoding character used by ActiveRecord.
2022-10-10 09:03:37 +08:00
..
2022-10-03 22:20:04 +02:00
2022-10-03 22:20:04 +02:00