Testing the connection to the Db2 data source server

Test the connection to the Db2 data source server to determine if the federated server is properly configured to access the Db2 data source server.

Procedure

To test the connection to the Db2 server, open a pass-through session and issue an SQL SELECT statement on the Db2 system tables.
Db2 data source Example
Db2 for z/OS®
SET PASSTHRU server_definition_name
SELECT count(*) FROM sysibm.systables
SET PASSTHRU RESET
Db2
SET PASSTHRU server_definition_name
SELECT count(*) FROM syscat.systables
SET PASSTHRU RESET
Db2 for IBM® i
SET PASSTHRU server_definition_name
SELECT count(*) FROM qsys2.systables
SET PASSTHRU RESET
If the SQL SELECT statement returns a count, access to the data source is properly configured.