Comments are always recommended for good programming practices. So If you want to put some comments on a database tables of columns of a database table then go through this simple tutorial:
Syntax For Comments on Table:
COMMENT ON TABLE
IS 'the comments should be written here';
Syntax For Comments on Columns:
COMMENT ON TABLE | COLUMN table.column
IS 'the comments should be written here';
The comments provided using the above syntax will be saved in the database and can be retrieved using the following queries:
For tables:
select * from all_tab_comments
where table_name ='table_name'
IS 'the comments should be written here';
Syntax For Comments on Columns:
COMMENT ON TABLE | COLUMN table.column
IS 'the comments should be written here';
The comments provided using the above syntax will be saved in the database and can be retrieved using the following queries:
For tables:
select * from all_tab_comments
where table_name ='table_name'
Or
select * from user_tab_comments
where table_name = 'table_name'
For Columns:
select * from all_col_comments
where table_name = 'table_name'
Or
where table_name = 'table_name'
For Columns:
select * from all_col_comments
where table_name = 'table_name'
Or
select * from user_col_comments
where table_name = 'table_name'
where table_name = 'table_name'
COMMENTS