One of the coolest join options in Oracle is the Natural Join. Provided that the tables' columns were named such that the column name indicated which columns in two or more tables should be used for a join, it reduced the effort in writing SQL queries.
Instead of writing a:
SELECT ContactName, CityName
FROM Contact
JOIN City ON Contact.CityId = City.CityId
you could simply write:
SELECT ContactName, CityName
FROM Contact
NATURAL JOIN City
Considering how Microsoft has been trying to make development easier for software programmers, this is one feature that they ought to think about.
Natural Joins - Still not in MS SQL Server
最新推荐文章于 2025-12-31 22:48:07 发布
本文介绍了Oracle数据库中一种简便的表连接方式——自然连接。通过自然连接,开发者可以简化SQL查询语句,仅需指定参与连接的表名而无需显式定义连接条件。此特性能够提高开发效率并减少错误。

919

被折叠的 条评论
为什么被折叠?



