Is it valid to have a 'choice' of 'group' elements when defining an XML Schema (XSD)

i.e. is the following valid

<xs:complexType name="HeaderType">
  <xs:sequence>
    <xs:element name="reservation-number" type="ReservationNumberType" minOccurs="1" maxOccurs="1" nillable="false" />
    <xs:choice minOccurs="1" maxOccurs="1">
      <xs:group ref="ReservationGroup" />
      <xs:group ref="CancellationGroup"/>
    </xs:choice>
  </xs:sequence>
</xs:complexType>

Where an XML message can represent, for example, either a new reservation or a cancellation of an existing reservation.

If the message is for a reservation, then it must include all the elements defined in the ReservationGroup group.

If it is a cancellation, then it must include all the elements defined in the CancellationGroup group.

For some reason, my XML editor (Eclipse) does not like this, but does not indicate why. It shows there being an error on the line <xs:complexType name="HeaderType"> but does not say what the error is

Edit
Report