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.
I really would like to have a window where I have my connections and where I have nodes to expand all SQL queries for each connection like inside the SQL History. I would like to provide a plugin for this, but I don't know whether there is a publich API to read out all SQL history entries. If someone is willing to help me to provide a API or documentation, I will implement it by my own. Cheers Chris P.S. it is related to this ticket: https://netbeans.org/bugzilla/show_bug.cgi?id=153633
I'm currently more focused on other projects, but I'd be willing to sponsor uploads (you'll need an approved OCA: http://wiki.netbeans.org/FaqWhatIsCA). The history is located in the db.core module, all relevant code is bundled in the org.netbeans.modules.db.sql.history package. As you can see there the history itself is backed by an XML file and binding is done via JAXB. The API for db.core is currently friend-only and history is not exported. Implementing a window could be done if the module itself. In regard to #153633 a windows and the current dialog do not have to exclude each other.
Are you working on other projects on Netbeans? With the OCA I only can contribute to the real netbeans source and I can't create a plugin, or?
(In reply to ChrisLE from comment #2) > Are you working on other projects on Netbeans? Nope - outside the netbeans project (in any case I'm not employed by oracle, I just happenend to take the maintainer role for the DB modules). > With the OCA I only can contribute to the real netbeans source and I can't > create a plugin, or? The OCA is currently needed to get changes into the netbeans codebase. With the current modules you'd need an implementation dependency on db.core to access the SQL history, this won't be fun to maintain. If you want to work outside the netbeans codebase and create a plugin to support this, you can check if you can use the yenta module, that allows changing friend modules, whether it also allows implementation dependency like access I don't know.
Ok I figured out that I can access the sql history via the sql_history.xml and the SQL Commands will be saved inside SQL files in Roaming/NetBeans/8.2/config/Database. This will be only a workaround but I think this is ok for the first try. :)