tmthyjames / SQLCell

SQLCell is a magic function for the Jupyter Notebook that executes raw, parallel, parameterized SQL queries with the ability to accept Python values as parameters and assign output data to Python variables while concurrently running Python code. And *much* more.
MIT License
150 stars 11 forks source link

check types before creating UPDATE statement #48

Open tmthyjames opened 7 years ago

tmthyjames commented 7 years ago

Check for types for quote injection into UPDATE statement.

(ProgrammingError) column "phteam" does not exist
LINE 1: ...E branding SET host_name = 'local' WHERE brand_name = PHTEAM
^
"UPDATE branding SET host_name = 'local' WHERE brand_name = PHTEAM" {}

PHTEAM here should be in quotes.