Skip to content

Commit

Permalink
Add missing semicolons when printing or writing SQL to file
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyMcCormick committed Jan 27, 2025
1 parent af32d12 commit 14acedd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/felis/tap_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -573,15 +573,15 @@ def _compiled_inserts(self) -> list[str]:
def _print_sql(self) -> None:
"""Print the generated inserts to stdout."""
for insert_str in self._compiled_inserts():
print(insert_str)
print(insert_str + ";")

def _write_sql_to_file(self) -> None:
"""Write the generated insert statements to a file."""
if not self.output_path:
raise ValueError("No output path specified")
with open(self.output_path, "w") as outfile:
for insert_str in self._compiled_inserts():
outfile.write(insert_str + "\n")
outfile.write(insert_str + ";" + "\n")

def _insert(self, table_name: str, record: list[Any] | dict[str, Any]) -> None:
"""Generate an insert statement for a record.
Expand Down

0 comments on commit 14acedd

Please sign in to comment.