Skip to content

Commit ed0f73b

Browse files
committed
Fixed the async issue
1 parent 74585f3 commit ed0f73b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/databricks/sql/thrift_backend.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -898,8 +898,10 @@ def execute_command(
898898
sessionHandle=session_handle,
899899
statement=operation,
900900
runAsync=True,
901+
# For async operation we don't want the direct results
901902
getDirectResults=ttypes.TSparkGetDirectResults(
902-
maxRows=max_rows, maxBytes=max_bytes
903+
maxRows=0 if async_op else max_rows,
904+
maxBytes=0 if async_op else max_bytes,
903905
),
904906
canReadArrowResult=True if pyarrow else False,
905907
canDecompressLZ4Result=lz4_compression,

0 commit comments

Comments
 (0)