def _escape(s):
    e = s
    e = e.replace('\\', '\\\\')
    e = e.replace('\n', '\\n')
    e = e.replace('\r', '\\r')
    e = e.replace("'", "\\'")
    e = e.replace('"', '\\"')
    return e
Helper method that escapes parameters to a SQL query.
dataset/ETHPy150Open airbnb/airflow/airflow/contrib/hooks/bigquery_hook.py/_escape