java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'.

Hibernate JIRA | Fabio Parise | 1 decade ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Hibernate try to execute this typical Oracle syntax on my SqlServer 2000 as shown below: my id configuration is: <id name="pkid" type="long" column="pkid" unsaved-value="null"> <generator class="native"> <param name="sequence">seq_pro_aoo</param> </generator> </id> Trace log: Hibernate: select seq_pro_aoo.nextval from dual 13-ago-2003 9.32.40 it.saga.library.persistence.PersistenceConfiguration getSessionFactory INFO: SessionFactory found! 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions AVVERTENZA: SQL Error: 208, SQLState: 42S02 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions GRAVE: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions AVVERTENZA: SQL Error: 16945, SQLState: HY000 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions GRAVE: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]The cursor was not declared. 13-ago-2003 9.32.40 net.sf.hibernate.JDBCException <init> GRAVE: Could not save object java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source) at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSCursorRequest.openCursor(Unknown Source) at com.microsoft.jdbc.sqlserver.SQLServerImplStatement.execute(Unknown Source) at com.microsoft.jdbc.base.BaseStatement.commonExecute(Unknown Source) at com.microsoft.jdbc.base.BaseStatement.executeQueryInternal(Unknown Source) at com.microsoft.jdbc.base.BasePreparedStatement.executeQuery(Unknown Source) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at net.sf.hibernate.id.SequenceGenerator.generate(SequenceGenerator.java:61) at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:599) at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1202) at it.saga.library.persistence.PersistentStatelessBean.save(PersistentStatelessBean.java:179) at it.saga.pubblici.protocollo.impl.BLGProAOOBean.save(BLGProAOOBean.java:38) at BLGProAOO_StatelessSessionBeanWrapper30.save(BLGProAOO_StatelessSessionBeanWrapper30.java:180) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:119) at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48) at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:803) at java.lang.Thread.run(Thread.java:536) 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC]Database changed to Protocollo 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Changed database context to 'Protocollo'. 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC]Language changed to us_english 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Changed language setting to us_english. java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source) at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source)

    Hibernate JIRA | 1 decade ago | Fabio Parise
    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'.
  2. 0

    Hibernate try to execute this typical Oracle syntax on my SqlServer 2000 as shown below: my id configuration is: <id name="pkid" type="long" column="pkid" unsaved-value="null"> <generator class="native"> <param name="sequence">seq_pro_aoo</param> </generator> </id> Trace log: Hibernate: select seq_pro_aoo.nextval from dual 13-ago-2003 9.32.40 it.saga.library.persistence.PersistenceConfiguration getSessionFactory INFO: SessionFactory found! 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions AVVERTENZA: SQL Error: 208, SQLState: 42S02 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions GRAVE: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions AVVERTENZA: SQL Error: 16945, SQLState: HY000 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logExceptions GRAVE: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]The cursor was not declared. 13-ago-2003 9.32.40 net.sf.hibernate.JDBCException <init> GRAVE: Could not save object java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source) at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSCursorRequest.openCursor(Unknown Source) at com.microsoft.jdbc.sqlserver.SQLServerImplStatement.execute(Unknown Source) at com.microsoft.jdbc.base.BaseStatement.commonExecute(Unknown Source) at com.microsoft.jdbc.base.BaseStatement.executeQueryInternal(Unknown Source) at com.microsoft.jdbc.base.BasePreparedStatement.executeQuery(Unknown Source) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at com.evermind.sql.FilterPreparedStatement.executeQuery(FilterPreparedStatement.java:271) at net.sf.hibernate.id.SequenceGenerator.generate(SequenceGenerator.java:61) at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:599) at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1202) at it.saga.library.persistence.PersistentStatelessBean.save(PersistentStatelessBean.java:179) at it.saga.pubblici.protocollo.impl.BLGProAOOBean.save(BLGProAOOBean.java:38) at BLGProAOO_StatelessSessionBeanWrapper30.save(BLGProAOO_StatelessSessionBeanWrapper30.java:180) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:119) at com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java:48) at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:803) at java.lang.Thread.run(Thread.java:536) 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC]Database changed to Protocollo 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.40 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Changed database context to 'Protocollo'. 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC]Language changed to us_english 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: SQL Warning: 0, SQLState: 13-ago-2003 9.32.41 net.sf.hibernate.util.JDBCExceptionReporter logWarnings AVVERTENZA: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Changed language setting to us_english. java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'. at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source) at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) at com.microsoft.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source)

    Hibernate JIRA | 1 decade ago | Fabio Parise
    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'.

    Root Cause Analysis

    1. java.sql.SQLException

      [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Invalid object name 'dual'.

      at com.microsoft.jdbc.base.BaseExceptions.createException()
    2. com.microsoft.jdbc
      TDSRPCRequest.processReplyToken
      1. com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source)
      2. com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)
      3. com.microsoft.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source)
      4. com.microsoft.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source)
      5. com.microsoft.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source)
      5 frames