File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -200,7 +200,13 @@ def _copy(
200200
201201 logging .info (f"Starting copy into `{ self .fqn } ` from path '{ path } '" )
202202 return execute (
203- query .format (file_format = self .file_format , from_clause = from_clause )
203+ query .format (
204+ file_format = self .file_format ,
205+ from_clause = from_clause ,
206+ storage_integration_clause = f"STORAGE_INTEGRATION = { storage_integration } "
207+ if storage_integration and not (stage or self ._stage )
208+ else "" ,
209+ )
204210 )
205211
206212 def copy_into (
@@ -230,7 +236,7 @@ def copy_into(
230236 copy_query = f"""
231237 COPY INTO { self .fqn } { col_str }
232238 FROM {{from_clause}}
233- { f"STORAGE_INTEGRATION = { storage_integration } " if storage_integration and not ( stage or self . _stage ) else "" }
239+ {{storage_integration_clause} }
234240 FILE_FORMAT = ( FORMAT_NAME ='{{file_format}}')
235241 MATCH_BY_COLUMN_NAME={ match_by_column_name .value }
236242 { files_clause }
You can’t perform that action at this time.
0 commit comments