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 173798 - error using ide to "view data" of db table
Summary: error using ide to "view data" of db table
Status: RESOLVED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: Jiri Rechtacek
URL:
Keywords: NETFIX, PATCH_AVAILABLE
Depends on:
Blocks:
 
Reported: 2009-10-05 20:50 UTC by emiddio
Modified: 2013-05-28 14:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
show prev fixed bug re-introduced (368.91 KB, image/jpeg)
2009-12-21 12:49 UTC, emiddio
Details
tail end of log file show error before nb locked up (42.37 KB, text/plain)
2010-01-05 15:20 UTC, emiddio
Details
potential patch (1.84 KB, patch)
2013-05-26 20:21 UTC, matthias42
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description emiddio 2009-10-05 20:50:16 UTC
works with nb651, fails with nb671; both running jdk1.6.0_16;

trying to read "view data" of table from pointbase;
both netbeans setup with schema PBPUBLIC, user pbpublic;

relevant data:

nb651
jdbc:pointbase://localhost:9092/sun-appserv-samples
com.pointbase.jdbc.jdbcUniversalDriver

command

select * from PBPUBLIC.SAVINGSACCOUNT

yields

Executed successfully in 0 s.
Line 1, column 1

Execution finished after 0 s, 0 error(s) occurred.

==================================================

nb671
jdbc:pointbase://localhost:9092/sun-appserv-samples
com.pointbase.jdbc.jdbcUniversalDriver

command

select * from PBPUBLIC.SAVINGSACCOUNT

yields

Error code 86018, SQL state ZZF19: This result set has been invalidated.
Line 1, column 1

Execution finished after 0 s, 1 error(s) occurred.
===============================

on both use netbeans "view data" right click option on table
Comment 1 emiddio 2009-10-07 20:09:15 UTC
tested with build dnloaded 10/6/09 - nb68; problem exists there also

using same pointbase driver as nb651 -- nb671, nb68 get errors using the 'view data' for a table
Comment 2 Ivan Sidorkin 2009-10-11 15:00:36 UTC
reassigned to db for evaluation
Comment 3 Jiri Rechtacek 2009-10-27 14:32:20 UTC
I'm investigating the problem....
Comment 4 emiddio 2009-10-31 18:25:52 UTC
still in latest dev build; attachment will be a jpg to help
Comment 5 Jiri Rechtacek 2009-11-03 12:45:44 UTC
AFAIK Pointbase isn't one of supported databases in NetBeans IDE.
Comment 6 emiddio 2009-11-09 11:59:21 UTC
netbeans supported/worked with pointbase with version nb4.1 thru nb6.5.1 --  
stopped working in nb671

now the response is "not-supported"  -- so i have to keep a copy of every 
version of netbeans ever shipped so i can work on old code -- just in case some feature that used to work no longer does?

where can i complain to to Bosses' of netbeans?


are you guessing ? -- where is the official list or notifications as to
when support is being dropped in a next release for some feature previouly
supported ?

Glassfish claims support for pointbase and a bunch of other db's;

thanks 

-- i tried to email this msg a wk ago -- but the netbeans migration
was occuring and did not get thru.
Comment 7 Jiri Rechtacek 2009-11-10 07:17:10 UTC
The official list of supported databases is at http://wiki.netbeans.org/NB68TestedPlatformAndRuntimes. Anyway, could you give me a guide where I can download a Pointbase and install it? Or could you link me on any NetBeans&Pointbase co-bundle? I would like to investigate this problem but I have no way how to play with Pointbase. Thanks
Comment 8 emiddio 2009-11-10 12:09:49 UTC
i have co-bundles -- if necessary you can dnload from me -- i can put a file
in a place for you.

i use the AS8.1 --which contains pointbase -- not so much as for running as81
but for using pointbase with all the j2ee1.4 examples/samples,etc the reference
pointbase -- the J2EE 2nd Edition Tutorial Book references pointbase.


i just found a link on netbeans site
http://www.netbeans.info/downloads/start.php?f_id=3591&lang_id=1

or choose netbeans dnload archive then version 4.1 with appserv bundle,
http://www.netbeans.info/downloads/dev.php?email=&monthly=1&contact=1&release_version=4.1&build_type_id=2

you dont have to run netbeans 4.1;after the as81 is installed you can just go
to pointbase\tools\serveroption\startserver.bat -- 

you can also use netbeans4.1 to start the pointbase or as8.1 also if you wanted.
Comment 9 emiddio 2009-11-10 12:18:22 UTC
this was a newer link than i initially provided
http://www.netbeans.info/downloads/all.php?b_id=623&src=1
Comment 10 emiddio 2009-11-10 12:35:27 UTC
i have the j2eetutorial14NB4_1.zip -- which is the tutorial using pointbase
and projects setup for netbeans4.1 -- its 4MBbyte -- i could email it;

the other tutorial examples for j2ee1.4 from sun are all non-netbeans samples,

ie -- they use asant.bat -- and the free form projects made from them
probably dont build correctly;

anyway -- there are .sql scripts in the bundle that you can use to setup
pointbase tables for the examples -- then you can use netbeans to "view"
the tables -- and get the errors -- only get errors with nb671 and future
versions
Comment 11 Jiri Rechtacek 2009-11-11 13:36:50 UTC
Thanks for your hints, I install co-bundle NB4.1 with Sun App Server (with solving a problem with missing libraries on my Ubuntu - 
Command Error:
/tmp/netbeans-4.1/_uninst/sjsas_pe-8_1_02_2005Q2-fcs-bin-b06-linux-13_may_2005.bin: error while loading shared libraries: libstdc++-libc6.2-2.so.3: cannot open shared object file: No such file or directory) I can now connect sample database on Pointbase. Also I can confirm I cannot get any data from Pointbase tables due to "Error code 86018, SQL state ZZF19: This result set has been invalidated." I'm going to investigate more this problem.
Comment 12 emiddio 2009-11-11 15:22:23 UTC
BTW -- nb4.1 gets errors exiting with any jdk1.6x; so i only run nb4.1 with jdk1.5x
Comment 13 Jiri Skrivanek 2009-11-12 08:58:13 UTC
The problem is in PointBase driver itself. Call connection.getMetaData().getColumns() invalidates ResultSet with previously get data. It can be reproduced with the following code snippet: 

        Class.forName("com.pointbase.jdbc.jdbcUniversalDriver");
        Connection connection = DriverManager.getConnection("jdbc:pointbase:sample;database.home=D:/Development/DB/PointBase/databases", "pbpublic", "pbpublic");
        Statement stmt = connection.createStatement();
        String sql = "select * from PBPUBLIC.CUSTOMER_TBL";
        ResultSet rs1 = stmt.executeQuery(sql);
        ResultSet rs2 = connection.getMetaData().getColumns(null, null, null, null);
        rs1.next();

I made a workaround in our code base.
core-main #9814b799acf6
Comment 14 emiddio 2009-11-12 12:51:30 UTC
i dont understand -- since the error does not occur using same driver with nb651 or earlier?

could you explain?
Comment 15 Jiri Skrivanek 2009-11-13 02:11:27 UTC
NetBeans code changes. Previously connection.getMetaData().getColumns() was not used.
Comment 16 emiddio 2009-12-21 12:49:15 UTC
Created attachment 92829 [details]
show prev fixed bug re-introduced
Comment 17 emiddio 2009-12-21 12:54:16 UTC
bug was fixed; i tested about 11/12/2009 dev build.

fix is in dev build
Product Version: NetBeans IDE Dev (Build nbms-and-javadoc-4564-on-091220)
Java: 1.6.0_16; Java HotSpot(TM) 64-Bit Server VM 14.2-b01
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
Userdir: C:\Users\emiddio\.netbeans\dev

also works in nb651;

fix not in nb68fcs;

please put fix back in for nb68 update 1;

also please specify exactly which nb68dev nbm module current fix is in,
i want to dnload and use in nb68

thanks
Comment 18 Jiri Skrivanek 2010-01-05 07:37:46 UTC
The fix is included in NetBeans 6.8 and it works for me there. In message.log I have version org.netbeans.modules.db.dataview [1.5.1 200912041610] and it is located here netbeans/ide12/modules/org-netbeans-modules-db-dataview.jar.
Comment 19 emiddio 2010-01-05 15:17:19 UTC
the fix "was not" in my nb68 when i 1st ran it -- since i got the same
errors i used to get; such as:
Error code 86018, SQL state ZZF19: This result set has been invalidated.
Line 1, column 1

Execution finished after 0 s, 1 error(s) occurred.

but when i installed it i imported from another netbeans and i probably renamed
some newer version -- such as dev or 68m2 to 6.7 so i could import settings from one of those installations.

since then i have configured that nb68 with dev build plugin update sites -- like
deadlock.netbeans and others to get newer modules than shipped with nb68.

so just now -- on a different machine i installed nb68 fresh; then tested with pointbase; the 1st connection try locked up netbeans -- i had to kill it;
i did save the messages.log and will be attached later.

more testing -- i did finally get it to work at times and fail at times;

have to make sure to use right-click refresh, disconnect, refresh, connect(a diff db), refresh, to get it to mostly work; i can view data -- like you said -- so its partially fixed.

i did get 2 exceptions which were filed --

reports 324014, and 324015.

see those and the to be attached messages.log file.
Comment 20 emiddio 2010-01-05 15:20:23 UTC
Created attachment 93089 [details]
tail end of log file show error before nb locked up

waited few minutes -- had to task-manager kill netbeans;

was my 1st pointbase connect attempt after installing fresh - fresh
.netbeans/6.8 dir, no additional plugin/nbm's installed.

1st db of any kind use.
Comment 21 Jiri Skrivanek 2010-01-06 01:34:12 UTC
The exception in messages.log comes from PointBase driver but I don't know why it blocked NetBeans. Some problem with connection.

java.sql.SQLException: Connection failure. handlePrimitiveResponse(...).
	at com.pointbase.dbexcp.dbexcpException.getSQLException(DashoA13*..:205)

As I can't reproduce any exception I am not able to find out what is the problem.
Comment 22 emiddio 2010-01-07 15:44:20 UTC
what can i do to help?

should i zip up some databases where i get the problem?
Comment 23 matthias42 2013-05-26 20:21:55 UTC
Created attachment 134922 [details]
potential patch

- Found a downloadable package of Weblogic Server 8.1, which bundles pointbase
- Opened it in netbeans 7.3, browsed tables => worked
- Opened it in netbeans main-golden: did not work

Problem: The jdbc driver reports "PointBase" for getCatalogs, while the catalog in this case was "demo" -> the assumption in the rework was, that databases, not supporting multiple catalogs do the sane thing and report an empty list ...

The attached patch works around this. With it, I could browse the demo database supplied together with WLS81.

BUT the bug is _old_ and it looks as if the product (pointbase) died in the mean time. So it might be better to ignore this and close it as WONTFIX. I think both responses could be supported by arguments.
Comment 24 Jaroslav Havlin 2013-05-27 15:50:36 UTC
I've integrated the patch - http://hg.netbeans.org/core-main/rev/4b228386756c

I think it can be useful for some users. (And dropping the patch would be waste of your talent :-) )
Thank you, Matthias!
Comment 25 Quality Engineering 2013-05-28 14:14:04 UTC
Integrated into 'main-golden', will be available in build *201305281155* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/4b228386756c
User: Jaroslav Havlin <jhavlin@netbeans.org>
Log: #173798: Error using ide to "view data" of db table

Patch by Matthias42.