Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. XML Validation against XSD

XML Validation against XSD

Scheduled Pinned Locked Moved Unsolved General and Desktop
7 Posts 3 Posters 2.3k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Y Offline
    Y Offline
    yeckel
    wrote on 15 Dec 2015, 08:41 last edited by
    #1

    Hi,
    Is there some other Qt way then QXmlSchemaValidator from xmlpatterns how to check XML conforming XSD? Or I have to use external library? (currently xmllint) I'm on Qt4

    I cannot use QXmlSchemaValidator as its allocating all RAM(12GB)+swap and then failing on out of memory. It's generating permutation 11 deep inside Qt code :-/ (Shared between Qt4 and Qt5)

    Thanks.

    1 Reply Last reply
    0
    • J Offline
      J Offline
      jsulm
      Lifetime Qt Champion
      wrote on 15 Dec 2015, 08:44 last edited by
      #2

      12GB of RAM?!
      How big are your XML files?
      Could be a bug in QXmlSchemaValidator.

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      Y 1 Reply Last reply 15 Dec 2015, 09:22
      0
      • J jsulm
        15 Dec 2015, 08:44

        12GB of RAM?!
        How big are your XML files?
        Could be a bug in QXmlSchemaValidator.

        Y Offline
        Y Offline
        yeckel
        wrote on 15 Dec 2015, 09:22 last edited by
        #3

        @jsulm Yes it's some kind if bug in xmlpatterns, my XSD is 15kB and XML ~200kB. 11 is number of attributes in one element and 11! is a lot. That's why I'm looking for some other way, like QXml.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mcosta
          wrote on 15 Dec 2015, 09:56 last edited by
          #4

          Hi,

          have you tried some XML Schema Validator online (for instance this ) to verify if your XSD is correct?

          Once your problem is solved don't forget to:

          • Mark the thread as SOLVED using the Topic Tool menu
          • Vote up the answer(s) that helped you to solve the issue

          You can embed images using (http://imgur.com/) or (http://postimage.org/)

          1 Reply Last reply
          0
          • Y Offline
            Y Offline
            yeckel
            wrote on 15 Dec 2015, 10:02 last edited by
            #5

            Yep It's valid using the online validator, it's valid in Notepad++, It's valid with xmllint.

            1 Reply Last reply
            0
            • M Offline
              M Offline
              mcosta
              wrote on 15 Dec 2015, 10:10 last edited by
              #6

              looks like a bug. I suggest to open a BugReport

              Once your problem is solved don't forget to:

              • Mark the thread as SOLVED using the Topic Tool menu
              • Vote up the answer(s) that helped you to solve the issue

              You can embed images using (http://imgur.com/) or (http://postimage.org/)

              1 Reply Last reply
              0
              • Y Offline
                Y Offline
                yeckel
                wrote on 15 Dec 2015, 10:18 last edited by
                #7

                Yes it's a bug and on Qt4 it will stay so. QTBUG-12534, QTBUG-26824, QTBUG-6485 I' was trying to solve it but it's above my mental abilities :-/ But my question was, is there some other Qt way how to check XML against XSD?

                1 Reply Last reply
                0

                3/7

                15 Dec 2015, 09:22

                • Login

                • Login or register to search.
                3 out of 7
                • First post
                  3/7
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • Users
                • Groups
                • Search
                • Get Qt Extensions
                • Unsolved