Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QGIS3.28.15:Polygon Features from ArcGIS GDB Turn into TABLE after Editing in QGIS #57536

Closed
2 tasks done
a1053180364 opened this issue May 23, 2024 · 4 comments
Closed
2 tasks done
Assignees
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers Upstream Needs changes in an upstream library (like Qt, Proj, GDAL, ...)

Comments

@a1053180364
Copy link

What is the bug or the crash?

Hello, I have discovered a bug in QGIS 3.28.15. When importing POLYGON features from a GDB file created in ArcGIS into QGIS, and then editing the attributes in QGIS by adding new attribute fields, the polygon features unexpectedly become TABLE when re-importing the file back into ArcGIS.

Steps to reproduce the issue

1. Create a GDB file and add POLYGON in ArcGIS, then close ArcGIS.
2. Import the POLYGON into QGIS and edit the attributes by adding a new field.
1

3. Save the GDB file, close QGIS, and reload it in ArcGIS. Then will find that the original POLYGON have turned into TABLE.
2

Versions

3.28.15

Supported QGIS version

  • I'm running a supported QGIS version according to the roadmap.

New profile

Additional context

No response

@a1053180364 a1053180364 added the Bug Either a bug report, or a bug fix. Let's hope for the latter! label May 23, 2024
@rouault
Copy link
Contributor

rouault commented May 23, 2024

@a1053180364 Could you attach a zip with the .gdb just after you created with ArcGIS, and one after you edited it with QGIS?

@agiudiceandrea agiudiceandrea added Feedback Waiting on the submitter for answers Data Provider Related to specific vector, raster or mesh data providers labels May 23, 2024
@a1053180364
Copy link
Author

Here is the attached zip file:
gdb.zip

1

2

@rouault rouault self-assigned this May 25, 2024
@rouault rouault added Upstream Needs changes in an upstream library (like Qt, Proj, GDAL, ...) and removed Feedback Waiting on the submitter for answers labels May 25, 2024
rouault added a commit to rouault/gdal that referenced this issue May 25, 2024
Versions of the driver before commit fdf3901
didn't properly update the m_nHeaderBufferMaxSize field when updating an
existing feature when the new version takes more space than the previous
version. OpenFileGDB doesn't care but Esri software (FileGDB SDK or
ArcMap/ArcGis) do, leading to issues such as
qgis/QGIS#57536
rouault added a commit to rouault/gdal that referenced this issue May 25, 2024
Versions of the driver before commit fdf3901
didn't properly update the m_nHeaderBufferMaxSize field when updating an
existing feature when the new version takes more space than the previous
version. OpenFileGDB doesn't care but Esri software (FileGDB SDK or
ArcMap/ArcGis) do, leading to issues such as
qgis/QGIS#57536
@rouault
Copy link
Contributor

rouault commented May 25, 2024

OK, the issue is that your QGIS version is using a GDAL version prior to GDAL 3.9.0, which was affected by a bug causing Esri software to choke on files updated by GDAL/QGIS. GDAL 3.9.1 will detect & autorepair such issues in corrupted files, with the fixes of OSGeo/gdal#10008

Your workaround for the time being is to re-open the modified file with QGIS, and use "Save vector layer as" functionality to regenerate a new clean FileGeodatabase that should read fine in Esri software . Or use the ogr2ogr command line utility, or through QGIS with the Processing toolbox / GDAL / Vector conversion / Convert format tool which is the graphical interface over ogr2ogr.

@rouault
Copy link
Contributor

rouault commented May 25, 2024

Updating to the latest QGIS LTR should also avoid that issue as I believe it ships with GDAL 3.9

@rouault rouault closed this as completed May 25, 2024
rouault added a commit to rouault/gdal that referenced this issue May 25, 2024
Versions of the driver before commit fdf3901
didn't properly update the m_nHeaderBufferMaxSize field when updating an
existing feature when the new version takes more space than the previous
version. OpenFileGDB doesn't care but Esri software (FileGDB SDK or
ArcMap/ArcGis) do, leading to issues such as
qgis/QGIS#57536
rouault added a commit to OSGeo/gdal that referenced this issue Jun 3, 2024
Versions of the driver before commit fdf3901
didn't properly update the m_nHeaderBufferMaxSize field when updating an
existing feature when the new version takes more space than the previous
version. OpenFileGDB doesn't care but Esri software (FileGDB SDK or
ArcMap/ArcGis) do, leading to issues such as
qgis/QGIS#57536
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers Upstream Needs changes in an upstream library (like Qt, Proj, GDAL, ...)
Projects
None yet
Development

No branches or pull requests

3 participants