move-coop / parsons

A python library of connectors for the progressive community.
https://www.parsonsproject.org/
Other
258 stars 128 forks source link

[Feature/Addition] Enable passing parameters to Redshift unload statement #869

Open austinweisgrau opened 1 year ago

austinweisgrau commented 1 year ago

Currently it is not possible to pass parameters to the Redshift.unload() method. This is because of a limitation in Redshift itself. See issue here.

As discussed in the upstream issue, this really should be possible in order to encourage best practices around escaping variables and to avoid SQL injection in unload statements, the same way it is in normal Redshift query statements.

This will not be possible unless either:

Detailed Description

See also https://github.com/sqlalchemy-redshift/sqlalchemy-redshift/issues/215

Context

Possible Implementation

Priority

shaunagm commented 8 months ago

How high a priority is this?

I'd be hesitant to add another use of psycopg2, as that library is single-handedly responsible for something like 75% of installation issues.

austinweisgrau commented 8 months ago

Low priority, probably can close if you want to clean things up honestly.