C
conradwt
Hi, I was wondering, is it possible to restrict the value of an element
based on the type element? For example,
<mytypes>
<mytype>
<name>value1</name>
<type>double</type>
<value>123.89</value>
</mytype>
<mytype>
<name>value2</name>
<type>integer</type>
<value>123</value>
</mytype>
<mytype>
<name>value3</name>
<type>short</type>
<value>123</value>
</mytype>
</mytypes>
Now, the specification would for the XSD would be as follows:
a) 1 or more 'mytype'
b) 'type' element should constrain 'value'
If anyone has any ideas as to how to develop this in XSD, please post
to the group.
Thanks in advance,
-Conrad
based on the type element? For example,
<mytypes>
<mytype>
<name>value1</name>
<type>double</type>
<value>123.89</value>
</mytype>
<mytype>
<name>value2</name>
<type>integer</type>
<value>123</value>
</mytype>
<mytype>
<name>value3</name>
<type>short</type>
<value>123</value>
</mytype>
</mytypes>
Now, the specification would for the XSD would be as follows:
a) 1 or more 'mytype'
b) 'type' element should constrain 'value'
If anyone has any ideas as to how to develop this in XSD, please post
to the group.
Thanks in advance,
-Conrad