MrCalen/Typeorm-Log-To-SQL

JSON objects in params are converted to '[object Object]'

Closed this issue · 0 comments

When trying to transform the following query:

SELECT $1::json ->> 'key-a';
 -- PARAMETERS: [{"key-a":"hello"}]

I get the following result:

SELECT  '[object Object]' ::json ->> 'key-a';

I think it could be better if we can have the following:

SELECT  '{"key-a":"hello"}' ::json ->> 'key-a';