Skip to main content
Question

How to Update/Write File Geodatabase Metadata

  • May 20, 2026
  • 4 replies
  • 89 views

phoeffler
Supporter
Forum|alt.badge.img+9

I’m able to update metadata elements in multiple feature classes within esri file geodatabases using the very helpful article at Working with Geodatabase Metadata: Writing/Updating Metadata – FME Support Center. This gets me most of the way to where I need to be.

After reading through the article and numerous posts on the Community, I’m stuck on how to use this or another workflow to update the metadata for the file geodatabase itself. There is metadata associated with each feature class, but there is also geodatabase-level metadata.

The FeatureReader using the Metadata Feature Read Mode was new to me - very useful, along with the XMLUpdater and the methods outlined in the article. But it seems to only work for the contents of a geodatabase. 

Any thoughts on how to work with the metadata on the container, as well?

Thanks in advance.

4 replies

j.botterill
Influencer
Forum|alt.badge.img+58
  • Influencer
  • May 21, 2026

You used be able to control this on a writer parameter for Esri geodatabase. Now I think this has changed in 2026.1 fme, following this article Working with Geodatabase Metadata: Writing/Updating Metadata – FME Support Center

 

You may need to transform it into XML within format attributes using XMLTemplater, AttributeManager  set required attributes

  • geodb_metadata_string = your XML here
  • geodb_type = geodb_metadata

 

On a reader you can change the read mode over = Metadata


phoeffler
Supporter
Forum|alt.badge.img+9
  • Author
  • Supporter
  • May 21, 2026

I’m currently using 2025.1.2 and my experience aligns with what is shown in the referenced article.

I’m not sure if you’re indicating that there are changes at the 2026 versions that will make this process more difficult or not - I hope not.

This is currently simple and effective for sanitizing a problematic metadata element (/metadata/Esri/DataProperties/itemProps/itemLocation/linkage) that is not editable within ArcGIS Pro or by exporting, editing, and importing the metadata, so a real security/privacy benefit to overcome a defect in the esri format and software:

User Parameters specify the feature classes to have their metadata updated and the metadata element replacement value.

In ArcGIS Pro, one can View or Edit the Metadata for feature classes within an Esri file geodatabase, but also for the file geodatabase itself. Since the geodatabase is not read in as a feature type, I don’t see a way to edit its metadata.

Hopefully that helps to clarify the issue a bit.

Appreciate the discussion on it.


phoeffler
Supporter
Forum|alt.badge.img+9
  • Author
  • Supporter
  • June 1, 2026

@LizAtSafe, I know that updating the metadata for a file geodatabase itself is outside of the scope of your article, but thought I’d see if you had any thoughts on how this might be accomplished?


jamatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • June 10, 2026

Hi ​@phoeffler ,

Sorry for the delayed reply and thanks for your patience. The current options available can only extract XML metadata at the Feature Type (Feature Class table) level. Unfortunately there isn't currently a native option for reading metadata at the file geodatabase container level yet.

Since there doesn’t appear to be an existing FME Idea for this, I’d recommend submitting one and outlining your intended use cases. This allows other users to upvote, help raise visibility with our developers, and gauge interest for future support.

As a workaround, you can use ArcPy to access file geodatabase level metadata. As per Esri's documentation, the Metadata class exposes the XML via xml property so you can use PythonCaller transformers in FME to extract that metadata and write it back.

Note: This requires ArcGIS Pro installed on the same machine. You will also need to point FME's Python interpreter to ArcGIS Pro's Python environment under Workspace Parameters > Scripting > Python Compatibility > Esri ArcGis Python 3.x

Read XML Write/Save XML
import fme
from fme import BaseTransformer
import fmeobjects
import arcpy
from arcpy import metadata as md

gdb_path = r'PATH TO YOUR GDB'
gdb_md = md.Metadata(gdb_path)

class FeatureProcessor(BaseTransformer):

def input(self, feature: fmeobjects.FMEFeature):
pass

def close(self):
output = fmeobjects.FMEFeature()
output.setAttribute('metadata_xml', gdb_md.xml)

self.pyoutput(output)
import fme
from fme import BaseTransformer
import fmeobjects
import arcpy
from arcpy import metadata as md

gdb_path = r'PATH TO YOUR GDB'

class FeatureProcessor(BaseTransformer):

def input(self, feature: fmeobjects.FMEFeature):
gdb_md = md.Metadata(gdb_path)
gdb_md.xml = feature.getAttribute("YOUR XML ATTRIBUTE NAME")
gdb_md.save()
self.pyoutput(feature)

def close(self):
pass

 

  • Replace gdb_path with your geodatabase path.
  • Replace gdb_path with your geodatabase path.
  • Replace feature.getAttribute(“”) with the attribute containing your updated XML.

 

The first PythonCaller should output a metadata_xml attribute containing the file geodatabase level metadata. From there, you can follow the article you linked and use XML transformers such as XMLFormatter or XMLUpdater to modify the XML. Once you're done, a second PythonCaller can write the updated XML back to the geodatabase.

For more details, I'd recommend referring to Esri's documentation on the Metadata class. Hope this helps!