9 Replies Latest reply on Nov 30, 2016 10:31 AM by Steven Hawkins

    teiid not supporting Sql Server datatype [varchar] (max).

    Kulbhushan Chaskar Master

      Hi,

       

      I am firing insert query on a sql server database, query trying to insert a data into the column having datatype [varchar](max) .

      but teiid throwing exception

      "org.teiid.jdbc.TeiidSQLException: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sqlServerConn: 0 TEIID11013:TEIID11004 Error executing statement(s): [Prepared Values: ['org.teiid.core.types.ClobImpl@21d6c677'] SQL: INSERT INTO "Instance"."anyName"."tableName" ("id", "name", "mobile") VALUES (1, ?, 1)]"

       

      Stack trace:-

      org.teiid.jdbc.TeiidSQLException: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sqlServerConn: 0 TEIID11013:TEIID11004 Error executing statement(s): [Prepared Values: ['org.teiid.core.types.ClobImpl@21d6c677'] SQL: INSERT INTO "instance"."anyName"."tableName" ("id", "name", "mobile") VALUES (1, ?, 1)]

        at org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:135)

        at org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:71)

        at org.teiid.jdbc.StatementImpl.postReceiveResults(StatementImpl.java:703)

        at org.teiid.jdbc.StatementImpl.access$100(StatementImpl.java:64)

        at org.teiid.jdbc.StatementImpl$2.onCompletion(StatementImpl.java:542)

        at org.teiid.client.util.ResultsFuture.done(ResultsFuture.java:135)

        at org.teiid.client.util.ResultsFuture.access$200(ResultsFuture.java:40)

        at org.teiid.client.util.ResultsFuture$1.receiveResults(ResultsFuture.java:79)

        at org.teiid.net.socket.SocketServerInstanceImpl.receivedMessage(SocketServerInstanceImpl.java:268)

        at org.teiid.net.socket.SocketServerInstanceImpl.read(SocketServerInstanceImpl.java:306)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

        at java.lang.reflect.Method.invoke(Unknown Source)

        at org.teiid.net.socket.SocketServerConnectionFactory$ShutdownHandler.invoke(SocketServerConnectionFactory.java:98)

        at com.sun.proxy.$Proxy30.read(Unknown Source)

        at org.teiid.net.socket.SocketServerInstanceImpl$RemoteInvocationHandler$1.get(SocketServerInstanceImpl.java:405)

        at org.teiid.jdbc.StatementImpl.executeSql(StatementImpl.java:551)

        at org.teiid.jdbc.StatementImpl.executeUpdate(StatementImpl.java:1088)

        at org.teiid.jdbc.StatementImpl.executeUpdate(StatementImpl.java:344)

        at java.util.Optional.ifPresent(Unknown Source)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

        at java.lang.reflect.Method.invoke(Unknown Source)

        at org.apache.wink.server.internal.handlers.InvokeMethodHandler.handleRequest(InvokeMethodHandler.java:63)

        at org.apache.wink.server.handlers.AbstractHandler.handleRequest(AbstractHandler.java:33)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.CreateInvocationParametersHandler.handleRequest(CreateInvocationParametersHandler.java:54)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.FindResourceMethodHandler.handleSubResourceMethod(FindResourceMethodHandler.java:183)

        at org.apache.wink.server.internal.handlers.FindResourceMethodHandler.handleRequest(FindResourceMethodHandler.java:110)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.FindRootResourceHandler.handleRequest(FindRootResourceHandler.java:95)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.HeadMethodHandler.handleRequest(HeadMethodHandler.java:53)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.OptionsMethodHandler.handleRequest(OptionsMethodHandler.java:46)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.handlers.SearchResultHandler.handleRequest(SearchResultHandler.java:33)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.log.ResourceInvocation.handleRequest(ResourceInvocation.java:92)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.internal.log.Requests.handleRequest(Requests.java:76)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)

        at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)

        at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:63)

        at org.apache.wink.server.handlers.AbstractHandlersChain.run(AbstractHandlersChain.java:48)

        at org.apache.wink.server.internal.RequestProcessor.handleRequestWithoutFaultBarrier(RequestProcessor.java:207)

        at org.apache.wink.server.internal.RequestProcessor.handleRequest(RequestProcessor.java:154)

        at org.amdatu.web.rest.wink.WinkFilterManager.handleRequest(WinkFilterManager.java:119)

        at org.amdatu.web.rest.wink.WinkFilter$1.run(WinkFilter.java:62)

        at org.amdatu.web.rest.wink.WinkFilter$1.run(WinkFilter.java:1)

        at java.security.AccessController.doPrivileged(Native Method)

        at org.amdatu.web.rest.wink.WinkFilter.doFilter(WinkFilter.java:55)

        at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:108)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:80)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:84)

        at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:46)

        at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:31)

        at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:76)

        at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:49)

        at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)

        at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:808)

        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:587)

        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:221)

        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1127)

        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)

        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)

        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)

        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)

        at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:215)

        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)

        at org.eclipse.jetty.server.Server.handle(Server.java:497)

        at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:310)

        at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:257)

        at org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:540)

        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)

        at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)

        at java.lang.Thread.run(Unknown Source)

      Caused by: org.teiid.core.TeiidProcessingException: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sqlServerConn: 0 TEIID11013:TEIID11004 Error executing statement(s): [Prepared Values: ['org.teiid.core.types.ClobImpl@21d6c677'] SQL: INSERT INTO "instance"."anyName"."tableName" ("id", "name", "mobile") VALUES (1, ?, 1)]

        at org.teiid.dqp.internal.process.DataTierTupleSource.exceptionOccurred(DataTierTupleSource.java:401)

        at org.teiid.dqp.internal.process.DataTierTupleSource.nextTuple(DataTierTupleSource.java:161)

        at org.teiid.query.processor.relational.AccessNode.nextBatchDirect(AccessNode.java:374)

        at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:282)

        at org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:145)

        at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:151)

        at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:114)

        at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:164)

        at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:146)

        at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:470)

        at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:348)

        at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51)

        at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:274)

        at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:276)

        at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119)

        at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

        ... 1 more

      Caused by: org.teiid.core.TeiidException: 0 Remote org.teiid.translator.jdbc.JDBCExecutionException: 0 TEIID11013:TEIID11004 Error executing statement(s): [Prepared Values: ['org.teiid.core.types.ClobImpl@21d6c677'] SQL: INSERT INTO "instance"."anyName"."tableName" ("id", "name", "mobile") VALUES (1, ?, 1)]

        at org.teiid.translator.jdbc.JDBCUpdateExecution.executeTranslatedCommand(JDBCUpdateExecution.java:276)

        at org.teiid.translator.jdbc.JDBCUpdateExecution.execute(JDBCUpdateExecution.java:84)

        at org.teiid.dqp.internal.datamgr.ConnectorWorkItem$1.execute(ConnectorWorkItem.java:394)

        at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:356)

        at sun.reflect.GeneratedMethodAccessor84.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

        at java.lang.reflect.Method.invoke(Unknown Source)

        at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:211)

        at com.sun.proxy.$Proxy57.execute(Unknown Source)

        at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:306)

        at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:112)

        at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108)

        at java.util.concurrent.FutureTask.run(Unknown Source)

        at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:65)

        ... 6 more

      Caused by: java.sql.SQLFeatureNotSupportedException: Remote java.sql.SQLFeatureNotSupportedException: IJ031042: Method is not implemented by JDBC driver

        at org.jboss.jca.adapters.jdbc.WrappedConnection.checkException(WrappedConnection.java:1930)

        at org.jboss.jca.adapters.jdbc.WrappedStatement.checkException(WrappedStatement.java:1437)

        at org.jboss.jca.adapters.jdbc.WrappedPreparedStatement.setCharacterStream(WrappedPreparedStatement.java:1470)

        at org.teiid.translator.jdbc.JDBCExecutionFactory.bindValue(JDBCExecutionFactory.java:934)

        at org.teiid.translator.jdbc.sybase.BaseSybaseExecutionFactory.bindValue(BaseSybaseExecutionFactory.java:147)

        at org.teiid.translator.jdbc.JDBCBaseExecution.bind(JDBCBaseExecution.java:107)

        at org.teiid.translator.jdbc.JDBCUpdateExecution.executeTranslatedCommand(JDBCUpdateExecution.java:250)

        ... 19 more

      Caused by: java.lang.AbstractMethodError: Remote java.lang.AbstractMethodError: null

        at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.setCharacterStream(JtdsPreparedStatement.java:1274)

        at org.jboss.jca.adapters.jdbc.WrappedPreparedStatement.setCharacterStream(WrappedPreparedStatement.java:1466)

        ... 23 more