Excel: An unsupported SQL data type was encountered

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Excel: An unsupported SQL data type was encountered

Post by mgsteiner »

I got the same error as Sonia in this post and cannot find any workaround.

@Sonia, can you please put the solution you have found to solve this issue?
MGS
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

It may be that you have an ODBC driver for Excel, even though Excel itself is not installed. In that case you can use an ODBC stage.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Post by mgsteiner »

ray.wurlod wrote:It may be that you have an ODBC driver for Excel, even though Excel itself is not installed. In that case you can use an ODBC stage. ...
I'a currently using an ODBC Stage, but I get this error and I have tried to change the data type in the ODBC Stage but the problem remains.

The full error is the following:

Ext2Excel..Transformer_1: |Ext2Excel..ODBC_0.DSLink2: DSD.BCIOpenW call to function SQLPrepare failed.
SELECT MESSAGETYPEID,MESSAGESEVERITY,MESSAGETEXT FROM `Tabelle1$`
SQLSTATE=S1004, DBMS.CODE=0
[DataStage][SQL Client]An unsupported SQL data type was encountered|
MGS
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

That thread was eight years old and Sonia hasn't posted in four. Off to your own post.

:?: The original post was for Parallel jobs but your posts are always for Server jobs... is this a Server job question as well?
-craig

"You can never have too many knives" -- Logan Nine Fingers
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Post by mgsteiner »

Yes . It is server job . DataStage 8.1.2
MGS
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Thanks... corrected and in the proper forum now.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Kryt0n
Participant
Posts: 584
Joined: Wed Jun 22, 2005 7:28 pm

Post by Kryt0n »

What format types have you specified within the Excel sheet?
Try make all columns (at least those you're extracting anyway) type Text (within Excel) and see if it works
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Post by mgsteiner »

No , it doesnt work. Always I receive the same error
Ext2Excel..ODBC_0.DSLink2: DSD.BCIOpenW call to function SQLPrepare failed.
SELECT MESSAGETYPEID FROM `Tabelle1$`
SQLSTATE=S1004, DBMS.CODE=0
[DataStage][SQL Client]An unsupported SQL data type was encountered
Any other tips? :)
MGS
Kryt0n
Participant
Posts: 584
Joined: Wed Jun 22, 2005 7:28 pm

Post by Kryt0n »

Yeah, forget Excel... right royal pita!

Do a table import of your ODBC DSN and use the definition it creates in your job.

While I would truly hope it isn't the cause, you could also try

Code: Select all

SELECT `MESSAGETYPEID` FROM `Tabelle1$`
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Post by mgsteiner »

I have done an ODBC Table Definition Import in DS and used in ODBC Stage to write to it, in oder to have an Excel file with the data from my Hash Table.
Hash_Table --> Transformer --> ODBC Stage (for Excel)
Anyhow can't get it work due to the Data Type error

For what do you suggest a Select stmt when I want to Insert?
MGS
Kryt0n
Participant
Posts: 584
Joined: Wed Jun 22, 2005 7:28 pm

Post by Kryt0n »

Not much really, we had to fiddle around a bit ourselves so can't be sure which bits were right. Did find it liked those funny quotes though (the one below the ~), just make sure the column names match the first row of the excel sheet (your Tabelle1 is the name of a sheet rather than a named section I assume?)
sreewin7
Participant
Posts: 41
Joined: Tue Sep 14, 2010 8:48 pm

Re: Excel: An unsupported SQL data type was encountered

Post by sreewin7 »

Try to check your odbc drive connection and if your execl may be correct, delete and try to do one more time.
mgsteiner
Premium Member
Premium Member
Posts: 42
Joined: Wed Aug 31, 2011 2:56 am
Location: St. Gallen - CH
Contact:

Post by mgsteiner »

Thanks a lot for all suggestions. I will try out and see if I can make it work. The, I will post my results.

Anyhow please, let me know if anybody has any other hint. :)
MGS
Post Reply