cancel
Showing results for 
Search instead for 
Did you mean: 

DB2 Login Failed.... system error 127 (IBM ODBC DB2 DRIVER).....

Former Member
0 Kudos

When trying to make a new connection to DB2 databases in Crystal Reports XI I get the message:

Login Failed:

Details: IM003: Specified driver could not be loaded due to system error 127 (IBM ODBC DB2 DRIVER). Database Vendor Code: 160

I get this when trying to connect to ANY DB2 database. Now, I here you say "check your DB2 settings....".

This is not the problem - I have numurous other reports that are already running from DB2 - when I open them into CR XI the connection works fine, and all the connections are fine in ODBC settings.

Any help is gratefully received.

thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Richard,

I am not an expert regarding the integration of DB2 with Crystal Reports XI, but as you mention, that you get the error message:

Login Failed:

Details: IM003: Specified driver could not be loaded due to system error 127 (IBM ODBC DB2 DRIVER). Database Vendor Code: 160

I looked for the meaning of the Database Vendor Code 160 and got this information:


 db2 "? SQL0160N"


SQL0160N The WITH CHECK OPTION clause is not valid for the
          specified view.

Explanation:

The WITH CHECK OPTION clause cannot be used in a view definition
if:

o   The view is defined as read only.  The view is read only if
    the SELECT statement contains any of the following.  (Note
    that these conditions do not apply to subqueries of the
    SELECT statement.)

    -   A DISTINCT keyword

    -   A column function in the selected list

    -   A GROUP BY or HAVING clause

    -   A FROM clause that identifies either:

        -   More than one table or view

        -   A read-only view

    -   A set operator (other than UNION ALL).

o   The SELECT statement in the CREATE VIEW statement includes a
    subquery (except for specific statistic columns of some
    catalog tables).

o   A view on which the specified view definition is dependent
    has an INSTEAD OF trigger defined.

o   A view on which the specified view definition is dependent
    contains a text search function.



 Federated system users: the WITH CHECK option is not supported
on views that reference updatable nicknames.

 The statement cannot be processed.  The specified view was not
created.

User Response:

Remove the WITH CHECK OPTION clause or change the view definition
so it conforms to the rules above.

 sqlcode :  -160

 sqlstate :  42813

Maybe your report tries to create such a view and therefore, you are not able to connect to DB2 using that report, but you can get a successful connection with others.

Hope this helps,

Regards,

Edgardo