MCPcopy
hub / github.com/spaceandtimefdn/SxT-Python-SDK / execute_query

Method execute_query

src/spaceandtime/sxtuser.py:494–507  ·  view source on GitHub ↗

Execute a SQL query, returning success flag and data. Can be DQL, DML, or DDL. Args: sql_text (str): SQL text to execute. biscuits (list): List of biscuits required to authorize this request. app_name (str): Name of the application making

(self, sql_text:str, biscuits:list = None, app_name:str = None)

Source from the content-addressed store, hash-verified

492
493
494 def execute_query(self, sql_text:str, biscuits:list = None, app_name:str = None):
495 """
496 Execute a SQL query, returning success flag and data. Can be DQL, DML, or DDL.
497
498 Args:
499 sql_text (str): SQL text to execute.
500 biscuits (list): List of biscuits required to authorize this request.
501 app_name (str): Name of the application making the request.
502
503 Returns:
504 bool: Success flag (True/False) indicating the call worked as expected.
505 list: Data (as list of dicts) if successful, otherwise an error object.
506 """
507 return self.base_api.sql_exec(sql_text=sql_text, biscuits=biscuits, app_name=app_name)
508
509
510 def execute_zkproven_query(self, sql_text:str, biscuits:list = None):

Callers 3

execute_sqlMethod · 0.95
test_sxt_userFunction · 0.95
test_sxt_user_2Function · 0.95

Calls 1

sql_execMethod · 0.80

Tested by 2

test_sxt_userFunction · 0.76
test_sxt_user_2Function · 0.76