- Learning PostgreSQL 10(Second Edition)
- Salahaldin Juba Andrey Volkov
- 110字
- 2021-07-02 22:42:04
The rename operation
The rename operation is used to alter the attribute name of the resultant relation or to give a specific name to the resultant relation. The rename operation is used to perform the following:
- Remove confusion if two or more relations have attributes with the same name
- Provide user-friendly names for attributes, especially when interfacing with reporting engines
- Provide a convenient way to change the relation definition and still be backward compatible
The AS keyword in SQL is the equivalent of the rename operator in relational algebra. The following SQL example creates a relation with one tuple and one attribute, which is renamed PI:
SELECT 3.14::real AS PI;
推薦閱讀
- 基于LabWindows/CVI的虛擬儀器設(shè)計與應(yīng)用
- Visual C# 2008開發(fā)技術(shù)詳解
- INSTANT Varnish Cache How-to
- Hands-On Linux for Architects
- 可編程控制器技術(shù)應(yīng)用(西門子S7系列)
- 3D Printing for Architects with MakerBot
- 大數(shù)據(jù)技術(shù)與應(yīng)用
- Linux服務(wù)與安全管理
- Lightning Fast Animation in Element 3D
- 單片機技術(shù)一學(xué)就會
- SMS 2003部署與操作深入指南
- 學(xué)練一本通:51單片機應(yīng)用技術(shù)
- 電動汽車驅(qū)動與控制技術(shù)
- 計算機硬件技術(shù)基礎(chǔ)(第2版)
- 新一代人工智能與語音識別