Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SHOW ALL TABLES; Query causes INTERNAL Error: MySQLResult::Next called without result #94

Open
2 tasks done
JayJamieson opened this issue Oct 30, 2024 · 0 comments
Open
2 tasks done

Comments

@JayJamieson
Copy link

What happens?

Loaded mysql extension per documentation, attached and set mysql_debug_show_queries=true. Ran the SHOW ALL TABLES; query and error occurred. As per below.

v1.1.2 f680b7d08f
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
D load mysql;
D attach 'host=localhost user=root password=password port=3306 database=multi_tenant' as mysqldb (type MYSQL);
D use mysqldb;
D set mysql_debug_show_queries=true;
D SHOW ALL TABLES;
SET character_set_results = 'utf8mb4';

SET character_set_results = 'utf8mb4';

START TRANSACTION


SELECT table_name, column_name, data_type, column_type, column_default, is_nullable, numeric_precision, numeric_scale
FROM information_schema.columns
WHERE table_schema='multi_tenant'
ORDER BY table_name, ordinal_position;


ROLLBACK

INTERNAL Error: MySQLResult::Next called without result
This error signals an assertion failure within DuckDB. This usually occurs due to unexpected conditions or errors in the program's logic.
For more information, see https://duckdb.org/docs/dev/internal_errors

To Reproduce

Run mysql with following docker compose configuration:

version: '3'
services:
  db:
    image: mysql:8
    restart: always
    ports:
      - 3306:3306
    environment:
      MYSQL_DATABASE: multi_tenant
      MYSQL_ROOT_PASSWORD: password

Start DuckDB CLI shell and run following commands in order

install mysql; # skip if already installed?
load mysql;
attach 'host=localhost user=root password=password port=3306 database=multi_tenant' as mysqldb (type MYSQL);
use mysqldb;
set mysql_debug_show_queries=true;
SHOW ALL TABLES;

Observe SHOW ALL TABLES; causes INTERNAL Error: MySQLResult::Next called without result

OS:

Linux silver-slab 5.15.153.1-microsoft-standard-WSL2 #1 SMP Fri Mar 29 23:14:13 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

MySQL Version:

8

DuckDB Version:

v1.1.2 f680b7d08f

DuckDB Client:

CLI

Full Name:

Jay Jamieson

Affiliation:

None

Have you tried this on the latest main branch?

  • I agree

Have you tried the steps to reproduce? Do they include all relevant data and configuration? Does the issue you report still appear there?

  • I agree
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant