This question follows from $area gives NULL for some polygons in QGIS's Field Calculator. New question asks the same question as to why some area variables appear NULL. But the problem was resolved for one layer but not the other.

All $areas are found except for the polygon in the screenshot. The larger polygon and smaller polygon are over-wrapped but are separate entries. Area for smaller entry is found but not the bigger one. I tried fixing geometries but it does not help. Please let me know how I can proceed.

I am using the layer, all economic concessions (English) from the link: https://data.opendevelopmentcambodia.net/dataset/economiclandconcessions

enter image description here

  • I am working on this as well. give me some time to go through this. if I found any solution I will answer. this is more interesting than the previous one. Jan 26, 2021 at 12:44
  • 1
    @uditha, Thank you so much.
    – JessicaP
    Jan 26, 2021 at 12:45
  • 2
    it is probably an invalid polygon
    – Ian Turton
    Jan 26, 2021 at 13:13
  • yes sir, several of them are invalid because the attribute table entries are nor accompanied with geometries @Ian Turton . But in several of them have area values exceeding whole number integer maximum limit. Jan 26, 2021 at 13:27

1 Answer 1


Short Answer

since the $area calculated exceeding the value of the displayable limit of the whole number integer with in field calculator please use output field type as whole number integer 64 bit with maximum output field length of 21

(whole number integer 64 bit and 21 field size is a must)

Long Answer

Please refer the previous answer HERE for the CRS Change and all up to step 4

  1. go to the Attribute Table of the newly created shapefile
  2. Go to Field Calculator
  3. And enter $area in the Expression Field while giving a name to the column with data type whole number integer 64 bit (whole number integer 64 bit and 21 field size is a must)
  4. then give the output field length as 21 (maximum possible)

enter image description here

  1. and click ok
  2. your attribute table should look like this

enter image description here

again as previous areas with unknown geometry will not display any area

enter image description here

  • 1
    or create a float number field, as it's country areas, just divide the area by 1 000 000 to have square kilometers : round($area / 1000000, 2). Jan 26, 2021 at 14:11
  • 1
    @J.Monticolo yes, this is also can be done. with this we can go with whole number integer as well. Jan 26, 2021 at 14:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.