IBM Support

ODBC Error after upgrade to Impromptu 5 - TRANSOFT

Troubleshooting


Problem

Error "[51][Transoft][TSODBC][usqlsd]'FROM' expected here (c1)" when attempting to run an Impromptu report against an ISAM database via Transoft ODBC. Impromptu 4.01 may return data successfully whereas Impromptu 5.0 may return the error

Resolving The Problem

This may be caused by improvements to the SQL generated by Impromptu 5. An ODBC trace on the Impromptu 5 report may reveal something like the following:

SQLPrepare
0x01010007
[105]select T1.CONTACT_NO c1, T1.NAME_KEY c2, T1.LAST_NAME c3 from CONTACTS T1
105
SQL_ERROR
SQLError
NULL
NULL
0x01010007
[5]37000
0
[51][Transoft][TSODBC][usqlsd]'FROM' expected here (c1)
512
51
SQL_SUCCESS

The above SQL is SQL92 compliant and should work as this is valid SQL. The difference between the two versions is as follows:

Impromptu 4.0x generates:

SQLPrepare
0x01010003
[68]select T1."last_name", T1."first_name", T1."title" from "contact" T1
68
SQL_SUCCESS

Impromptu 5.0x, (see first SQL mentioned here) generates SQL with a column heading statement. The syntax for this is 'column_name column_heading' or, more explicit, 'column_name as column_heading'. This results in 'select T1.CONTACT_NO c1' in Impromptu 5 and in Impromptu 4 as 'select T1.CONTACT_NO'.

Some ODBC drivers may not be able to process this.In such cases the COGDMOD.ini file must be changed.

There are two options you can try, the first one forces Impromptu 5.0x to use the method from Impromptu 4.0x again. The second option will instruct Impromptu 5.0x to use the more explicit way of using column headers. This may work as well.

1. Add the following section to the \cogdmod.ini file. Use as the driver name the name of your ODBC .dll, this can be found in the heading of an ODBC trace. The section is:

[DRIVER:<name>.DLL]
SQL_COLUMN_ALIAS="N"

2. Or, less strict, this allows Impromptu to use column headers but then with the keyword 'as'. This requires again the same section to be added to the \cogdmod.ini file:

[DRIVER:<name>.DLL]
Keyword Alias=" as %s "

[{"Product":{"code":"SSTQPQ","label":"IBM Cognos Series 7 PowerPlay"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Impromptu","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Impromptu 5.0","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Historical Number

67124

Document Information

Modified date:
15 June 2018

UID

swg21353133