The publish generates the <MyInfo/> tag, but we need to have the tag removed when there is no data, because our application will reject the tag.
What TDM Portal log(s) in debug mode do you need? I have no access to copy the logs from the server. I can only cut and paste content from the log files. I also have to scrub the log content.
I can’t send the actual XML, XSD nor screen captures but sent samples that are scrubbed below with the relevant information.
FYI: MyInfo table exists in the XML if a calculated field in another table is greater than zero.
TDM Table: MyInfo
Datatype : string
Nullable : False
Validation Rules: pattern : (01|02|03|04|05|06|07|08|09|10|11|12|21|22|23|24|25|26|27|28|29|30|31|32)[0-9]{7}
Function: @if(1=2,~NOVALUE~,027100238)@
Datatype : string
Nullable : True
Validation Rules: enumeration : Other
Datatype : string
Nullable : True
Validation Rules: maxLength : 17; pattern : [A-Za-z0-9\-]+
Function: @if(1=2,~NOVALUE~,A0017235698234)@
<MyInfo/> When all fields are empty or have ~NOVALUE~, the end tag should not exist in the XML file.
This is the XSD.
<!—My Info -->
<xsd:element name="MyInfo" minOccurs="0">
<xsd:annotation>
<xsd:documentation>
<xsd:Description>My Info</xsd:Description>
</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:sequence>
<!-- Choice between Rout No or Other -->
<xsd:choice minOccurs="0">
<!-- Rout No-->
<xsd:element name="RoutNo" type="RoutNoType">
<xsd:annotation>
<xsd:documentation>
<xsd:Description>Rout No</xsd:Description>
</xsd:documentation>
</xsd:annotation>
</xsd:element>
<!-- Other-->
<xsd:element name="OtherCd" minOccurs="0">
<xsd:annotation>
<xsd:documentation>
<xsd:Description>Check</xsd:Description>
</xsd:documentation>
</xsd:annotation>
<xsd:simpleType>
<xsd:restriction base="StringType">
<xsd:enumeration value="Other"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:choice>
<!-- Acct No-->
<xsd:element name="AcctNo" type="AcctNoType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>
<xsd:Description>Acct No</xsd:Description>
</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
Release : 4.9
Component : CA Test Data Manager