Closed vitaly-t closed 6 years ago
Rolled this into the driver upgrade commit, thanks!
A, finally! :smile:
@dmfay As I revisited this with this question: https://github.com/vitaly-t/pg-promise/issues/563
I would say that the following approach is better:
const rawSQL = pgp.as.format(script.sql);
The formatting method knows internally how to deal with all types that support Custom Type Formatting (both explicit
and symbolic
syntax), and QueryFile
is just one such type.
This change will be needed, if you eventually get to upgrade
pg-promise
to v7.1.0 or later. That version brought it some changes that are non-breaking for any client, but for your integration this change will be needed.So, do not accept this PR before you upgrade
pg-promise
to v7.1.0 or later! :wink: