How to show geodatabase calculated area and length in meters from WGS84 FC?

2535
7
Jump to solution
02-19-2018 05:26 AM
ClaudioRuschel
New Contributor III

All feature classes of my enterprise geodatabase have a standard configuration using a geographic coordinate system (GCS_SIRGAS_2000, that is similar to WGS 84). ESRI applications that are able to access the geodatabase, like ArcGIS Desktop, automatically show area and length (for polygons feature classes) calculated in degrees, that is useless. How can I configure the geodatabase to show these properties in meters without reprojecting the features?

0 Kudos
1 Solution

Accepted Solutions
XanderBakker
Esri Esteemed Contributor

Maybe a little further ahead it will be possible to use Arcade expression (in Pro, not ArcMap) to leverage the

Geometry Functions | ArcGIS for Developers .

This is already possible in ArcGIS Online:

Using:

return Text(AreaGeodetic(Geometry($feature), 'square-kilometers'),"0.000") + " km²";

and:

return Text(LengthGeodetic(Geometry($feature), 'kilometers'), "0.000") + " km";

View solution in original post

7 Replies
JoshuaBixby
MVP Esteemed Contributor

ESRI applications that are able to access the geodatabase, like ArcGIS Desktop, automatically show area and length (for polygons feature classes)

Can you elaborate on which tools and/or functionality you are using when viewing area and length information?  The Identify Tool, Measure Tool, etc....?

Your data is obviously in geographic, what spatial reference is your data frame?

0 Kudos
ClaudioRuschel
New Contributor III

In ArcMap, this behavior appears in the Attribute Table and Identify Tool.

It doesn't matter about the Data Frame Coordinate System or Display Units

that are configured. The values shown are always the same, as calculated

for the reference system defined for the feature class.

2018-02-19 16:53 GMT-03:00 Joshua Bixby <geonet@esri.com>:

GeoNet <https://community.esri.com/?et=watches.email.thread>

Re: How to show geodatabase calculated area and length in meters from

WGS84 FC?

reply from Joshua Bixby

<https://community.esri.com/people/bixb0012?et=watches.email.thread> in

Geodatabase - View the full discussion

<https://community.esri.com/message/751542-re-how-to-show-geodatabase-calculated-area-and-length-in-meters-from-wgs84-fc?commentID=751542&et=watches.email.thread#comment-751542>

0 Kudos
JoshuaBixby
MVP Esteemed Contributor

I am not sure what back-end data store you are using (shape file, file database, enterprise geodatabase, etc...), but all of them have a default area and length field that default to the units of the data set's coordinate system.  One can Add Geometry Attributes—Help | ArcGIS Desktop , in this case AREA_GEODESIC and PERIMETER_LENGTH_GEODESIC, to give accurate measurements in meters.

In terms of Data Frame coordinate system, it does matter for some tools.  For example, if a data set is geographic but the Data Frame is projected, then the Measure tool (Measuring distances and areas—Help | ArcGIS Desktop ) can be configured to give measurements in projected meters, feet, etc....  Since the Identify tool simply reports what is in the attribute table, the Data Frame coordinate system won't make a difference for it.

ClaudioRuschel
New Contributor III

As mentioned, I´m using an Enterprise Geodatabase (in this case, PostgreSQL), but you can consider the same behaviour for File and Personal Geodatabase. Area and Length columns are automatically shown in the ArcMap view of the attribute table with the original reference system and units. So, my question is if there is a hidden resource to configure the way these values are shown, just like you can configure "GEODESIC" when calculating values.

0 Kudos
JoshuaBixby
MVP Esteemed Contributor

No.

For enterprise geodatabases, the default shape area and length fields are not actually stored, they are dynamically generated by calling the corresponding spatial accessor function.  For PostgreSQL, the area one sees in the attribute table in ArcMap or ArcGIS Pro is the value returned by calling ST_Area on the shape field when the data is loaded into the application.  Although it is possible using SQL to call ST_Transform before calling ST_Area, I don't believe Esri implements such an option through any configuration parameters.  My guess is that part of the reason is how expensive such an operation would be, which would create the perception of slowness to the end user when loading feature classes.

ClaudioRuschel
New Contributor III

Precisely, Joshua. It seems to me that this kind of configuration is not in ESRI´s roadmap yet. 

The solution would be simple using PostGIS. To get the area in square meters just replace ST_Area(geom) with ST_Area(geography(ST_Transform(geom,4326))). I just would like to have a configuration variable that I could adjust the SQL expression.

Thanks,

Cláudio Ruschel

0 Kudos
XanderBakker
Esri Esteemed Contributor

Maybe a little further ahead it will be possible to use Arcade expression (in Pro, not ArcMap) to leverage the

Geometry Functions | ArcGIS for Developers .

This is already possible in ArcGIS Online:

Using:

return Text(AreaGeodetic(Geometry($feature), 'square-kilometers'),"0.000") + " km²";

and:

return Text(LengthGeodetic(Geometry($feature), 'kilometers'), "0.000") + " km";