sudharshan |
Newbie |
|
India |
|
|
None Specified |
|
Friday, March 26, 2021 |
Friday, March 26, 2021 6:39:01 AM |
1 [0.01% of all post / 0.00 posts per day] |
|
Description
Step1: Please open the given mfd and refer Screenshot 1.
Step2: So if we go inside Validationchildparent udf, you can find itemValidationParentCheck(Screenshot 2).
Step3: Inside itemValidationParentCheck We can find the main logic for conditional and mandatory logic for group as I said earlier.(Screenshot 3).
Step4: We can find the TotalDutiableQuantity under ItemQuantity, TotalDutiableQuantity Is conditional whereas unitcode id mandatory according to specs(Screenshot 4).
Step5: Our requirement is we need to perform validation on this parent child relationship, for instance if the parent is present in input xml then we need to go and check the mandatory child(and throw exceptions if no data or tag is their) or else we don't need to check.
Step6: But the issue here is the whole group is repeating, the item in which the TotalDutiableQuantity is present will repeat for 50 times. Refer Screenshot 6 and 7.
Step7: So the validations what we implemented for this parent child is not working feasibly, can anyone suggest a optimized one.
Steps To Reproduce:
step 1: open the mfd file
step 2: add the xsd from the zip file(Input XSD\TN Spec for SDC\TradenetResponse.xsd)
step 3: add the json schema from the zip file(Output Json Schema\Jsonschema..json)
step 4: Add input file from the zip file(Input\DUMMY_T08GA0029H202102095041_TDBI038_INPPMT.xml)
step 5: Generate output -> Exceptions are not thrown clearly if you delete the tag or data in input xml
|
|