Considerations for using distributed relational database

This section contains information that may be useful in developing applications that use application servers which are not the same product as their application requesters.

All DB2® products support extensions to IBM® SQL. Some of these extensions are product-specific, but many are already shared by more than one product or support is planned but not yet generally available.

For the most part, an application can use the statements and clauses that are supported by the database manager of the current server, even though that application might be running through the application requester of a database manager that does not support some of those statements and clauses. Restrictions to this general rule are identified by application requester:

  • for DB2 for z/OS® Application Server application requester, see Table 1
  • for Db2® for i Application Server application requester, see Table 2
  • for DB2 LUW application requester, see Table 3.

Note that an 'R' in the table indicates that this SQL function is not supported in the specified environment. An 'R' in every column of the same row means that the function is available only if the current server and requester are the same product or that the statement is blocked by the application requester from being processed at the application server.

Table 1. DB2 for z/OS Application Requester
SQL Statement or Function DB2 for z/OS Application Server Db2 for i Application Server DB2 LUW Application Server
COMMIT HOLD R R R
DECLARE STATEMENT      
DECLARE TABLE      
DECLARE VARIABLE      
DESCRIBE TABLE     R
DESCRIBE with USING clause     R
DISCONNECT R R R
ROWID data types     R
DATALINK data types R R R
BINARY and VARBINARY data types     R
Host declarations not documented in language specific appendices   1 1
PREPARE with USING clause     R
ROLLBACK HOLD R R R
SET CURRENT PACKAGESET      
SET variable   R R
SET TRANSACTION R R R
Scrollable Cursor statements R R R
UPDATE cursor - FOR UPDATE clause not specified      
Table 2. Db2 for i Application Requester
SQL Statement or Function DB2 for z/OS Application Server Db2 for i Application Server DB2 LUW Application Server
COMMIT HOLD R   R
DECLARE STATEMENT      
DECLARE TABLE      
DECLARE VARIABLE      
DESCRIBE TABLE     R
DESCRIBE with USING clause     R
DISCONNECT      
Host Variables - optional colon R R R
ROWID data types     R
DATALINK data types R   R
BINARY and VARBINARY data types     R
Host declarations not documented in language specific appendices 1   1
PREPARE with USING clause     R
ROLLBACK HOLD R   R
SET CURRENT PACKAGESET R R R
SET variable R R R
SET TRANSACTION R   R
Scrollable Cursor statements R   R
UPDATE cursor - FOR UPDATE clause not specified R    
Table 3. DB2 LUW application requester
SQL Statement or Function DB2 for z/OS Application Server Db2 for i Application Server DB2 LUW Application Server
COMMIT HOLD R R R
DECLARE STATEMENT R R R
DECLARE TABLE R R R
DECLARE VARIABLE R R R
DESCRIBE TABLE R R R
DESCRIBE with USING clause R R R
DISCONNECT      
Host Variables - optional colon R R R
ROWID data types 2 2 R
DATALINK data types R R R
BINARY and VARBINARY data types R R R
Host declarations not documented in language specific appendices 1 1  
PREPARE with USING clause R R R
ROLLBACK HOLD R R R
SET CURRENT PACKAGESET      
SET variable R R R
SET TRANSACTION R R R
Scrollable Cursor statements R R R
UPDATE cursor - FOR UPDATE clause not specified R    
1 The statement is supported if the application requester understands it.
2 The DB2 LUW application requester application requester will process a ROWID data type at the application server using the compatible VARCHAR(40) FOR BIT DATA data type.