Skip to main content

Hi,

I am trying to read features from a DB/2 database using an ODBC connection. This is the statement that throws an error;

 

Database Generated Error Information:
Database Error Message: >IBM]bSystem i Access ODBC Driver]SDB2 for i5/OS]SQL0104 - Token ] is ongeldig. Geldige tokens: ( NEW FINAL TABLE UNNEST LATERAL XMLTABLE JSON_TABLE <IDENTIFIER>.
Database SQL Statement Text: SELECT * FROM .BZSAART00] WHERE 1=0

 

The problem seems to be with the e ] around the table name. When I use an SQL executor without the  ] it works just fine However since the attributes might differ (I want to loop thru 27 tables to read it's content) using an sqlexecutor is not an option since the attributes to expose will differ per table.

 

Anyone knows a way to get the featurereader to use the right syntax? Is this a bug?

 

Regards,

Alex

 

 

 

 

@alex_apeldoorn,

Thanks for posting this question. A few clarifications; 1) are you using the DB2 Reader in the FeatureReader? Have you attempted this? 2) What version of FME Desktop are you using? 3) What is the DB2 Database version and what is the version of DB2 ODBC Driver are you using?


Hi @steveatsafe

 

I tried the ODBC reader and the regular feature reader. As far as i know the DB/2 reader doesnt support ODBC connections. Since I am connecting to a cloud database and this option isn't offered it's not an option for me.

I am using FME desktop 2019.0.0.1 and I don't know the DB/2 version.. Like i said it's a cloud solution so they didn't provide me that info. The ODBC driver I use is IBM iaccess ODBC driver version 13.64.22.0

 

Regards

Alex


Hi @steveatsafe

 

I tried the ODBC reader and the regular feature reader. As far as i know the DB/2 reader doesnt support ODBC connections. Since I am connecting to a cloud database and this option isn't offered it's not an option for me.

I am using FME desktop 2019.0.0.1 and I don't know the DB/2 version.. Like i said it's a cloud solution so they didn't provide me that info. The ODBC driver I use is IBM iaccess ODBC driver version 13.64.22.0

 

Regards

Alex

The DB/2 in the past was just an ODBC connection under the hood. You would create a DSN on your system and this is referenced in FME using the DB/2 Database. We've worked with DB/2 cloud instances so it should work in that way.

Here's some information for configuring DB/2 ODBC Connection. If you find these are no longer valid please let us know.

Another option is the JDBC Format. See this KB for information. Using FME JDBC Connectivity.

Here's another KB Question that wasn't solved by the looks of it but I think it was due to a 32bit vs 64bit processes.

 

If you are still stuck, perhaps if you can create a case at www.safe.com/support and address SteveatSafe in the description I can help you out with this configuration.

 

 


Reply