ODBC Driver for Kingdee K3 WISE

Build 23.0.8839

JOIN クエリ

The 本製品 supports standard SQL joins like the following examples.

Inner Joins

Inner joins are the default join when the JOIN keyword is specified. The INNER and NATURAL keywords are also supported. The following query returns the Names of all Accounts that have Contacts and the FirstNames of those Contacts.

SELECT Account.Id, Account.Name, Contact.FirstName, Contact.LastName FROM Account JOIN Contact ON Account.Id = Contact.AccountId_Id

Left Join

Left joins can be executed with the LEFT JOIN and LEFT OUTER JOIN keywords. The following returns all Accounts and the Equipment Id for any preferred Equipment defined for that Account:

SELECT Account.Id, Account.Name, Equipment.Id AS Eid, Equipment.Name AS Ename FROM Account LEFT JOIN Equipment ON Account.PreferredEquipmentid_id = Equipment.Id WHERE Account.Name = 'Adventure Works (sample)'

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 23.0.8839