Announcement

Collapse
No announcement yet.

xml tidied with attr. sorted does not work for me

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

  • koen
    replied
    sorting first nodes then attributes

    I had a similar issues comparing XML files.
    The new fileformat plugin does not help here.
    I need both the nodes and attributes sorted.
    I tried the new "XML Sorted and tidied", it sorts attributes nicely but not the elements
    See screenshot

    Leave a comment:


  • Aaron
    replied
    Hello Hound Dog,

    Our latest XML sorted and tidied file format is based off of the XSLT provided earlier in this forum post. Are you familiar with a modification that could provide the sorting you need? You are welcome to create copies and modify the external file formats to better meet your needs.

    Update: Link to file formats
    http://www.scootersoftware.com/downl...oreformats_alt

    Do you have a set of XML files and schema you could email to us or post in the forums for us to test with? Our email is [email protected] and if you email us please include a link back to this forum post.

    Leave a comment:


  • Hound Dog
    replied
    BeyondCompare and comparing XSD schemas

    Hi,

    Just following up on this. I've recently encountered a similar problem - I'm trying to compare 2 XSD files. The schemas are generated, and the order of the top-level elements (i.e. xsd:simpleType, xsd:complexType) is different each time. The order of elements within those type definitions (e.g. elements within an xsd:sequence) is the same each time though.

    So while the xsd:simpleType and xsd:complexType elements are in a totally different order, the schemas could semantically be the same. If any element inside a type definition was different in one schema (e.g. 2 elements in an xsd:sequence were in a different order) then the schemas wouldn't be the same.

    We are checking these files into source control, and it is very difficult to determine if the schema has changed or not between each generation.

    Is it possible for BeyondCompare to sort xsd:simpleType and xsd:complexType elements alphabetically, before its passed to HTML Tidy to format it? This way you could easily compare 2 schemas, which would be a very useful feature!

    James

    Leave a comment:


  • Chris
    replied
    Hi Michael,

    I also tried repeating the crash on my own system (Windows Vista Sp2, 32-bit). I used the settings and example files you sent, then followed the steps in your screen cast. The files loaded without conversion errors using all 4 formats.

    Leave a comment:


  • Michael Bulgrien
    replied
    Thanks, Aaron. I will try to run the compare on another box too. The machine on which it is failing is an XP SP3 box with a fairly new installation of BC. I was not an administrator of the system at the time, but I am now. I'll try the compare again now that I'm an administrator to see if it makes any difference.

    Leave a comment:


  • Aaron
    replied
    Yes, sorry for the request. I just wanted to make sure I was working with the whole and correct packet of information. These files are the ones that I have been working with in our email archives, and in my testing I do not see the same behavior as your do. For me, the pair of new files in XML_Sorted.zip all open up fine in all 4 file formats using a fresh portable install of BC3.2.4, after importing your BCSettings and then unzipping your Support package.

    Your previous zip would fail only on one side, due to a syntax error caused by a "<" character. You had since replaced these with "[" characters in the new sample set.

    From your screencast, your conversion seems to fail on both sides, which is not a behavior I have seen using either your settings in BC3.2.4, or originally in my own install.

    I'll try it on another machine as well to see if that will help. One thing you may want to try is to setup a fresh portable install to see if it is reproducible on the same machine or a different one.

    Leave a comment:


  • Michael Bulgrien
    replied
    I don't know why I'm being asked for all of this again.

    On Thursday, February 24, 2011 at 9:31 PM I sent you a mail with screencast and attachments:

    BCSupport.zip
    BCSettings.zip (which included the 4 XML rules)

    On Tuesday, February 22, 2011 9:24 AM I sent you a mail with:

    XML_Sorted.zip

    This zip file is the only zip file that I sent with .xml files instead of .xml.txt files and they are the files that fail to load in my environment.

    If you really need me to resend everything, I will, but it will take me a couple days to do so. I am swamped right now and am going out of town early in the morning.

    Leave a comment:


  • Aaron
    replied
    Reviewing your latest screencast, it looks like you have trouble loading both sides of the comparison. That would certainly make tracking this down a bit more difficult.

    Could you perhaps sent a single email (with a link back to this forum post), including all the separate parts of the equation:
    1) The set of test files
    2) BCSupport.bcpkg
    3) BCSettings.bcpkg including all 4 XML rules

    This way I can make sure I'm dealing with the correct combination of file formats and files. Please send a secondary (no attachment email) letting us know to expect it just in case it is caught by junk mail filters.

    Leave a comment:


  • Aaron
    replied
    Hello Michael,

    Not yet. I have not been able to reproduce any issue with these files.

    I did have one oddity come up during testing:
    At one point, I somehow loaded your files (ExpectedResults.xml) with oddly modified server="lines" which ended with ;gt; or similar text, instead of just ending with "Machine Name". I am not sure how this happened, and I have attempted to reproduce it by using a Portable install with your Support and Settings packages loaded from scratch. I believe it was an older set of files I modified manually or had merged with your original sample files (re-saved with the Tidied variant that relabeled < and > characters).

    In both your original submission with "<" characters and in the latest testing, I have managed to find the problem terminology by switching to Tidied or <default>, and usually one of the first Difference lines has contained the syntax issue. Since Conditions.xml loads fine for all 4 file formats, and ExpectedResults.xml has issues, it must be one of the different lines in ExpectedResults that contains the XML syntax trouble.

    I would like to reiterate that the latest problem I hit (and was able to find and fix by deleting ;gt I have not been able to reproduce. I just mention it as an example in finding syntax problems with XML files. In your last batch of example files, I am able to open them in all four file formats without issue.

    Could you include or email a screenshot of the first different section when your files are loaded using the Tidied format and/or Default format? Perhaps our data sets are out of sync.

    Leave a comment:


  • Michael Bulgrien
    replied
    Any updates?

    Leave a comment:


  • Aaron
    replied
    Thanks. I see the more recent email, and we'll investigate as soon as we can.

    I believe I've found the older email as well, but I was not sure they were the exact files used in this forum post.

    Leave a comment:


  • Michael Bulgrien
    replied
    I had already sent the file pair several days ago, but got no response. I've resent the files.

    Leave a comment:


  • Aaron
    replied
    Hello Michael,

    Thanks for the suggestion.

    Would you be able to send in this pair of sample files to [email protected] ? Please include a link to this forum post for reference.

    Leave a comment:


  • Michael Bulgrien
    replied
    XML Tidied with Attributes Sorted

    First of all, let me say that "XML Tidied with Attributes Sorted" is an awesome plug-in.
    However, when two nodes have exactly the same attributes, it would be helpful if the nodes would be sorted by alphabetically:

    http://screencast.com/t/y6oXRCtV5l
    http://screencast.com/t/xlbSZ6mB

    This might need to be accomplished in two steps:
    1. Sort the Attributes
    2. then Sort the Nodes alphabetically


    Both XML Sorted and XML Sorted and Tidied blow up on my files:

    http://screencast.com/t/QFOvV05f
    http://screencast.com/t/NbW8pCHghRg
    Last edited by Michael Bulgrien; 08-Feb-2011, 12:07 PM.

    Leave a comment:


  • Aaron
    replied
    Hello,

    We've recently added an "XML Sorted and Tidied" file format to our external conversions page based on a general xslt and conversion program. We would be very interested in any feedback:
    http://www.scootersoftware.com/downl...kb_moreformats

    Leave a comment:

Working...
X