Topic
3 replies Latest Post - ‏2011-12-22T15:26:13Z by kevintap
CodyBurleson
CodyBurleson
3 Posts
ACCEPTED ANSWER

Pinned topic Cannot convert unknown JDBC type ID of "-9"

‏2011-12-22T10:33:41Z |
When attempting to use a SQL Data Services Provider against an Microsoft SQL JDBC connection (which uses Microsoft SQL JDBC driver 3.0), Portlet Factory provides the following error. I tried with both connection pool and XA datasource defined in WAS; neither makes a difference. Does anybody know what this might be caused by and some work-around? Thanks in advance for any tips!

This Builder Call caused the following exception: Cannot convert unknown JDBC type ID of "-9".
com.bowstreet.webapp.engine.WebAppRuntimeException: Cannot convert unknown JDBC type ID of "-9".
at com.bowstreet.builders.webapp.methods.SqlUtilities.toJdbcType(SqlUtilities.java:320)
at com.bowstreet.builders.webapp.methods.SqlUtilities.generateInsertStatement(SqlUtilities.java:787)
at com.bowstreet.builders.webapp.SqlDataServicesBuilder.createCreateOp(SqlDataServicesBuilder.java:509)
at com.bowstreet.builders.webapp.SqlDataServicesBuilder.doBuilderCall(SqlDataServicesBuilder.java:265)
at com.bowstreet.builders.webapp.foundation.WebAppGenHandler.doBuilderCall(WebAppGenHandler.java:477)
at com.bowstreet.generation.implementation.BaseGenContext.internalInvokeBuilder(BaseGenContext.java:201)
at com.bowstreet.generation.implementation.BaseGenContext.performGenerationPhase(BaseGenContext.java:513)
at com.bowstreet.generation.GenerationManager.generate(GenerationManager.java:183)
at com.bowstreet.generation.GenerationManager.generate(GenerationManager.java:82)
at com.bowstreet.designer.model.ModelAccess.generate(ModelAccess.java:194)
at com.bowstreet.designer.model.ModelContext.generate(ModelContext.java:550)
at com.bowstreet.designer.model.ModelContext.access$100(ModelContext.java:71)
at com.bowstreet.designer.model.ModelContext$1.runInUIThread(ModelContext.java:333)
at org.eclipse.ui.progress.UIJob$1.run(UIJob.java:95)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4041)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3660)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:620)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:575)
at org.eclipse.equinox.launcher.Main.run(Main.java:1408)
SCACServiceProvider.model /NMGOPS_Manage_SCAC/WebContent/WEB-INF/models/scac/providers/db SQL Data Services:SCACDataServices WebSphere Portlet Factory Builder Error
Updated on 2011-12-22T15:26:13Z at 2011-12-22T15:26:13Z by kevintap
  • CodyBurleson
    CodyBurleson
    3 Posts
    ACCEPTED ANSWER

    Re: Cannot convert unknown JDBC type ID of "-9"

    ‏2011-12-22T11:00:11Z  in response to CodyBurleson
    Note that all of the datatypes in the table I am accessing with the SQL Data Services are of type nvarchar.
    • CodyBurleson
      CodyBurleson
      3 Posts
      ACCEPTED ANSWER

      Re: Cannot convert unknown JDBC type ID of "-9"

      ‏2011-12-22T11:40:39Z  in response to CodyBurleson
      I now think that it is because Experience Factory is not coded to support the nvarchar type from Microsoft SQL. After switching my columns to just varchar, it works fine. I will open a issue with IBM.
      • kevintap
        kevintap
        41 Posts
        ACCEPTED ANSWER

        Re: Cannot convert unknown JDBC type ID of "-9"

        ‏2011-12-22T15:26:13Z  in response to CodyBurleson
        You are correct. The NVARCHAR column type is not supported/known by Web Experience Factory. This is a relatively new type in SQL Server. The constant type codes in java.sql.Types for NVARCHAR are only present in Java 1.6 and above. Web Experience Factory maintains compatibility for Java 1.5, so support for this column type has not yet been added, as it would require a minimum Java version of 1.6.