Files
email-tracker/external/duckdb/test/sql/json/issues/issue6722.test
2025-10-24 19:21:19 -05:00

24 lines
699 B
SQL

# name: test/sql/json/issues/issue6722.test
# description: Test issue 6722 - INTERNAL Error: read_json_auto and read_json(auto_detect=true) fail to handle property name case sensitivities
# group: [issues]
require json
statement ok
PRAGMA enable_verification
# this file has 4 columns, name "id", "Id", "iD", and "ID"
query IIII
FROM 'data/json/duplicate_column_names.json'
----
42 43 44 45
# due to case-insensitivity these column names would cause an error, but we add a number to de-duplicate them
query IIIIII
DESCRIBE FROM 'data/json/duplicate_column_names.json'
----
id BIGINT YES NULL NULL NULL
Id_1 BIGINT YES NULL NULL NULL
iD_2 BIGINT YES NULL NULL NULL
ID_3 BIGINT YES NULL NULL NULL