Welcome Guest! Log in
×

Notice

The forum is in read only mode.
Due to some maintenance operations, stambia.org will be switched to read-only mode during the 13th November. It will be possible to read and download, but impossible to post on the forums or create new accounts. For any question please contact the support team.

Topic-icon Question Creating a mapping to write into a sheet

More
15 Feb 2016 17:00 - 15 Feb 2016 17:01 #1 by letancel
letancel created the topic: Creating a mapping to write into a sheet
Hi,

I am trying to insert data in an Excel sheet.
I have a really simple Mapping with two objects:
- In source : a SQL Server table
- In target : an Excel sheet (from an excel file I reversed)

I followed the "Getting started with Stambia's JDBC Excel Driver", and did everything mentioned in the tutorial, but when I execute the mapping, I get an error during the Integration part (Load of data) :
com.indy.engine.common.exceptions.EngineExceptionI: Exception for source column 1 and target column 1
at com.indy.engine.actionCodes.JdbcActionCodeI.a(SourceFile:598)
at com.indy.engine.actionCodes.JdbcActionCodeI.executeTrgDirectBindedInsert(SourceFile:695)
at com.indy.engine.actionCodes.JdbcActionCodeI.executeDirectBindedFetch(SourceFile:1005)
at com.indy.engine.action.common.ActionCodeTypeI.executeDirectBindedCode(SourceFile:1399)
at com.indy.engine.action.common.ActionCodeTypeI.executeBindedCode(SourceFile:1565)
at com.indy.engine.action.common.ActionCodeTypeI.executeCode(SourceFile:1630)
at com.indy.engine.action.common.ActionCodeTypeI.run(SourceFile:1805)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.UnsupportedOperationException
at com.stambia.jdbc.driver.xls.xls.XlsPrepareStatement.setNString(Unknown Source)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setNString(DelegatingPreparedStatement.java:238)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setNString(DelegatingPreparedStatement.java:238)
at com.indy.engine.actionCodes.convert.JdbcConverter.convertString(JdbcConverter.java:110)
at com.indy.engine.actionCodes.convert.JdbcConverter$4.write(JdbcConverter.java:709)
at com.indy.engine.actionCodes.convert.JdbcConverter$4.write(JdbcConverter.java:1)
at com.indy.engine.actionCodes.loader.a.a(SourceFile:113)
at com.indy.engine.actionCodes.JdbcActionCodeI.a(SourceFile:586)
... 7 more

The "Load of data" generated code is :
insert into "ErrorFichierRetourMAJadmin"."Feuil1$"
(
"file_name",
"date_creation",
"type_enregistrement",
"ref_externe",
"num_ordre_dem",
"donnees"
)
values
(
:{L1_file_name}:,
:{L2_date_creation}:,
:{L3_type_enregistrement}:,
:{L4_ref_externe}:,
:{L5_num_ordre_dem}:,
:{L6_donnees}:

)

I could not find a way to resolve it, do you have any idea?

Thx
Last Edit: 15 Feb 2016 17:01 by letancel.
More
16 Feb 2016 10:13 #2 by Thomas BLETON
Thomas BLETON replied the topic: Creating a mapping to write into a sheet
Hi :)
It seems to be related to the datatypes.
Can you please try to disable some columns in the mapping, in order to find which one is concerned by the error ? And then please tell me what are the source/target datatypes for this column.
More
16 Feb 2016 10:59 #3 by letancel
letancel replied the topic: Creating a mapping to write into a sheet
Hi,

I did disable the columns one by one but it still doesn't work..
Same error, same message "com.indy.engine.common.exceptions.EngineExceptionI: Exception for source column 1 and target column 1"
I'm mapping Nvarchar type from source to Varchar type on the target, so I don't understand what I'm doing wrong
More
16 Feb 2016 11:25 - 28 Sep 2016 16:13 #4 by Thomas BLETON
Thomas BLETON replied the topic: Creating a mapping to write into a sheet
Oh, it seems strange and deserves a particular analysis.
Please send to the support team:
- your Designer version number
- your Runtime version number
- a copy of your mapping, metadata, and target Excel file

They will look into this ;)
Last Edit: 28 Sep 2016 16:13 by Thomas BLETON.