Personal geodatabase

4393
2
Jump to solution
01-14-2015 01:29 AM
JUAN_CARLOSROMERO_BLANCO
New Contributor

I'm trying to read a shape from a persona Database (MDB) using ArcGIS java SDK. 

public static void main(String[] args) {
    String pathMDB="C:\\Documentos\\NetBeansProjects\\Pruebas\\OpenPersonalGeodatabaseMDB\\Atlantic.mdb";
    Geodatabase mdbGeodatabase=null;
    try {
            mdbGeodatabase= new Geodatabase(pathMDB);
    } catch (FileNotFoundException ex) {
        Logger.getLogger(OpenPersonalGeodatabaseMDB.class.getName()).log(Level.SEVERE, null, ex);
    } catch (Exception ex) {
        Logger.getLogger(OpenPersonalGeodatabaseMDB.class.getName()).log(Level.SEVERE, null, ex);
    }
  
  
  
  
    System.out.println(mdbGeodatabase.getGeodatabaseTables().toString());
      
   }

i always have the error File opened that is not a database file. i'm doing right ?

0 Kudos
1 Solution

Accepted Solutions
VijayGandhi
New Contributor III

The supported format for a geodatabase file is a ".geodatabase". That database is created through a GeodatabaseFeatureTable - basically, it connects to a FeatureLayer and downloads data into a file.

The workflow is described at Offline editing workflow | ArcGIS for Developers . An example is also available in the samples (Editing -> Offline editing workflow).

View solution in original post

2 Replies
VijayGandhi
New Contributor III

The supported format for a geodatabase file is a ".geodatabase". That database is created through a GeodatabaseFeatureTable - basically, it connects to a FeatureLayer and downloads data into a file.

The workflow is described at Offline editing workflow | ArcGIS for Developers . An example is also available in the samples (Editing -> Offline editing workflow).

VijayGandhi
New Contributor III

Note that to download features, the FeatureLayer/Service has to be published with Sync capability.

ArcGIS REST API

0 Kudos