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

Support Informix nested Structs #16038

Open
lukaseder opened this issue Apr 1, 2022 · 1 comment
Open

Support Informix nested Structs #16038

lukaseder opened this issue Apr 1, 2022 · 1 comment

Comments

@lukaseder
Copy link

System information:

  • Operating system (distribution) and version: Microsoft Windows [Version 10.0.22000.556]
  • DBeaver version: Version 21.3.2.202112271055
  • Java version: openjdk version "17" 2021-09-14 (build 17+35-2724)

Connection specification:

  • Database name and version: IBM Informix Dynamic Server Version 14.10.FC5DE
  • Driver name: com.informix.jdbc.IfxDriver
  • Do you use tunnels or proxies (SSH, SOCKS, etc)? No

Describe the problem you're observing:

When projecting nested rows and nested collections of rows, the result is just a IfxStruct.toString() rendition which describes the data structure's metadata, not the data contents

Steps to reproduce, if exist:

select 
  row(1, 2) as a, 
  row(1, row(1, 2)) as b, 
  multiset { 1, 2 } as c,
  multiset { row(1, 2) } as d;

The output is:

image

As you can see:

  • a is split up correctly into its components
  • b doesn't correctly show the nested row
  • c seems to format some reasonable output (not sure if by accident)
  • d doesn't show anything useful

The problem is that as soon as java.sql.Struct types are nested, the formatting stops working

PostgreSQL doesn't have this problem, because PostgreSQL produces a string representation of the data structure, which is reasonable enough as a result:

select 
  row(1, 2) as a, 
  row(1, row(1, 2)) as b, 
  array [ 1, 2 ] as c,
  array [ row(1, 2) ] as d;

Resulting in

image

I still like it better when Dbeaver creates separate columns for nested data structures, but if that's too complex, then some reasonable string representation of a Struct would do as well.

@LonwoLonwo
Copy link
Member

Thanks for the idea and for the investigation @lukaseder

@emironovDB emironovDB modified the milestones: 22.1.1, 22.1.5 May 31, 2022
@emironovDB emironovDB modified the milestones: 22.1.5, 22.2.5 Aug 2, 2022
@tati-kru tati-kru removed this from the 22.2.5 milestone Nov 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants