This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 207867

Summary: Informix returns string in metadata space padded
Product: db Reporter: matthias42
Component: CodeAssignee: Jiri Rechtacek <jrechtacek>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P3    
Version: 7.1   
Hardware: PC   
OS: Linux   
Issue Type: ENHANCEMENT Exception Reporter:
Attachments: proposed patch

Description matthias42 2012-01-28 11:49:11 UTC
Created attachment 115342 [details]
proposed patch

I noticed, that my informix connections failed to display foreign keys. In my own code I found, that sometimes informix return space padded string in the metadata so basicly I now trim every string returned by metadata. This assumes  that no sane DBMS uses space padding in the "real data". I guard the trimming for null values, which are left unaltered.

Additionally the metadata model makes the assumption, that a DBMS not supporting catalogs in definition statements, also does not allow catalogs in queries. This assumption is wrong. Informix only allows creates in the same catalog, but queries can be cross catalog. I removed the guard in JDBCMetadata and just try to get the catalogs. If this fails it gets logged but we don't do an early exit. Instead the core then falls back to the old "we don't see other catalogs" behaviour.

Together with the fix from bug #207866 I can now see all catalogs of an server and use "show data" on them.
Comment 1 Jiri Rechtacek 2012-02-10 18:01:13 UTC
Thanks. Applied in core-main/rev/754606a7d290