登录 注册
当前位置:主页 > 资源下载 > SQL语言基础中涉及的未明确限定的列名

SQL语言基础中涉及的未明确限定的列名

  • 更新:2024-07-07 11:33:20
  • 大小:5.26MB
  • 推荐:★★★★★
  • 来源:网友上传分享
  • 类别:Informix - 数据库
  • 格式:PPT

资源介绍

限定不明确的列名 * 用表名作为前缀来限定在多个表中都出现的列名字. 利用表的前缀可以提高性能. 使用不同的别名来标志在不同表中的相同的名字。 * Qualifying Ambiguous Column Names You need to qualify the names of the columns in the WHERE clause with the table name to avoid ambiguity. Without the table prefixes, the DEPTNO column could be from either the DEPT table or the EMP table. It is necessary to add the table prefix to execute your query. If there are no common column names between the two tables, there is no need to qualify the columns. However, you will gain improved performance by using the table prefix because you tell the Oracle Server exactly where to go to find columns. The requirement to qualify ambiguous column names is also applicable to columns that may be ambiguous in other clauses, such as the SELECT clause or the ORDER BY clause. Instructor Note Demo: l4loc.sql Purpose: To illustrate a SELECT clause with no aliases.