PMS Information Systems
Welcome to PMS Information Systems - IBM i (AS/400) Forum !!!

Get Answers for all your queries on IBM i (AS/400).

Now V7R1- SQL statements can now reference objects from more than one IBM i system.

View previous topic View next topic Go down

Now V7R1- SQL statements can now reference objects from more than one IBM i system.

Post  maran on Thu Jan 03, 2013 1:03 am


The GA version of the DB2 for i 7.1 release simplified access to DB2 objects on remote systems by eliminating the need for explicit remote connections with the new three-part name support. Instead of developers having to use an extra CONNECT or SET CONNECTION statement to explicitly connect statement, they can now simply run an SQL statement like the following to retrieve data from a table on a different system or partition.

SELECT lastname, address, city FROM rmtsystem.datalib.customer

WHERE state='IA'

The SELECT statement in this example accesses a remote table with a three-part name value of rmtsystem.rmtschema.customers. The first part of the name is the remote database server name: rmtsystem. This value must correspond to an entry in the IBM i relational database directory entry that was added with the Add Relational Database Directory Entry (ADDRDBDIRE) command. The second component is the schema name, datalib, on the remote server. The final part of the three-part name is the name of the DB2 object, customer, on the remote server. Whenever an SQL statement references an object with a three-part name that resides on a different system, DB2 starts an implicit Distributed Relational Database Architecture (DRDA) connection to enable the DB2 object on the remote server to be accessed.

maran
Admin

Posts : 442
Join date : 2009-07-24

View user profile http://pmsinformationsystem.forumotion.net

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum