avm19 opened a new issue, #2035:
URL: https://github.com/apache/arrow-adbc/issues/2035
### What happened?
`executescript()` fails to execute a script if it contains multiple
statements.
Here is the error summary (Python):
> ProgrammingError: INVALID_ARGUMENT: [libpq] Failed to execute query: could
not infer schema: failed to prepare query: ERROR: cannot insert multiple
commands into a prepared statement
>
>Query was:
DROP TABLE IF EXISTS table1;
DROP TABLE IF EXISTS table2;
. SQLSTATE: 42601
### Stack Trace
_No response_
### How can we reproduce the bug?
Python:
```python
script = """
DROP TABLE IF EXISTS table1;
DROP TABLE IF EXISTS table2;
"""
with adbc_driver_postgresql.dbapi.connect(uri) as conn:
with conn.cursor() as cur:
cur.executescript(script)
```
### Environment/Setup
Python 3.11
>pip list | grep adbc
adbc-driver-manager 1.1.0
adbc-driver-postgresql 1.1.0
adbc-driver-sqlite 1.1.0
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]