Loading ...
Sorry, an error occurred while loading the content.

mysql_stmt_execute error ?

Expand Messages
  • Rob
    Hello - just getting set up to use xml-dbms - but I ran into this error. Any ideas? I run the transfer tool as follows on the test files (I have only edited
    Message 1 of 2 , Oct 17, 2006
    View Source
    • 0 Attachment
      Hello - just getting set up to use xml-dbms - but I ran into this
      error. Any ideas?

      I run the transfer tool as follows on the test files (I have only
      edited the db.props file) as follows

      java org.xmlmiddleware.xmldbms.tools.Transfer File1=parser.props
      File2=db.props Method=StoreDocument MapFile=orders.map
      XMLFile=orders.xml ActionFile=orders1.act

      My db.props file:

      #Properties for XML-DBMS
      URL=jdbc:mysql://localhost/test_xmltodbms
      Driver=com.mysql.jdbc.Driver
      DataSourceClass=org.xmlmiddleware.db.JDBC1DataSource
      User=root
      Password=*******

      I am running mysql version 4.1.2


      Errors:

      java.sql.SQLException: Incorrect arguments to mysql_stmt_execute
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2975)
      at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1600)
      at
      com.mysql.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:1125)
      at
      com.mysql.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:677)
      at
      com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1357)
      at
      com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1274)
      at
      com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1259)
      at
      org.xmlmiddleware.db.SPPreparedStatement.executeUpdate(SPPreparedStatement.java:92)
      at
      org.xmlmiddleware.xmldbms.datahandlers.DataHandlerBase.updateOrInsert(DataHandlerBase.java:190)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.storeRow(DOMToDBMS.java:1328)
      at
      org.xmlmiddleware.xmldbms.DOMToDBMS.processClassRow(DOMToDBMS.java:552)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.processRow(DOMToDBMS.java:881)
      at
      org.xmlmiddleware.xmldbms.DOMToDBMS.processRowChild(DOMToDBMS.java:849)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.processChild(DOMToDBMS.java:693)
      at
      org.xmlmiddleware.xmldbms.DOMToDBMS.processChildren(DOMToDBMS.java:630)
      at
      org.xmlmiddleware.xmldbms.DOMToDBMS.processClassRow(DOMToDBMS.java:544)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.processRoot(DOMToDBMS.java:447)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.processRoot(DOMToDBMS.java:477)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.storeDocument(DOMToDBMS.java:368)
      at org.xmlmiddleware.xmldbms.DOMToDBMS.storeDocument(DOMToDBMS.java:317)
      at
      org.xmlmiddleware.xmldbms.tools.Transfer.storeDocumentInternal(Transfer.java:840)
      at
      org.xmlmiddleware.xmldbms.tools.Transfer.storeDocument(Transfer.java:479)
      at
      org.xmlmiddleware.xmldbms.tools.Transfer.dispatchStoreDocument(Transfer.java:696)
      at org.xmlmiddleware.xmldbms.tools.Transfer.dispatch(Transfer.java:434)
      at org.xmlmiddleware.xmldbms.tools.Transfer.main(Transfer.java:353)
    • Ronald Bourret
      Hello, There is no obvious reason that this is happening. Here s a few things you might try: 1) Make sure you ve created the tables in the database. XML-DBMS
      Message 2 of 2 , Oct 17, 2006
      View Source
      • 0 Attachment
        Hello,

        There is no obvious reason that this is happening. Here's a few things
        you might try:

        1) Make sure you've created the tables in the database. XML-DBMS does
        not do this for you -- it maps between an existing XML document (schema)
        and an existing relational schema.

        2) Comment out the two Action elements from orders1.act so that only
        inserts are performed. (The Action elements are telling XML-DBMS to
        first attempt to update the Parts and Customers tables if the specified
        part / customer already exists. Perhaps this causes a problem with MySQL
        when they don't exist, although I can't imagine why.)

        3) If neither of the above works, modify the makeUpdate method in
        DataHandlerBase to print out the SQL statements that are being executed
        and check that these are valid for MySQL. You can also add statements to
        check that the correct parameters are being set. You would do all of
        this in the code after the if statement.

        -- Ron

        Rob wrote:

        > Hello - just getting set up to use xml-dbms - but I ran into this
        > error. Any ideas?
        >
        > I run the transfer tool as follows on the test files (I have only
        > edited the db.props file) as follows
        >
        > java org.xmlmiddleware.xmldbms.tools.Transfer File1=parser.props
        > File2=db.props Method=StoreDocument MapFile=orders.map
        > XMLFile=orders.xml ActionFile=orders1.act
        >
        > My db.props file:
        >
        > #Properties for XML-DBMS
        > URL=jdbc:mysql://localhost/test_xmltodbms
        > Driver=com.mysql.jdbc.Driver
        > DataSourceClass=org.xmlmiddleware.db.JDBC1DataSource
        > User=root
        > Password=*******
        >
        > I am running mysql version 4.1.2
        >
        >
        > Errors:
        >
        > java.sql.SQLException: Incorrect arguments to mysql_stmt_execute
        > at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2975)
        > at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1600)
        > at
        > com.mysql.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:1125)
        > at
        > com.mysql.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:677)
        > at
        > com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1357)
        > at
        > com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1274)
        > at
        > com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1259)
        > at
        > org.xmlmiddleware.db.SPPreparedStatement.executeUpdate(SPPreparedStatement.java:92)
        > at
        > org.xmlmiddleware.xmldbms.datahandlers.DataHandlerBase.updateOrInsert(DataHandlerBase.java:190)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.storeRow(DOMToDBMS.java:1328)
        > at
        > org.xmlmiddleware.xmldbms.DOMToDBMS.processClassRow(DOMToDBMS.java:552)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.processRow(DOMToDBMS.java:881)
        > at
        > org.xmlmiddleware.xmldbms.DOMToDBMS.processRowChild(DOMToDBMS.java:849)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.processChild(DOMToDBMS.java:693)
        > at
        > org.xmlmiddleware.xmldbms.DOMToDBMS.processChildren(DOMToDBMS.java:630)
        > at
        > org.xmlmiddleware.xmldbms.DOMToDBMS.processClassRow(DOMToDBMS.java:544)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.processRoot(DOMToDBMS.java:447)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.processRoot(DOMToDBMS.java:477)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.storeDocument(DOMToDBMS.java:368)
        > at org.xmlmiddleware.xmldbms.DOMToDBMS.storeDocument(DOMToDBMS.java:317)
        > at
        > org.xmlmiddleware.xmldbms.tools.Transfer.storeDocumentInternal(Transfer.java:840)
        > at
        > org.xmlmiddleware.xmldbms.tools.Transfer.storeDocument(Transfer.java:479)
        > at
        > org.xmlmiddleware.xmldbms.tools.Transfer.dispatchStoreDocument(Transfer.java:696)
        > at org.xmlmiddleware.xmldbms.tools.Transfer.dispatch(Transfer.java:434)
        > at org.xmlmiddleware.xmldbms.tools.Transfer.main(Transfer.java:353)
      Your message has been successfully submitted and would be delivered to recipients shortly.