[udig-devel] [jira] Created: (UDIG-956) Information View causes ClassCastException in postgis:jdbc for null boolean attribute

Gary Lucas (JIRA) jira at codehaus.org
Fri Aug 4 08:58:03 PDT 2006


Information View causes ClassCastException in postgis:jdbc for null boolean attribute
-------------------------------------------------------------------------------------

                 Key: UDIG-956
                 URL: http://jira.codehaus.org/browse/UDIG-956
             Project: uDIG
          Issue Type: Bug
          Components: postgis
    Affects Versions: UDIG 1.1.RC2
         Environment: JRE 1.5, uDig 1.1-RC2
            Reporter: Gary Lucas
         Assigned To: Jody Garnett


When attempting to inspect the database (PostGIS) attributes for a point feature in uDig by using the Info tool, the program shows only the first few attributes in the table and brings up an "Error" dialog informing me that an error has occurred and that I should consult the log for the cause.   Consulting the log, I get a dump showing a java ClassCaseException (see below).

The problem appears to be related to cases where a boolean attribute in the database table has a "null" value.  By setting the value of that attribute in the affected record to either "true" or "false" I was able to stop the java exception from happening and was able to get the program to display a full set of attributes in the Information view.  Of course, in this case "null" was the appropriate value for the database to have in that particular field, so it doesn't help to simply prevent it from being null.

A copy of the dump follows.

I apologize if this is a known bug, but I was unable to find an obvious matching searching the issue database.

java.lang.ClassCastException: java.lang.String
	at net.refractions.udig.project.ui.internal.properties.AttributePropertyDescriptor$1.getText(AttributePropertyDescriptor.java:110)
	at org.eclipse.ui.views.properties.PropertySheetEntry.getValueAsString(PropertySheetEntry.java:476)
	at org.eclipse.ui.views.properties.PropertySheetViewer.updateEntry(PropertySheetViewer.java:1220)
	at org.eclipse.ui.views.properties.PropertySheetViewer.access$4(PropertySheetViewer.java:1214)
	at org.eclipse.ui.views.properties.PropertySheetViewer$3.valueChanged(PropertySheetViewer.java:320)
	at org.eclipse.ui.views.properties.PropertySheetEntry.fireValueChanged(PropertySheetEntry.java:323)
	at org.eclipse.ui.views.properties.PropertySheetEntry.setValues(PropertySheetEntry.java:738)
	at org.eclipse.ui.views.properties.PropertySheetEntry.refreshValues(PropertySheetEntry.java:597)
	at org.eclipse.ui.views.properties.PropertySheetEntry.refreshChildEntries(PropertySheetEntry.java:551)
	at org.eclipse.ui.views.properties.PropertySheetEntry.setValues(PropertySheetEntry.java:735)
	at org.eclipse.ui.views.properties.PropertySheetViewer.setInput(PropertySheetViewer.java:875)
	at org.eclipse.ui.views.properties.PropertySheetPage.selectionChanged(PropertySheetPage.java:392)
	at net.refractions.udig.tool.info.internal.InfoView2.showDetail(InfoView2.java:185)


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the udig-devel mailing list