In data load, it seems some XML attributes mapped incorrectly and I\'m now trying to correct this, but am struggling with MySQL\'s handling of this XML column.
I wan
UPDATE biblioitems
SET marcxml = UpdateXML(marcxml,'datafield[@tag="520"]/subfield[@code="3"]/@code',
'code="a"')
WHERE biblionumber = '220405';
Note that the UpdateXML function requires an existing node to be found. If you want to insert an attribute, you have to replace an existing attribute with more than one. for example to insert attribute d in the x element:
select updateXML('