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.
Build: NetBeans IDE Dev (Build 200807040101) VM: Java HotSpot(TM) Client VM, 10.0-b19, Java(TM) SE Runtime Environment, 1.6.0_05-b13 OS: Linux, 2.6.25.10-47.fc8, i386 User comments: STACKTRACE: (first 10 lines) org.xml.sax.SAXParseException: Premature end of file. at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:239) at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:283) at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:124) at org.netbeans.modules.db.sql.history.SQLHistoryPersistenceManager$AtomicWriter.run(SQLHistoryPersistenceManager.java:232) at org.openide.filesystems.EventControl.runAtomicAction(EventControl.java:120) at org.openide.filesystems.FileSystem.runAtomicAction(FileSystem.java:499) at org.netbeans.modules.db.sql.history.SQLHistoryPersistenceManager.create(SQLHistoryPersistenceManager.java:111) at org.netbeans.modules.db.sql.history.SQLHistoryManager.save(SQLHistoryManager.java:111) at org.netbeans.modules.db.sql.execute.SQLExecuteHelper.execute(SQLExecuteHelper.java:176) at org.netbeans.modules.db.sql.loader.SQLEditorSupport$SQLExecutor.run(SQLEditorSupport.java:476)
I suppose if an XML exception occurs, a dialog should open informing the user of the problem and the persisted file should be deleted and recreated.
should have a fix soon
b403b05a21a6 If there's any corruption executing SQL, such that unparsable text is saved then SQL History will report a message in the dialog, log the error in messages.log and reset the history file.
Created attachment 67761 [details] sample sql_history file with corrupted values
To verify the fix, replace an existing sql_history file with this one in config/Databases/SQLHISTORY then try to open SQL History. Opening history again will prompt the user to execute SQL in order to show the history dialog
Verified with build 080819.
Integrated into 'main-golden', available in build *200808191401* on http://bits.netbeans.org/dev/nightly/ Changeset: http://hg.netbeans.org/main/rev/b403b05a21a6 User: John Baker` <jbaker@netbeans.org> Log: #143680 SQL History: org.xml.sax.SAXParseException: Premature end of file; cleanup