(self, file: StrOrBytesPath, progress=noop)
| 61 | progress(len(df)) |
| 62 | |
| 63 | def to_json(self, file: StrOrBytesPath, progress=noop): # noqa: ARG002 |
| 64 | import pandas as pd |
| 65 | |
| 66 | df = pd.read_sql(self.sql, self.con) |
| 67 | with atomic_file(file) as f: |
| 68 | df.to_json(f, orient="records") |
| 69 | |
| 70 | def export(self, file: StrOrBytesPath, format: str = "csv", progress=noop): # noqa: A002 |
| 71 | if format == "json": |