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.
Product Version: NetBeans IDE Dev (Build 200706180000) Java: 1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06 System: Windows XP version 5.1 running on x86; Cp1251; ru_RU (nb) The attached .zip-file contains: - NB 6.0 VWP project "InsUpdDel_Oracle", created according to the tutorial "Performing Inserts, Updates, and Deletes" (http://www.netbeans.org/kb/55/vwp-inserts_updates_deletes.html) - SQL script, which describes tables of DB scheme "Travel" - screenshots 1. In the window "Runtime" create new database connection for "Oracle 10g" under the tree node "Databases". 1.1 download jdbs drivers (ojdbc14.jar) for Oracle Database 10g Release 2 from http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html 1.2 create new jdbc-driver with name "Oracle" under the tree node "Databases | Drivers" (use the downloaded ojdbc14.jar) 1.3 create new connection under the tree node "Databases": - select "Oracle" in the dropdown list "Name" - put "jdbc:oracle:thin:@jbrave-pc1.sfbay.sun.com:1521:ora10g" into the "Database URL" - use "travel" for "User Name" and "Password" 2. Open the attached VWP project and run it (sqlDateConverter1 with pattern "dd.MM.yyyy" is used for a table column "textField1", related to the DB Table field "TRIP.DEPDATE"). 3. In web-browser select any person from a Drop Down List and click the button "Save Changes". Result: - error message will appear in the web-browser (see "scrnshot_Web_Page_View_SQlDateConverter.JPG") 4. Delete sqlDateConverter1 from property "converter" of a table column "textField1". Run project. In web-browser select any person from a Drop Down List and click the button "Save Changes". Result: - error message will appear in the web-browser (see "scrnshot_Web_Page_View_NoConverter_DateValue.JPG" and "scrnshot_Web_Page_View_NoConverter_DateTimeValue.JPG")
Created attachment 43977 [details] Project_screenshots
Created attachment 45173 [details] Query Editor
Attachment was meant for another bug.
There does appear to be a problem here. Oracle does a number of non-standard things with dates, so a fix may involve new code. Until I dig into it, I can't say whether we can do it for 6.0.
Workaround is to run the Oracle Driver in V8 Compatibility mode, as described in: http://wiki.netbeans.org/wiki/view/VwpFAQOracleSqlDate This causes Oracle Dates to be mapped in java.sql.Timestamps. Not as elegant, but it works fine. On that basis, lowering priority to P3; I will continue to look for a better solution. I may eventually close the bug, since we could document the workaround in the InsertUpdateDelete tutorial.
Suggested workaround with using approach, described in http://wiki.netbeans.org/wiki/view/VwpFAQOracleSqlDate, definitely works. The bug status is changed to FIXED. Product Version: NetBeans IDE Dev (Build 200710291200) Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b02 System: Windows XP version 5.1 running on x86
Verified on: Product Version: NetBeans IDE Dev (Build 200710291200) Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b02 System: Windows XP version 5.1 running on x86
Nothing was fixed in the IDE so this cannot be marked as fixed. It doesn't seem possible to add a warning to the user, so I think it's ok to mark as WILLNOTFIX There should be an FAQ that points to this workaround
marking as WONTFIX as this is an Oracle limitation so there's nothing in NetBeans that can be done to fix this.
John, could you provide a more detailed explanation of what the problem is here? What is going wrong? Using v8compatibility works, but I can see this having a lot of other side effects, as it basically degrades your database functionality for NetBeans to version 8.
desc5 and desc6 do sound contradictory So far what I see is when a component is bound to a dataprovider field key of type Date, not TimeStamp at runtime, Oracle complains that the type is not a valid SQL type. In this project, a TextField is bound to the DepDate field. To retrieve and store a date instead of a timestamp, an SQLDateConverter is applied to the TextField. I'll see if any workaround can be applied to CachedRowSetXImpl5 or related. If not then the workaround describe will have to do.