Skip to main content
Solved

Issue with using the XMLUpdater transformer to manipulate Metadata


Forum|alt.badge.img

I'm using the Esri Geodatabase (ArcSDE Geodb) reader with Feature Read Mode set to Metadata, to read in GEMINI metadata from SDE. I'd like to manipulate certain elements before sending the updated metadata back to the SDE feature class.

Using the XMLUpdater I've been able to amend the content for some elements, however I haven't had any success when trying to amend the revision date, as there are three different date strings all with the same XML path:

metadata/gmd:GEMINI_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:citation/gmd:CI_Citation/gmd:date/md:CI_Date/gmd:date/gco:Date

Currently none of them are getting updated on the output XML.

The different date types are differentiated in the gmd:dateType element, e.g:

<gmd:dateType> <gmd:CI_DateTypeCode codeList="http://standards.iso.org/ittf/PubliclyAvailableStandards/ISO_19139_Schemas/resources/Codelist/gmxCodelists.xml#CI_DateTypeCode" codeListValue="revision">Revision</gmd:CI_DateTypeCode> </gmd:dateType>

Has any tried this before, or has any ideas for how to just update one of the dates?

Best answer by itay

Hi @katiem, this ws demonstrates how to update the date tag in your document.

The trick was to get the right syntax for the XML path

issue-with-using-the-xmlupdater-transformer-to-man.fmw

Hope this helps.

View original
Did this help you find an answer to your question?

9 replies

itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • March 29, 2017

Forum|alt.badge.img
  • Author
  • March 30, 2017
itay wrote:
Hi @itay that article is helpful for the general process thanks. However the issue we are having is that the XML path we want to update is duplicated in the metadata and we're not sure how to isolate the specific one we want to update. There are three elements within the metadata, each one has the same XML path and they are only differentiated in the contents of the <gmd:dateType> element...

 


itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • March 30, 2017
katiem wrote:
Hi @itay that article is helpful for the general process thanks. However the issue we are having is that the XML path we want to update is duplicated in the metadata and we're not sure how to isolate the specific one we want to update. There are three elements within the metadata, each one has the same XML path and they are only differentiated in the contents of the <gmd:dateType> element...

 

Can you supply a sample of the metadata?

 

 


Forum|alt.badge.img
  • Author
  • March 30, 2017
itay wrote:
Can you supply a sample of the metadata?

 

 

Sure, this is the particular section.

 

 


itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • March 30, 2017
katiem wrote:

Sure, this is the particular section.

 

 

I actually mean a file...that way ppl can test different solutions.

 

 


Forum|alt.badge.img
  • Author
  • March 30, 2017
itay wrote:
Can you supply a sample of the metadata?

 

 

Here's the file: metadata-date-question.xml

 

 


itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • Best Answer
  • March 30, 2017

Hi @katiem, this ws demonstrates how to update the date tag in your document.

The trick was to get the right syntax for the XML path

issue-with-using-the-xmlupdater-transformer-to-man.fmw

Hope this helps.


Forum|alt.badge.img
  • Author
  • March 30, 2017
itay wrote:

Hi @katiem, this ws demonstrates how to update the date tag in your document.

The trick was to get the right syntax for the XML path

issue-with-using-the-xmlupdater-transformer-to-man.fmw

Hope this helps.

Thanks that's exactly what I needed, we were missing the number in the XML path. Have loaded the updated metadata back into SDE successfully with the help of this article: https://knowledge.safe.com/articles/787/writing-xml-metadata-to-geodatabase.html

 

 


itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • March 30, 2017
katiem wrote:
Thanks that's exactly what I needed, we were missing the number in the XML path. Have loaded the updated metadata back into SDE successfully with the help of this article: https://knowledge.safe.com/articles/787/writing-xml-metadata-to-geodatabase.html

 

 

 

Glad I could help.

Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings