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.
When I connect to DB2 database explorer doesnt show me tree with database objects. It works well in 7.3.1 I am using: IBM DB2 Universal Driver db2jcc4.jar db2jcc_license_cisuz.jar sqlj4.zip Product Version = NetBeans IDE 7.4 (Build 201310111528) Operating System = Windows 7 version 6.1 running on x86 Java; VM; Vendor = 1.7.0_21 Runtime = Java HotSpot(TM) Client VM 23.21-b01
Created attachment 141547 [details] IDE log
Hello, thanks for the report. Unfortunately I don't see anything in the log related to this issue. The screenshot could be useful. I would also ask you to look into the issue 225254 if they are related somehow.
Created attachment 141662 [details] In 7.3.1 it works well
Created attachment 141663 [details] In 7.4 it doesnt show tree
It is hard to say if there is some connection between this issue and 225254. Here there is exactly the same db2 database, exactly the same JDK (1.7.0_21), exactly the same db2 driver in both cases. The only difference is NB_7.3.1 in working case and NB_7.4 in case of trouble. Let me know how can I help you more. I am able to setup Skype conference and to share my desktop if it would help. Jarda
Could you please provide the jdbc url your using to connect? It can anonymized, but I need the structure with all elements. I suspect (call it hunch) a duplicate of bug 237345. There the jdbc connection does not refer to one database, but the whole dbms. You could be facing the same issue.
Created attachment 141665 [details] URLs
Ok - once again jdbc implementors prove that can mess up even the simplest apis. I downloaded the IBM demo appliance (https://www.ibm.com/developerworks/data/library/techarticle/dm-1205testdrivedb2/). I could reproduce the problem. First problem is indeed a duplicate of bug 237345 (no children are shown for the connection node, because delegation does not work - see discussion and potential fix in mentioned bug). Second is bogus data from DB2: For the connection: jdbc:db2://192.168.1.100:50001/SAMPLE Connection#getCatalog returns NULL for DB2 connections Connection#getMetadata#getCatalogs returns a list with one entry: SAMPLE This is already bogus - it gets even better (dmd = DatabaseMetaData): dmd.getTables(null, null, "%", new String[] {"TABLE"}) lists all tables in the SAMPLE DB. While this: dmd.getTables("SAMPLE", null, "%", new String[] {"TABLE"}); doesn't list any table. So my fix for the second problem: Mark the DB2 driver as reporting bogus catalog names (introduced for pointbase, bug 173798). Libor, could you please take a look at this? I raised priority to P1, according to guide lines it qualifies by: usability Prevents most users from completing work, with no workaround While bug 237345 could be worked around (connect to mysql db), I don't see a similar possibility for DB2.
(In reply to matthias42 from comment #8) > Mark the DB2 driver as reporting bogus catalog names (introduced for pointbase, bug 173798). In db.metadata, JDBCMetadata.java: # This patch file was generated by NetBeans IDE # It uses platform neutral UTF-8 encoding and \n newlines. --- Base (BASE) +++ Locally Modified (Based On LOCAL) @@ -210,6 +210,8 @@ * @return */ private boolean driverReportsBogusCatalogNames() throws SQLException { - return "PointBase JDBC Driver".equals(dmd.getDriverName()); + String driverName = dmd.getDriverName(); + return "PointBase JDBC Driver".equals(driverName) || + "IBM Data Server Driver for JDBC and SQLJ".equals(driverName); } }
Sorry for late patch integration. Fixed in changeset: http://hg.netbeans.org/core-main/rev/f2ab1d481cc5 Matthias, thank you very much for that patch. It works perfectly for me. Jaroslav, could you please verify it? Thank you
Hello can you guide me how to implement this patch? Thank you Jaroslav
(In reply to jaroslav.beran from comment #11) > Hello can you guide me how to implement this patch? > > Thank you > > Jaroslav Hello, just wait when it'll be integrated into daily build. It will be noticed here.
Integrated into 'main-silver', will be available in build *201311080001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/f2ab1d481cc5 User: Libor Fischmeistr <lfischmeistr@netbeans.org> Log: #237648: When I connect to DB2 database explorer doesnt show me tree with database objects.
Created attachment 141981 [details] Fixed Hello, I tested it with success - now it works well. Thank you very much :-) Jaroslav
thanks for verification. (In reply to jaroslav.beran from comment #14) > Created attachment 141981 [details] > Fixed > > Hello, > > I tested it with success - now it works well. > > Thank you very much :-) > > Jaroslav
Integrated into release74: http://hg.netbeans.org/releases/rev/2c3337758136
Integrated into 'releases/release74', will be available in build *201311141216* or newer. Wait for official and publicly available build. Changeset: http://hg.netbeans.org/releases/rev/2c3337758136 User: Libor Fischmeistr <lfischmeistr@netbeans.org> Log: #237648: When I connect to DB2 database explorer doesnt show me tree with database objects.
*** Bug 225254 has been marked as a duplicate of this bug. ***