Skip to content

Commit ba72da0

Browse files
committed
More timings
1 parent ddc2940 commit ba72da0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/databricks/sql/client.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1408,8 +1408,12 @@ def _convert_arrow_table(self, table: "pyarrow.Table"):
14081408
ResultRow = Row(*column_names)
14091409

14101410
if self.connection.disable_pandas is True:
1411+
start_time = time.time()
14111412
columns_as_lists = [col.to_pylist() for col in table.itercolumns()]
1412-
return [ResultRow(*row) for row in zip(*columns_as_lists)]
1413+
res = [ResultRow(*row) for row in zip(*columns_as_lists)]
1414+
end_time = time.time()
1415+
print(f"Time taken to convert arrow table to list: {end_time - start_time} seconds")
1416+
return res
14131417

14141418
# Need to use nullable types, as otherwise type can change when there are missing values.
14151419
# See https://arrow.apache.org/docs/python/pandas.html#nullable-types

0 commit comments

Comments
 (0)