Forums: Define.xml
I constructed a test file trying to reproduce the problem. It contains:
<def:SupplementalDoc>
<def:DocumentRef leafID="LF.ReviewersGuide"/>
<def:DocumentRef leafID="LF.ComplexAlgorithms"/>
<!-- added for testing, see https://www.pinnacle21.com/forum/dd0078-document-not-referenced -->
<def:DocumentRef leafID="LF.TEST"/>
</def:SupplementalDoc>
and:
<def:CommentDef OID="COM.ARMCD">
<Description>
<TranslatedText xml:lang="en">Assigned based on Randomization Number. See Note 2.1</TranslatedText>
</Description>
<def:DocumentRef leafID="LF.ReviewersGuide"/>
<!-- added for testing - see https://www.pinnacle21.com/forum/dd0078-document-not-referenced -->
<def:DocumentRef leafID="LF.TEST"/>
and:
<def:leaf ID="LF.TEST" xlink:href="test.pdf">
<def:title>test</def:title>
</def:leaf>
and then tested it: Results:
Pinnacle21 Validator: DD0084 Variable=File Values=test.pdf Message=Referenced File is missing
And indeed, the "test.pdf" was not in the same directory. When I added it, the warning disappears.
I could reproduce your warning DD078 when I removed (or commented out) the entry under def:SupplementalDoc, i.e.:
<def:SupplementalDoc>
<def:DocumentRef leafID="LF.ReviewersGuide"/>
<def:DocumentRef leafID="LF.ComplexAlgorithms"/>
<!-- added for testing, see https://www.pinnacle21.com/forum/dd0078-document-not-referenced -->
<!--def:DocumentRef leafID="LF.TEST"/-->
</def:SupplementalDoc>
so what you probably forgot, was to also add "LF.TEST" under def:SupplementalDoc.
Can you check and let us know?
With best regards,
Jozef Aerts
CDISC Define-XML development team
Jozef did a nice job explaining the warning in P21. However, I do not think there is a rule in the specification that says that every document referenced, has to be part of the def:SupplementalDoc element.
Think about Analysis Results Metadata, where there can be many, many referenced code files. Why should they all be listed in the def:SupplementalDoc element? The def:leaf elements already contain all referenced files, if one needs to know all files referenced.
The main use I have seen for the def:SupplementalDoc element is to list the documents that get displayed in the bookmarks section of the display of the XML with the XSL stylesheet.
Lex Jansen
CDISC Define-XML Dev team
Hi,
My understanding of original post by Gopalakrishna is "Does Define-XML standard allow to have multiple references to different external documents within a single method or comment?" Text in Define-XML documentations not clear.
DD0078 check requires all documents in define.xml file to have any reference in CommentDef:, MethodDef: or def:SupplementalDoc.
Here is an example below. LF.TEST (test.pdf) document is defined and used only as a second reference to external documents in method MT.AGE.
P21C tool does not recognize this LF.TEST reference and complains that define.xml does not use this “test.pdf” document.
It's interesting that a standard stylesheet provided as a part of Define-XML package does not recognize the second reference as well and represents it as the first document ("complexalgorithms.pdf") referenced in Method definition.
Kind Regards,
Sergiy
...
<def:SupplementalDoc>
<def:DocumentRef leafID="LF.ReviewersGuide"/>
<def:DocumentRef leafID="LF.ComplexAlgorithms"/>
</def:SupplementalDoc>
…
<MethodDef OID="MT.AGE" Name="Algorithm to derive AGE" Type="Computation">
<Description>
<TranslatedText xml:lang="en">Age at Screening Date (Screening Date - Birth date). For the complete algorithm see the referenced external document.</TranslatedText>
</Description>
<def:DocumentRef leafID="LF.ComplexAlgorithms">
<def:PDFPageRef PageRefs="DM" Type="NamedDestination"/>
</def:DocumentRef>
<def:DocumentRef leafID="LF.TEST">
<def:PDFPageRef PageRefs="2" Type="PhysicalRef"/>
</def:DocumentRef>
</MethodDef>
...
<def:leaf ID="LF.ReviewersGuide" xlink:href="reviewersguide.pdf">
<def:title>Reviewers Guide</def:title>
</def:leaf>
<def:leaf ID="LF.ComplexAlgorithms" xlink:href="complexalgorithms.pdf">
<def:title>Complex Algorithms</def:title>
</def:leaf>
<def:leaf ID="LF.TEST" xlink:href="test.pdf">
<def:title>Test document</def:title>
</def:leaf>
Thank you for your inputs. Does Define-XML standard allow to have multiple references to same external document [data guide] within a single method or comment?
if we follow the given approach we are not getting warning in the report. But in the left side panel of define xml shows multiple references title [we have only one document called Analysis Reviewers Guide, but referred >1 references in a same method]. Would it be possible to hide multiple references links from left side panel, because referring same document.
Yes, multiple references are allowed from a single comment or method. You should only list the document once in the def:SupplementalDoc element.
Hi Sergiy,
The strange thing is that if the LF.TEST is given as the first document within the method, then PC21 does not report an error.
See below for reference.
<MethodDef OID="MT.AGE" Name="Algorithm to derive AGE" Type="Computation">
<Description>
<TranslatedText xml:lang="en">Age at Screening Date (Screening Date - Birth date). For the complete algorithm see the referenced external document.</TranslatedText>
</Description>
<def:DocumentRef leafID="LF.TEST">
<def:PDFPageRef PageRefs="2" Type="PhysicalRef"/>
</def:DocumentRef>
<def:DocumentRef leafID="LF.ComplexAlgorithms">
<def:PDFPageRef PageRefs="DM" Type="NamedDestination"/>
</def:DocumentRef>
< /MethodDef>
...
Can we expect a fix for the above in PC21.
Define.xml does in fact allow multiple references to different external documents within a single method or comment
For your response
<It's interesting that a standard stylesheet provided as a part of Define-XML package does not recognize the second reference as well and represents it as the first document ("complexalgorithms.pdf") referenced in Method definition.>
Please use the stylesheet that comes with ADaM - ARM package, you can find both the file references.
Thanks,
Saravanan
@Sergi:
Can you make sure from your example above that LF.ComplexAlgorithms is not included in the SupplementalDoc element at the beginning of the file?
I have a feeling it's still declared as a supplemental document and therefore considered referenced already.
For clarity, there is also a business rule for the def:DocumentRef element that says "If multiple documents are provided there will be multiple def:DocumentRef child elements within the def:SupplementalDoc element." -Page 59 of the Define 2 spec. Following this Business rule will remove all unexpected DD0078 issues.
@GMcDevitt
Below is a excerpt from the CDISC-ADaM example.
Here, there is no def:DocumentRef for LF.ADQSADAS.PGM within the def:SupplementalDoc, and PC21 does not give any issues.
<def:CommentDef OID="COM.ADQSADAS">
<Description>
<TranslatedText>See referenced dataset creation program and Analysis Data Reviewer's Guide, Section 2.1</TranslatedText>
</Description>
<def:DocumentRef leafID="LF.ADQSADAS.PGM"/>
<def:DocumentRef leafID="LF.ADRG">
<def:PDFPageRef PageRefs="Section2.1" Type="NamedDestination"/>
</def:DocumentRef>
</def:CommentDef>
The problem putting this within the def:SupplementalDoc element is that, it shows up in the left panel of the define.xml
Is there a way to have a reference a document in methods/comments, but not specify in def:SupplementalDoc
What I am trying to achieve is something like this below.(providing links to different sections of adrg)
using below
<def:SupplementalDoc>
<def:DocumentRef leafID="LF.ADRG"/>
</def:SupplementalDoc>
...
<MethodDef OID="MT.ADAE.AOCC01FL" Name="MT.ADAE.AOCC01FL" Type="Computation">
<Description>
<TranslatedText>Subset to CQ01NAM='' and TRTEMFL='Y' and sort by Subject (USUBJID), Start Date (ASTDT), and Sequence Number (AESEQ) and flag the first record (set AOCC01FL='Y') within each Subject (Flag First Treatment Emergent Dermatological Event for Time to Event Analysis). Refer Sections </TranslatedText>
</Description>
<def:DocumentRef leafID="LF.ADRG1">
<def:PDFPageRef PageRefs="Section2.1" Type="NamedDestination"/>
</def:DocumentRef>
<def:DocumentRef leafID="LF.ADRG2">
<def:PDFPageRef PageRefs="Section8.1" Type="NamedDestination"/>
</def:DocumentRef>
</MethodDef>
...
<def:leaf ID="LF.ADRG1" xlink:href="../dummy-csr/adrg.pdf">
<def:title>Analysis Data Reviewer's Guide Section2.1</def:title>
</def:leaf>
<def:leaf ID="LF.ADRG2" xlink:href="analysis-data-reviewers-guide.pdf">
<def:title>Analysis Data Reviewer's Guide Section8.1</def:title>
</def:leaf>
Thanks,
Saravanan
Hi Saravan,
Actually Gerard (@GMcDevitt) agrees with you. He proposed some simple short-term solution for users who want to avoid/hide false-positive DD0078 messages. It's enough to put a reference to a document into <def:SupplementalDoc>.
Regards,
Sergiy
Manipulating a machine-readable submission document for the sake of avoiding a false positive error or a problem with the stylesheet, is never a good idea. When people start doing this for define.xml, they will also start doing in SDTM and ADaM datasets.
It is the software that should be changed, not the correct (Define-XML compliant) document.
Hi,
Scenario: There are more than one reference to dataguide for a method/comment. There is a warning message [DD0078] while validating generated define xml in Pinnacle21 V2.2.0. If we are giving more than one sections/links referred in a same comment / method then it seems Pinnacle21 considers the first data guide reference and list the remaining links are "Document <document> is not referenced" in the exception report. Please confirm whether Pinnacle21 takes the first hyperlink in a comment/method and ignore the further links in the same comment.