Hello, I found that the SqlMap.xsd is incomplete. The original SqlMap.xsd
states that an sql element can not have an "include" sub-element which is not
true. In fact the example code snippet below is perfectly legal and working.
<sql id="TestTable_SelectFields">
SELECT Id, description
</sql>
<sql id="TestTable_BaseSQL">
<include refid="TestTable_SelectFields" />
FROM TestTable
</sql>
I updated the schema with:
<xs:element name="sql">
<xs:complexType mixed="true">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="include"/>
<xs:element ref="dynamic"/>
<xs:element ref="isEmpty"/>
<xs:element ref="isEqual"/>
<xs:element ref="isGreaterEqual"/>
<xs:element ref="isGreaterThan"/>
<xs:element ref="isLessThan"/>
<xs:element ref="isLessEqual"/>
<xs:element ref="isNotEmpty"/>
<xs:element ref="isNotEqual"/>
<xs:element ref="isNotNull"/>
<xs:element ref="isNotParameterPresent"/>
<xs:element ref="isNotPropertyAvailable"/>
<xs:element ref="isNull"/>
<xs:element ref="isParameterPresent"/>
<xs:element ref="isPropertyAvailable"/>
<xs:element ref="iterate"/>
</xs:choice>
<xs:attribute name="id" type="xs:string" use="required"/>
</xs:complexType>
</xs:element>
Regards,
Andrea