Specs I have seen for civilian aviation and military aviation have lots of complex dependencies. Other formats, not so much. Lots of applications leave these sorts of semantics-level checking up to applications.
However, in most cases our first version of a schema for such formats leaves out the co-dependency checks. They are often expressed in some ad-hoc notation, and generating them automatically from specifications/spec-databases is challenging. It would be typical if real de-facto data violates some of them, just as de-facto data often differs in small ways from the "layout" part of the format specifications. I am somewhat skeptical of the total correctness of such co-constraints. Obviously a really comprehensive DFDL schema for such a format has to implement the co-constraints as XSD 1.1 or Schematron rules, or as DFDL asserts (with failureType="recoverableError"). These complex co-constraints really bring into focus the notion of "well formed" vs. "valid", as the data can be parsed without the co-constraints, so it is well-formed, just not necessarily fully-valid unless these constraints are checked. On Fri, Sep 15, 2023 at 12:36 PM Roger L Costello <coste...@mitre.org> wrote: > Hi Folks, > > I am reading a large data specification. It is a well-written > specification. It describes each field in the data format. Many fields have > co-dependencies: if this field has value A, then that field must have value > B. That is a simple co-dependency. Most of the co-dependencies are much > more complex. And there are thousands of these complex co-dependencies. > Because of all the co-dependencies, the data format quickly became very > hard (for me) to understand. > > What's been your experience with real world data formats? Has each field > been standalone (no co-dependencies) or have many of the fields been > dependent on other fields? Do most real-world data formats contain lots of > complex co-dependencies? A data format is certainly easier to understand > when there were no co-dependencies. But maybe that's just not the way it is > in the real world. What has been your experience? > > /Roger >