The Update Section is parsed into RRs and these RRs are processed in order.
188.8.131.52. If any system failure (such as an out of memory condition, or a hardware error in persistent storage) occurs during the processing of this section, signal SERVFAIL to the requestor and undo all updates applied to the zone during this transaction.
184.108.40.206. Any Update RR whose CLASS is the same as ZCLASS is added to the zone. In case of duplicate RDATAs (which for SOA RRs is always the case, and for WKS RRs is the case if the ADDRESS and PROTOCOL fields both match), the Zone RR is replaced by Update RR. If the TYPE is SOA and there is no Zone SOA RR, or the new SOA.SERIAL is lower (according to [RFC1982]) than or equal to the current Zone SOA RR's SOA.SERIAL, the Update RR is ignored. In the case of a CNAME Update RR and a non-CNAME Zone RRset or vice versa, ignore the CNAME Update RR, otherwise replace the CNAME Zone RR with the CNAME Update RR.
220.127.116.11. For any Update RR whose CLASS is ANY and whose TYPE is ANY, all Zone RRs with the same NAME are deleted, unless the NAME is the same as ZNAME in which case only those RRs whose TYPE is other than SOA or NS are deleted. For any Update RR whose CLASS is ANY and whose TYPE is not ANY all Zone RRs with the same NAME and TYPE are deleted, unless the NAME is the same as ZNAME in which case neither SOA or NS RRs will be deleted.
18.104.22.168. For any Update RR whose class is NONE, any Zone RR whose NAME, TYPE, RDATA and RDLENGTH are equal to the Update RR is deleted, unless the NAME is the same as ZNAME and either the TYPE is SOA or the TYPE is NS and the matching Zone RR is the only NS remaining in the RRset, in which case this Update RR is ignored.
22.214.171.124. Signal NOERROR to the requestor.
126.96.36.199. Table Of Metavalues Used In Update Section
CLASS TYPE RDATA Meaning --------------------------------------------------------- ANY ANY empty Delete all RRsets from a name ANY rrset empty Delete an RRset NONE rrset rr Delete an RR from an RRset zone rrset rr Add to an RRset
188.8.131.52. Pseudocode For Update Section Processing
[rr] for rr in updates if (rr.class == zclass) if (rr.type == CNAME) if (zone_rrset<rr.name, ~CNAME>) next [rr] elsif (zone_rrset<rr.name, CNAME>) next [rr] if (rr.type == SOA) if (!zone_rrset<rr.name, SOA> || zone_rr<rr.name, SOA>.serial > rr.soa.serial) next [rr] for zrr in zone_rrset<rr.name, rr.type> if (rr.type == CNAME || rr.type == SOA || (rr.type == WKS && rr.proto == zrr.proto && rr.address == zrr.address) || rr.rdata == zrr.rdata) zrr = rr next [rr] zone_rrset<rr.name, rr.type> += rr elsif (rr.class == ANY) if (rr.type == ANY) if (rr.name == zname) zone_rrset<rr.name, ~(SOA|NS)> = Nil else zone_rrset<rr.name, *> = Nil elsif (rr.name == zname && (rr.type == SOA || rr.type == NS)) next [rr] else zone_rrset<rr.name, rr.type> = Nil elsif (rr.class == NONE) if (rr.type == SOA) next [rr] if (rr.type == NS && zone_rrset<rr.name, NS> == rr) next [rr] zone_rr<rr.name, rr.type, rr.data> = Nil return (NOERROR)