Announcement

Collapse
No announcement yet.

Can I ignore node attributes when comparing xml files

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Can I ignore node attributes when comparing xml files

    I am using the XML Tidied compare which works great. Except in the use case for my users, the attributes are irrelevent. Can I ignore attribute differences, or not even show the attributes at all? Thanks.

  • #2
    Not with the built-in XML grammar rules. But BC3 is highly configurable. It sounds like you have a special-case need that could be handled by creating a new file format for XML files with new grammar rules.
    BC v4.0.7 build 19761
    ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

    Comment


    • #3
      Thanks

      Thanks Michael, sounds like exactly what I need. Do you have a link that would get me started on a new file comparison format configuration?

      Thanks fellow Pennsylvanian!

      Comment


      • #4
        The references to grammar in the BC3 help file are quite high-level, so I don't think they will be of much help. If you have some sample files (left side/right side XML) for me to look at, I might be able to provide some guidance.
        BC v4.0.7 build 19761
        ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

        Comment


        • #5
          Thanks

          Thanks Michael. Do you mean sample xml files that I am trying to compare?

          Comment


          • #6
            Originally posted by jhoppppppp View Post
            Do you mean sample xml files that I am trying to compare?
            Yes
            BC v4.0.7 build 19761
            ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

            Comment


            • #7
              Okay attached are two example files. You can rename them to .xml


              Thanks!

              Comment


              • #8
                That looks pretty easy and straight forward to me. Try this:

                Click on Session Settings icon (referee)
                Click the Edit Grammar... button
                Click the New... button
                element name: id
                category: Delimited
                text from: id="id-
                text to: "
                Click OK
                Move new grammar element to top of list
                Click OK
                Under Importance tab, remove checkmark from new id grammar element
                Click OK

                If you don't want to see the unimportant differences at all, click the Ignore Unimportant Differences button on the toolbar: []
                BC v4.0.7 build 19761
                ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

                Comment


                • #9
                  Thanks for the Help!

                  Comment

                  Working...
                  X