[GRASS-user] v.in.ogr ESRI fileGDB

I have an ESRI GDB directory of bathymetric and topographic coverage. I've
not before imported this type of file from the command line.

Looking at the v.in.ogr manual page I'm not sure how to write the command;
there's not an example for a GDB.

Please point me to a reference that will teach me how to import this file
type.

TIA,

Rich

Hello Rich,
I don't have File GDB at hand to test it but it should be as simple as
pointing "input" to the folder of FGDB and setting "layer" to the name
of dataset in FGDB. You can get names of all layers in CLI with
"ogrinfo -ro -so /path/to/FGDB".

Good luck & let us know if you succeed.
Māris.

ceturtd., 2021. g. 16. sept., plkst. 20:08 — lietotājs Rich Shepard
(<rshepard@appl-ecosys.com>) rakstīja:

I have an ESRI GDB directory of bathymetric and topographic coverage. I've
not before imported this type of file from the command line.

Looking at the v.in.ogr manual page I'm not sure how to write the command;
there's not an example for a GDB.

Please point me to a reference that will teach me how to import this file
type.

TIA,

Rich
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

And if it works, perhaps it is worth adding an example to the help page? Or send a working code example that others can add to the help file of v.in.ogr if you like.

On Fri, Sep 17, 2021 at 8:46 AM Maris Nartiss <maris.gis@gmail.com> wrote:

Hello Rich,
I don’t have File GDB at hand to test it but it should be as simple as
pointing “input” to the folder of FGDB and setting “layer” to the name
of dataset in FGDB. You can get names of all layers in CLI with
“ogrinfo -ro -so /path/to/FGDB”.

Good luck & let us know if you succeed.
Māris.

ceturtd., 2021. g. 16. sept., plkst. 20:08 — lietotājs Rich Shepard
(<rshepard@appl-ecosys.com>) rakstīja:

I have an ESRI GDB directory of bathymetric and topographic coverage. I’ve
not before imported this type of file from the command line.

Looking at the v.in.ogr manual page I’m not sure how to write the command;
there’s not an example for a GDB.

Please point me to a reference that will teach me how to import this file
type.

TIA,

Rich


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

On Fri, 17 Sep 2021, Maris Nartiss wrote:

I don't have File GDB at hand to test it but it should be as simple as
pointing "input" to the folder of FGDB and setting "layer" to the name of
dataset in FGDB. You can get names of all layers in CLI with "ogrinfo -ro
-so /path/to/FGDB".

Māris,

Something's wrong here. Using 'ogrinfo -ro -so Tile_E.gdb' from the
directory where that's located produces this message:
INFO: Open of `Tile_E.gdb/'
       using driver `OpenFileGDB' successful.

Same result using -al rather than -ro.

Using the GUI:
Fri Sep 17 08:20:46 2021) v.in.ogr -r input=~/projects/washington/nevins-dock/data/bathymetry/Tile_E.gdb output=bathy_terrain
ERROR: Unable to open data source <[path_to_/Tile_E.gdb>

Is it me or v.in.ogr in the 8.0dev source?

A couple of years ago I had no problems importing ESRI FileGDB maps.

Regards,

Rich

Strange. I just tested and it works just as I described:
v.in.ogr input=/home/maris/path/to/dataset.gdb/ layer=mylayer output=mylayer

I was testing on the main branch compiled at the end of August running
with GDAL 3.0.4.

Rich, you should see in the output of ogrinfo -ro -so a list of layers
in the FGDB. If you do not see them, then you will not be able to
import as GRASS is using OGR for reading FGDB.
Here's an example of output on my system:
ogrinfo -ro -so path/to.gdb/
INFO: Open of `to.gdb/'
      using driver `OpenFileGDB' successful.
1: first_layer (Multi Line String)
2: second_layer (Multi Polygon)

Māris.

piektd., 2021. g. 17. sept., plkst. 18:30 — lietotājs Rich Shepard
(<rshepard@appl-ecosys.com>) rakstīja:

On Fri, 17 Sep 2021, Maris Nartiss wrote:

> I don't have File GDB at hand to test it but it should be as simple as
> pointing "input" to the folder of FGDB and setting "layer" to the name of
> dataset in FGDB. You can get names of all layers in CLI with "ogrinfo -ro
> -so /path/to/FGDB".

Māris,

Something's wrong here. Using 'ogrinfo -ro -so Tile_E.gdb' from the
directory where that's located produces this message:
INFO: Open of `Tile_E.gdb/'
       using driver `OpenFileGDB' successful.

Same result using -al rather than -ro.

Using the GUI:
Fri Sep 17 08:20:46 2021)
v.in.ogr -r input=~/projects/washington/nevins-dock/data/bathymetry/Tile_E.gdb output=bathy_terrain
ERROR: Unable to open data source <[path_to_/Tile_E.gdb>

Is it me or v.in.ogr in the 8.0dev source?

A couple of years ago I had no problems importing ESRI FileGDB maps.

Regards,

Rich
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Hi,

import lay layer using drag and drop into QGIS. From there to GRASS GIS (import QGIS layer).

Kind regards

Am 16.09.21 um 19:08 schrieb Rich Shepard:

I have an ESRI GDB directory of bathymetric and topographic coverage. I've
not before imported this type of file from the command line.

Looking at the v.in.ogr manual page I'm not sure how to write the command;
there's not an example for a GDB.

Please point me to a reference that will teach me how to import this file
type.

TIA,

Rich
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

On Fri, 17 Sep 2021, Maris Nartiss wrote:

I was testing on the main branch compiled at the end of August running
with GDAL 3.0.4.

Maris,

gdal-3.2.2 is installed here. The problem is not that.

Rich, you should see in the output of ogrinfo -ro -so a list of layers
in the FGDB. If you do not see them, then you will not be able to
import as GRASS is using OGR for reading FGDB.

That's what I expected. But, From the directory in which Tile_E.gdb/ is
located:
$ ogrinfo -ro -so ./Tile_E.gdb/
INFO: Open of `./Tile_E.gdb/'
       using driver `OpenFileGDB' successful.

That's it.

Of course GRASS could not import it since ogrinfo didn't see any content in
the open file.

I'll download it from the source again.

Thanks,

Rich

On Fri, 17 Sep 2021, Klaus Mithöfer wrote:

import lay layer using drag and drop into QGIS. From there to GRASS GIS
(import QGIS layer).

Klaus,

I don't run QGIS. GRASS and SAGA GIS meet my needs. It's also likely that if
ogr opens the directory but does not find any files it won't on QGIS either.

Regards,

Rich

Hi Rich,

I saw that you found a different solution, but just for the record: are you sure the fgdb actually contains vector data ? AFAIR, fgdb's can also contain raster data, but there is no gdal driver for that.

Moritz

Le 17 septembre 2021 19:29:37 GMT+02:00, Rich Shepard <rshepard@appl-ecosys.com> a écrit :

On Fri, 17 Sep 2021, Maris Nartiss wrote:

I was testing on the main branch compiled at the end of August running
with GDAL 3.0.4.

Maris,

gdal-3.2.2 is installed here. The problem is not that.

Rich, you should see in the output of ogrinfo -ro -so a list of layers
in the FGDB. If you do not see them, then you will not be able to
import as GRASS is using OGR for reading FGDB.

That's what I expected. But, From the directory in which Tile_E.gdb/ is
located:
$ ogrinfo -ro -so ./Tile_E.gdb/
INFO: Open of `./Tile_E.gdb/'
      using driver `OpenFileGDB' successful.

That's it.

Of course GRASS could not import it since ogrinfo didn't see any content in
the open file.

I'll download it from the source again.

Thanks,

Rich
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

On Fri, 17 Sep 2021, Moritz Lennert wrote:

I saw that you found a different solution, but just for the record: are
you sure the fgdb actually contains vector data ? AFAIR, fgdb's can also
contain raster data, but there is no gdal driver for that.

Moritz,

The alternative solution is less desirable.

I've no idea how to determine if the fileGDB holds vector or raster data.
I've looked through the gdal web site and didn't see how to determine the
type of data. But, I've assumed the .atx files in the directory ar vector.

There are also several TIFF files:
tile_e_dem_tif.aux.xml
tile_e_dem_tif.tfw
tile_e_dem_tif.tif
tile_e_dem_tif.tif.ovr
tile_e_dem_tif.tif.xml

I've not tried r.in.gdal; will do so over the weekend.

BTW, I don't know what Vero changed in the web site but for the 8.0dev
manual the GRASS startup page link in the General category still produces a
404 page not found.

Stay well,

Rich