Closed
Description
If I use the format
function on a query that contains a literal ?
this gets replaced, as per the documentation. How can I escape the ?
character so it doesn't get replaced?
const { format } = require('sqlstring')
format(`select * from mytable where foo = 'https://example.com?a=b' and bar = ?`, ['xyz'])
The resulting output from this would be
select * from mytable where foo = 'https://example.com'xyz'a=b' and bar = ?
whereas I want
select * from mytable where foo = 'https://example.com?a=b' and bar = 'xyz'