How do I get QGIS to stop chopping off parts of my attribute table column names past 10 characters? Or is this unavoidable
QGIS keeps cutting off attribute table column names after 10 characters, can I stop this?
7If you use a shapefile, this limitation is by design– KurtJul 14, 2020 at 20:58
2If save your layer as a Geopackage you can have longer field names.– BasweinJul 14, 2020 at 21:52
See here: http://switchfromshapefile.org/#10characters
Referring to shapefiles:
Attribute names are limited to 10 characters max. Longer names are usually automatically shortened. This leads to abbreviated and/or cryptic attribute names that are unintuitive to the recipient of the data.
More details about Shapefiles in the Shapefile Technical Description and Shapefile on Twitter.
If you want to use more than 10 characters, you should use another format, e.g. geopackage. Most limitations of shapefiles are not relevant for geopackage. However, Shapefiles are a de facto standard for interchange and has the best support for reading/writing. Geopackage however has become more popular and in the meantime most GIS software can at least read Geopackage. Full writing support is not implemented everywhere, so always reflect what you will need your data for: just for yourself, locally? Or do you have to share your data? With whom? What kind of software do they use and how is Geopackage supported by this software? Are they maybe willing to install QGIS instead to get full Geopacke support? If you just have to deal with people using QGIS and FOSS software, Geopackage might be a good choice.
However, even here some disadvantages of using Geopackage might be worth considering. I cite from a presentation of Geopackage Hackaton (the original is in german), see the second pdf here (Geopackage Hackathon - Einführung) on page 6: https://www.inspire.gv.at/INSPIRE-Oesterreich/GeoPackage-Hackathon.html
Geopackage is based on SQLite DB, a complex binary format (=disvadvantage for archiving)
The format is not streamable: it must be written to a local file system or most be accessible by a data service
As an alternative if you have to share your data often and don't want to use either Shapefile or Geopackage, consider using a server based geodatabase system like PostGIS.
Also consider this from the official Geopackage website FAQ:
Does GeoPackage replace Shapefile?
It could but it doesn’t have to. If all you need is simple exchange and display then GeoPackage may be overkill and something like GeoJSON may be more appropriate.
And than there is also file geodatabase that is ESRI's solution to the shortcomings of its own Shapefile format. However, file geodatabase has also disadvantages compared to geopackage, see: https://carto.com/blog/fgdb-gpkg/
And, last but not least, see The Ultimate List of GIS Formats and Geospatial File Extensions.
So it looks like the 10 character limit cannot be overcome then– MapDeathJul 14, 2020 at 22:36
Not with shapefiles, correct– BabelJul 14, 2020 at 22:46
That's a really good article you've linked to, it exposes all of the potential problems and comments on the benefits of the shapefile format. I think it's important to mention that the shapefile definition was documented by Esri in 1998 when ArcINFO (workstation) coverage was the major GIS data storage. At that time hard drives were very small in comparison, the CPU was Pentium II, the concept of a 2 GB file was considered ludicrous. Since then shapefiles have become the lowest common denominator for interchange and nobody wants to change the spec as it would destroy interoperability. Jul 15, 2020 at 0:07
Added some information in my answer– BabelJul 15, 2020 at 8:36