Method: 1. Use the statement "comment on column table name. Field name is 'comment information'" to add comments to the fields in the table; 2. Use the statement "comment on table is 'comment information'" to add comments to the table. Add comments itself.
The operating environment of this tutorial: Windows 10 system, Oracle 11g version, Dell G3 computer.
1. Since there are no comments added to the tables and table fields at work, you will not be able to understand the meaning of each table or field when viewing, so try to Add comments to tables or fields. First create a table.
2. Add comments to the fields in the table
Syntax:
comment on column 表名.字段名 is '注释信息';
If the comments in the table are incorrectly added, you can also directly use this syntax to re-comment the fields. Re-annotation will overwrite the original annotation content.
3. Add comments to the table itself
Syntax:
comment on table is '注释信息';
You can also use this syntax again to re-comment the table.
#4. After the changes are completed, use the tool to connect to the database. It is found that comments have been added. After adding comments, the table will look more intuitive.
Recommended tutorial: "Oracle Video Tutorial"
The above is the detailed content of How to add field comments in oracle. For more information, please follow other related articles on the PHP Chinese website!