E2 and merging SUBTYPE_CONSTRAINTs

Wilson, Peter R peter.r.wilson at boeing.com
Wed May 8 12:10:44 EDT 2002


All,

    In the body of the DAM it gives a simple explanation of how TOTAL_OVER
constraints are merged from different SUBTYPE_CONSTRAINTs for the same
entity, but there is no hint as to how supertype_expressions are merged,
just a pointer to an Appendix, which does not give a hint either, rather a
complicated algorithm. It would be most helpful if the body at least
outlined what is meant to happen.

    From reading the DAM I end up mentally replacing TOTAL_OVER by
AT_LEAST_ONEOF. Looked at in this light, TOTAL_OVER(a, b, c) can be replaced
by (a ANDOR b ANDOR c). Doing this, then the DAM says that the two
SUBTYPE_CONSTRAINTs:
SUBTYPE_CONSTRAINT sc1 FOR p;
  TOTAL_OVER(f,m);
END...
and
SUBTYPE_CONSTRAINT sc2 FOR p;
  TOTAL_OVER(a,c);
END...
are merged to:
SUBTYPE_CONSTRAINT merged1 FOR p;
  (f ANDOR m) AND (a ANDOR c);
END...
 That is TOTAL_OVERs are merged by ANDing them in ED1 terminology.

    Further, the body of the DAM makes it clear that:
SUBTYPE_CONSTRAINT sc3 FOR p;
  <expression>;
  TOTAL_OVER(f, m);
END...
is equivalent to:
SUBTYPE_CONSTRAINT equiv1 FOR p;
  <expression> AND (f ANDOR m);
END...

    It is not clear to me how expressions are meant to be combined.
SUBTYPE_CONSTRAINT sc4 FOR p;
  <expression4>;
END...
and
SUBTYPE_CONSTRAINT sc5 FOR p;
  <expression5>;
END...
can be combined as
SUBTYPE_CONSTRAINT sc45 FOR p;
  <expression4> ? <expression5>;
END...
where ? is some operator. The TOTAL_OVER examples suggest it is "AND", but
is it? The options seem to be "AND", or "ANDOR" or ";" (the last of which
begs the point).
   
    My concerns about the above have arisen from two things:

1) Given an existing supertype entity, S, with some ONEOF subtypes (A, B)
specifified in a SUBTYPE_CONSTRAINT for S, how to add a new subtype, C, for
S and additional SUBTYPE_CONSTRAINT for S to make the resulting overall
constraint ONEOF(A, B, C)?

2) The proposed algorithm ("Guidance for generating long-form EXPRESS
schemas for all editions of EXPRESS", Feeney, Haenisch, Price and Wasmer,
2001/08/27) for short to long forms includes an Ed2 to Ed1 algorithm, which
suggests creating a RULE to represent a TOTAL_OVER. As I am in principle
against RULEs except under dire circumstances I was looking for a non-RULE
method of mapping TOTAL_OVERs. I think that mapping them as a regular (a
ANDOR ...) constraint does the job better, or am I missing something?

Peter W.


Dr Peter R. Wilson
Boeing Commercial Airplanes
PO Box 3707, MS 6H-AF, Seattle, WA 98124-2207
(Package Delivery: MS 6H-AF, 1601 E. Valley Frontage Road, Renton, WA 98055)
Tel: (425) 237-3506, Fax: (425) 237-3428
Email: peter.r.wilson at boeing.com
--------------------------------
Any opinions expressed above are personal;
they shall not be construed as representative of any organisation.
--------------------------------
 



More information about the wg11 mailing list