Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[udig-devel] Error while opening my shape files

Hi all,

I have three shape files that were created by ArcGIS and have some attributes having names and values in Farsi. When I add them to the project, one of them is not added at all and udig throws an exception like this:

java.lang.IllegalArgumentException: Duplicate AttributeTypes DefaultAttributeType [name=���_���� , type=class java.lang.String , nillable=true, min=1, max=1]
at org.geotools.feature.FeatureTypeBuilder.check (FeatureTypeBuilder.java:601)
at org.geotools.feature.FeatureTypeBuilder.addType(FeatureTypeBuilder.java:348)
at org.geotools.feature.FeatureTypeBuilder.addTypes(FeatureTypeBuilder.java:328)
at org.geotools.feature.FeatureTypes.newFeatureType (FeatureTypes.java:218)
at org.geotools.feature.FeatureTypes.newFeatureType(FeatureTypes.java:168)
at org.geotools.data.shapefile.indexed.IndexedShapefileDataStore.getSchema(IndexedShapefileDataStore.java:935)
at org.geotools.data.AbstractFileDataStore.getFeatureSource(AbstractFileDataStore.java:70)
at net.refractions.udig.catalog.internal.shp.ShpServiceImpl.getDS(ShpServiceImpl.java:227)
at net.refractions.udig.catalog.internal.shp.ShpServiceImpl.members (ShpServiceImpl.java:152)
at net.refractions.udig.catalog.ui.workflow.ConnectionState.run(ConnectionState.java:131)
at net.refractions.udig.catalog.ui.workflow.Workflow.next(Workflow.java:260)
at net.refractions.udig.catalog.ui.workflow.Workflow$Runner.run (Workflow.java:585)
at net.refractions.udig.catalog.ui.workflow.Workflow.run(Workflow.java:444)
at net.refractions.udig.catalog.ui.FileConnectionPage$2.run(FileConnectionPage.java:166)
at net.refractions.udig.catalog.ui.workflow.WorkflowWizardDialog$3.run (WorkflowWizardDialog.java:98)
at net.refractions.udig.ui.PlatformGIS$1.call(PlatformGIS.java:90)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source) 

(The exception occurs in the linux, but it  doesn't occur  in the windows and the file is loaded without any exception.)
The other two files are added without any exceptions, but their string attributes are not displayed in the correct charset. I found a previous post about arabic charsets and I applied the patch related to that bug, but I didn't see any effects. I can open these files in the QGis without any problem. The attributes are not displayed in correct charset In QGis, but  when I change them, they are displayed correctly.
In udig, even in new created layers, when I type farsi strings for the attributes, they are converted to some strange characters. The default charset in my linux system is UTF-8.



Thanks in advance for your help


Back to the top