Re: [gdal-dev] ogr2ogr no longer works with non super user in PG after update

2024-06-11 Thread Alexandre Gacon via gdal-dev
Thanks even for the feedback. I have just spotted the nomd option but I didn't get the time to test it. Regards Alexandre Le mar. 11 juin 2024 à 17:43, Even Rouault a écrit : > Hi, > > The issue has been reported in https://github.com/OSGeo/gdal/issues/9994 > and should be be fixed in 3.9.1 per

Re: [gdal-dev] Changing many features in a GPKG in a transaction, why is the index updated?

2024-06-11 Thread Nyall Dawson via gdal-dev
On Wed, 12 Jun 2024 at 11:54, Even Rouault wrote: > > But... as you mention "bulk attribute changes", assuming you don't > change geometries, you would be better using OGR_L_UpdateFeature() where > you could specify to update only a subset of attributes instead of > updating the whole feature. In

Re: [gdal-dev] Changing many features in a GPKG in a transaction, why is the index updated?

2024-06-11 Thread Even Rouault via gdal-dev
Hi Nyall, What you observe is fully expected. The spatial index must be kept fully in sync with the changes in the feature table, even when run within a transaction. Otherwise if during the transaction you would execute a spatial query, you would get inconsistents result if the spatial index

[gdal-dev] Changing many features in a GPKG in a transaction, why is the index updated?

2024-06-11 Thread Nyall Dawson via gdal-dev
Hi list, I'm trying to understand some unexpected behavior I'm seeing while profiling bulk attribute changes in a GPKG file. First, I start a transaction on the layer using OGR_L_StartTransaction. This is successful. I then make many calls to OGR_L_SetFeature, changing different features, before

Re: [gdal-dev] gdal2xyz

2024-06-11 Thread Even Rouault via gdal-dev
Le 11/06/2024 à 21:31, Even Rouault via gdal-dev a écrit : Le 11/06/2024 à 21:22, Andrew Bell via gdal-dev a écrit : Hi, The documentation describes an application `gdal2xyz`, but I don't see one built in my development environment. I also don't see anything in the CMakeLists.txt that refe

Re: [gdal-dev] gdal2xyz

2024-06-11 Thread Even Rouault via gdal-dev
Le 11/06/2024 à 21:22, Andrew Bell via gdal-dev a écrit : Hi, The documentation describes an application `gdal2xyz`, but I don't see one built in my development environment. I also don't see anything in the CMakeLists.txt that refers to it. Is it named something I'm not expecting? Does it st

[gdal-dev] gdal2xyz

2024-06-11 Thread Andrew Bell via gdal-dev
Hi, The documentation describes an application `gdal2xyz`, but I don't see one built in my development environment. I also don't see anything in the CMakeLists.txt that refers to it. Is it named something I'm not expecting? Does it still exist? Thanks, -- Andrew Bell andrew.bell...@gmail.com __

Re: [gdal-dev] ogr2ogr no longer works with non super user in PG after update

2024-06-11 Thread Even Rouault via gdal-dev
Hi, The issue has been reported in https://github.com/OSGeo/gdal/issues/9994 and should be be fixed in 3.9.1 per https://github.com/OSGeo/gdal/pull/10004 (testing of the 3.9 branch at https://github.com/OSGeo/gdal/tree/release/3.9 would be appreciated to confirm that it fixes error for variou

[gdal-dev] ogr2ogr no longer works with non super user in PG after update

2024-06-11 Thread Alexandre Gacon via gdal-dev
Hello there, After updating our stack from GDAL 3.4.1 to GDAL 3.9.0, we have ogr2ogr calls which no longer succeed with the following message: ERROR: permission denied to create event trigger "ogr_system_tables_event_trigger_for_metadata". HINT: Must be superuser to create an event trigger. I

Re: [gdal-dev] GDALGetGeoTransform

2024-06-11 Thread Johannes Paul via gdal-dev
Thanks Even, that's what I was looking for. Thanks a lot for the support. On Tue, 11 Jun 2024 at 16:09, Even Rouault wrote: > Johannes, > > access to your DIMAP product would be needed to investigate. > > I assume the product also returns RPC? If so, test GetMetadata("RPC") > != null, and if i

[gdal-dev] TdhOGR - Vector Data Translation

2024-06-11 Thread Tim Hirrel via gdal-dev
Greetings: TdhOGR translates vector data between various formats while optionally transforming the coordinates to a different reference system. The data formats for source and target include those provided by the GDAL/OGR library and the TDH vecto

Re: [gdal-dev] GDALGetGeoTransform

2024-06-11 Thread Laurențiu Nicola via gdal-dev
Hi Johannes, You can use GDALGetGCPCount to check if the file has GCPs, then use gdalwarp -tps or the equivalent to uncrinkle it: https://stackoverflow.com/questions/48770002/project-raster-file-using-gcps. Laurentiu On Tue, Jun 11, 2024, at 17:02, Johannes Paul via gdal-dev wrote: > Hello, >

Re: [gdal-dev] GDALGetGeoTransform

2024-06-11 Thread Even Rouault via gdal-dev
Johannes, access to your DIMAP product would be needed to investigate. I assume the product also returns RPC?   If so, test GetMetadata("RPC") != null, and if it does, you can likely consider than any GeoTransform is "garbage". If you have RPCs, you can directly compute a geotransform. You ne

[gdal-dev] GDALGetGeoTransform

2024-06-11 Thread Johannes Paul via gdal-dev
Hello, coming back to an old thread regarding a DIMAP product which has no lon/lat (https://lists.osgeo.org/pipermail/gdal-dev/2018-January/048014.html). GDALGetGeoTransform method will return CE_None despite GeoTransformation matrix is not as expected, and in that specific case I would rather use

Re: [gdal-dev] Adding multiple TREs to a NITF using gdal_translate

2024-06-11 Thread Even Rouault via gdal-dev
Le 11/06/2024 à 12:11, Marek Setnik via gdal-dev a écrit : Hello! I'm having trouble with adding multiple TREs to a NITF file (using C++ API), the documentation mentions that the TRE creation options allows for that but I can't figure out the syntax, how do I achieve something like this: TR

Re: [gdal-dev] Adding multiple TREs to a NITF using gdal_translate

2024-06-11 Thread Brad Hards via gdal-dev
Not quite what you asked for, but https://github.com/OSGeo/gdal/blob/master/autotest/gdrivers/nitf.py#L2101 might be another way to achieve what you need. Otherwise,  some more details on exact TREs might be relevant. On 11 June 2024 8:11 pm, Marek Setnik via gdal-dev wrote: Hello! I'm h

[gdal-dev] Odp.: Adding multiple TREs to a NITF using gdal_translate

2024-06-11 Thread Marek Setnik via gdal-dev
Oh, that's perfect actually, it did tell me that using TRE twice should work and it actually does. My error was that I had extra bytes at the end of my TREs, I removed those and now I've got all my TREs showing up, so thank you! Od: Brad Hards Wysłane: wtorek, 1

[gdal-dev] Adding multiple TREs to a NITF using gdal_translate

2024-06-11 Thread Marek Setnik via gdal-dev
Hello! I'm having trouble with adding multiple TREs to a NITF file (using C++ API), the documentation mentions that the TRE creation options allows for that but I can't figure out the syntax, how do I achieve something like this: TRE=NAME1=VALUES1,NAME2=VALUES2 ? (I also tried to use TRE creati