Forums: Define.xml
First of all, there are no "columns" in define.xml (it is XML). There only are columns in the VIEW of the define.xml generated by the stylesheet. Some of these columns (like the "Origin / Source / Method / Comment" column combine information from different places in the define.xml. That's something I personally don't like, but has been done as regulatory reviewers often forget to scroll to the right to see "more" information. You are however always free to change/improve the stylesheet according to your preferences. Also do not forget that the stylesheet has parameters by which, by passing parameter values for them, you can steer the behaviour when creating the HTML. Examples are the "displayMethodsTable" and "displayCommentsTable" parameters.
According to the Define-XML specification, comments (def:CommentDef) can be associated with (i.e. referenced by): MetaDataVersion, ItemGroupDef, ItemDef, def:WhereClauseDef, def:Standard, CodeList. But it is up to you to decide where to put the comment on, but some "black box" software packages may take that decision away from you. If you would use a WYSIWYG software, i.e. a software with graphical user interface, you would be able to decide yourself where the comment exactly applies to.
Coming back to your question, an example file or snippet would be very helpful. You can also always contact me for further discussion (I am one of the developers of the Define-XML 2.1 standard). My mail address is easy to find out.
This sounds like the same problem we reported a few months back. If there are 2 Assigned variables and no Derived variables, the WhereClauseDef element is generated with the def:CommentOID attribute from the second Assigned variable- which means that comment appears for all Assigned variables, in addition to the comment actually associated with that variable, when viewed with the stylesheet.
It appears to be something that the Pinnacle 21 folks need to fix, as it occurs when producing the Define-XML using the P21 Define v2.1 spreadsheet template, and there doesn't seem to be any way to avoid it. The comment should not be attached to the WhereClauseDef element.
Thanks,
Nancy
Maybe you should use good software that has a graphical user interface (GUI) and works with wizards and is not "black box" and does not start from Excel?
In case anyone else is curious....
https://www.pinnacle21.com/forum/repeat-comments-when-converting-excel-spec-definexml
we have identified this issue while creating define using the excel of pinnacle community versions of 4.00 and above. as of now we are creating a define first using 4.00 version and changing it to 3.1.2 version to get the excel of that version and creating define again. This eliminates the duplicate columns as the 3.00 versions doesn't have this issue. But regardless we are consciously going back and forth to solve the duplicates in VLM, it would be helpful if it could be updated with the latest version of pinnacle.
I am generating a v2.1 define file from the workbook. I have where clauses on my ValueLevel tab that are the same for various variables within a domain, but with different comment values in the comment column. For most of the variables where the Origin is Assigned and the Source is Sponsor, I either get two of the same comment or two different comments. The comments are ones that are associated with the value in the where clause just not necessarily for the current variable. I have looked at the XML and I can't see the duplicate comments in there, but it also looks like the comment is associated with the where clause and not with the combination of the where clause and the variable. The original define.xml that I created the spec from was generated in Enterprise. I don't have Enterprise. When I change nothing in the workbook generated for the original define and recreate the define, there are also duplicate comments there were not in the original. Thoughts?