@@ -86,6 +86,33 @@ def execute_command(
8686 async_op : bool ,
8787 enforce_embedded_schema_correctness : bool ,
8888 ) -> Union ["ResultSet" , None ]:
89+ """
90+ Executes a SQL command or query within the specified session.
91+ This method sends a SQL command to the server for execution and handles
92+ the response. It can operate in both synchronous and asynchronous modes.
93+
94+ Args:
95+ operation: The SQL command or query to execute
96+ session_id: The session identifier in which to execute the command
97+ max_rows: Maximum number of rows to fetch in a single fetch batch
98+ max_bytes: Maximum number of bytes to fetch in a single fetch batch
99+ lz4_compression: Whether to use LZ4 compression for result data
100+ cursor: The cursor object that will handle the results
101+ use_cloud_fetch: Whether to use cloud fetch for retrieving large result sets
102+ parameters: List of parameters to bind to the query
103+ async_op: Whether to execute the command asynchronously
104+ enforce_embedded_schema_correctness: Whether to enforce schema correctness
105+
106+ Returns:
107+ If async_op is False, returns a ResultSet object containing the
108+ query results and metadata. If async_op is True, returns None and the
109+ results must be fetched later using get_execution_result().
110+
111+ Raises:
112+ ValueError: If the session ID is invalid
113+ OperationalError: If there's an error executing the command
114+ ServerOperationError: If the server encounters an error during execution
115+ """
89116 pass
90117
91118 @abstractmethod
0 commit comments