6 Replies Latest reply on Sep 24, 2012 7:50 AM by shawkins Branched from an earlier discussion.

    WAS -  From relational to XML (conforming to xschema) - TEIID40011 Processing exception

    gioppoluca

      Ok

      Another problem:

       

      12:31:50,937 WARN  [org.teiid.PROCESSOR] (Worker0_QueryProcessorQueue0) TEIID30020 Processing exception 'Group does not

      exist: bookxml.bookListingDocument' for request SzgS9sMQY42s.0.  Exception type org.teiid.api.exception.query.QueryResol

      verException thrown from org.teiid.query.resolver.util.ResolverUtil.handleUnresolvedGroup(ResolverUtil.java:779). Enable

      more detailed logging to see the entire stacktrace.

       

      As usual I'm trying to execute this basic example and problems seems to run everywhere.

       

      Questions:

      1) How to enable more detailed logging?

       

      Suggested problems origin:

      1) When I map the XML document I follow the document you wrote down and have this  thigs that does not work differently in Designer 7.8

       

      SELECT

              booksDB.aria.books.ISBN, booksDB.aria.books.TYPE, booksDB.aria.books.TITLE, booksDB.aria.publishers.NAME AS publisher, CONVERT(booksDB.aria.books.PUBLISH_YEAR, string) AS publishDate, CONVERT(booksDB.aria.books.EDITION, object) AS edition

          FROM

              booksDB.aria.books, booksDB.aria.publishers

          WHERE

              booksDB.aria.publishers.PUBLISHER_ID = booksDB.aria.books.PUBLISHER

       

      In the Convert function it used to be possible and accepted to use object, now is not proposed in the reconcile transformation function compositor; Could be this the cause of the error?

      In this case how can I convert to ojbect since it is required by the XSD?

       

      In any case the old VDB worked like a charm just the new created with the new Designer has problems.

      I attache the working one "new_libri" and the most recent and not working "BookTest"

       

      Hope that we manage to get it working.

      Luca

        • 1. Re: WAS -  From relational to XML (conforming to xschema) - still not working
          shawkins

          > 1) How to enable more detailed logging?

           

          You would do that in the log4j configuration for the org.teiid logger.  However in this case seeing the stacktrace is really of no benefit as it's a simple resolving error.

           

          > 1) When I map the XML document I follow the document you wrote down and have this  thigs that does not work differently in Designer 7.8

           

          Are you saying this is related to #1?  I don't see a correlation.  Are also you saying that this sql was generated for you automatically and then the transformation editor begins complaining?  If that's the case there is like a Designer issue.  A cast to object should have only been added if the mapping class/view has an edition column of type object.  However that may also be indicative of a Designer issue since an object type is not desirable in xml scenarios.

           

          Steve

          • 2. Re: WAS -  From relational to XML (conforming to xschema) - still not working
            gioppoluca

            Ok try to be more precise.

             

            That error does not happen with new_libri.vdb but happens with BookTest.vdb

             

            So since both VDB user the same MySQL database and schema I'm trying to make the "tiny differences" game and so I come up with:

            - apart from having used different names (which may not be trivial) I've used 7.8 and 7.6 Designer and since I've followed this guide

            https://community.jboss.org/message/724403#724403 (the pdf from Ramesh) and the only thing that I noticed is that during mapping in the XML document the document has an object type (that you fill with book.EDITION converting it to object)

            Since I followed the guide I'm quite sure that in 7.6 I was able to set object in the convert function, now that option is not available (mind I did the first example in july so my mind could fail me). In any case since is possible to modify the sql by hand I did so and designer stopped complaining my conversion of the field to a string where it expected an object.

            To be mode precise the "object" come from the xsd import and XML document creation (as described in the pdf).

             

            Obviously this could be nothing and the problem not be tied to the conversion.

             

            The new_libri.vdb if deployed runs correctly, not so the BookTest cannot understand why?

             

            How that it could be more help.

            Luca

            • 3. Re: WAS -  From relational to XML (conforming to xschema) - still not working
              gioppoluca

              Please any help?

              I doulbechecked and designer 7.8 treat the convert function the same way so also that option is a dead end.

               

              I really cannot give a proper meaning to:

               

              TEIID30020 Processing exception 'Group does notexist

               

              How can I enable more logging?

               

              Luca

              • 4. Re: WAS -  From relational to XML (conforming to xschema) - still not working
                gioppoluca

                OK forget it, that's a dumb of me.

                It was a missing 's' in the query in the name of the virtual table ('bookSxml' and not bookxml).

                It works like a charm.

                Have to stop working late :-D

                Thanks

                Luca

                • 5. Re: WAS -  From relational to XML (conforming to xschema) - still not working
                  gioppoluca

                  Ok Another problem

                  Here is the result of the:

                  Select XMLSERIALIZE("xml" as clob) from (select * from BookXML.bookListingDocument) as x

                  from squirrelsql

                  Any hints?

                  How to enable more logging?

                   

                   

                  12:45:05,371 INFO  [org.teiid.CONNECTOR] (Worker1_QueryProcessorQueue1) MySQL5ExecutionFactory Commi

                  t=true;DatabaseProductName=MySQL;DatabaseProductVersion=5.5.27;DriverMajorVersion=5;DriverMajorVersi

                  on=1;DriverName=MySQL-AB JDBC Driver;DriverVersion=mysql-connector-java-5.1.22 ( Revision: ${bzr.rev

                  ision-id} );IsolationLevel=2

                  12:45:05,979 WARN  [org.teiid.PROCESSOR] (New I/O server worker #2-1) TEIID40011 Processing exceptio

                  n 'TEIID30495 The request HPC1TxnhzZ57.0 has been closed.' for session HPC1TxnhzZ57.  Exception type

                  org.teiid.core.TeiidProcessingException thrown from org.teiid.dqp.internal.process.DQPCore.getReque

                  stWorkItem(DQPCore.java:495). Enable more detailed logging to see the entire stacktrace.

                  12:45:06,047 WARN  [org.teiid.PROCESSOR] (New I/O server worker #2-1) TEIID40011 Processing exceptio

                  n 'TEIID30495 The request HPC1TxnhzZ57.0 has been closed.' for session HPC1TxnhzZ57.  Exception type

                  org.teiid.core.TeiidProcessingException thrown from org.teiid.dqp.internal.process.DQPCore.getReque

                  stWorkItem(DQPCore.java:495). Enable more detailed logging to see the entire stacktrace.

                  • 6. Re: WAS -  From relational to XML (conforming to xschema) - still not working
                    shawkins

                    You can increase logging via the log4j config file, but that will just give you a stacktrace which isn't helpful in this situation.  Teiid does not hold lobs open over a socket connection after the resultset or statement has been closed.  squirrel assumes that it can close the statement after execution, which then gives you those exceptions on the server side when squirrel accesses the lobs later.  To safely display in squirrel, use XMLSERIALIZE("xml" as string)