-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Float fields created in ArcGIS are converted into Real 12, 11 - Precision is too high #51849
Comments
@epc-aac your shapefile does not contain any field (missing dbf?). |
Yes, sorry, you can telll this is my first report |
Ok, this is what happens (to my understanding): GDAL reports width 13 and precision 11.
But, according to https://issues.qgis.org/issues/11755 the width includes the decimal separator (and the minus sign) , so we reduce the width by 1 to accomodate QGIS field model (based on PostGIS where the decimal point is not included) This was discussed before: #23127 I'm not sure if there is something we can do here because there is not an exact solution to the problem. IIRC an application can ignore the width and precision in a DBF, in your test file for instance there is
which seems out of bounds to me. |
Note that we might enhance GDAL to handle different conventions when reporting width and precision, this would make it easier to access these informations from QGIS and other applications consistently. |
Ok, thank you! I get an idea of the issue. The thing is that someone created shapefile templates for a project and we can't handle them with QGIS. I've used 'refactorfields', so I've changed the template. Hope there will be no problem this time because it is not a final delivery. |
For reference: OSGeo/gdal#7264 |
What is the bug or the crash?
Float fields of a shapefile created with other platform / software are converted into real(12,11). You can see the values correctly but if you try to overwrite them you can only add values from -9,99999999999 to 9,99999999999.
Steps to reproduce the issue
Versions
3.22.8-Białowieża
3.28.2-Firenze
Supported QGIS version
New profile
Additional context
No response
The text was updated successfully, but these errors were encountered: