Database Reference
In-Depth Information
Figure 18.26
Adding Comments
to all of the
MUSIC Schema
Tables.
COMMENT ON COLUMN ARTIST.POBOX IS 'Post office box number';
COMMENT ON COLUMN ARTIST.CITY IS 'City';
COMMENT ON COLUMN ARTIST.STATE_PROVINCE IS 'State';
COMMENT ON COLUMN ARTIST.COUNTRY IS 'Country';
COMMENT ON COLUMN ARTIST.ZIP IS 'Zip code';
COMMENT ON COLUMN ARTIST.EMAIL IS 'Electronic mail address';
COMMENT ON COLUMN ARTIST.INSTRUMENTS
IS 'Artist instruments collection';
Column comments can be viewed through the
USER_COL_COMMENTS metadata dictionary view. The following query
shows the comments added to some ARTIST table columns. See the result in
Figure 18.27.
COLUMN TABLE_NAME FORMAT A16 HEADING "Table";
COLUMN COLUMN_NAME FORMAT A16 HEADING "Column";
COLUMN COMMENTS FORMAT A48 HEADING "Comments";
SELECT TABLE_NAME, COLUMN_NAME, COMMENTS
FROM USER_COL_COMMENTS WHERE TABLE_NAME='ARTIST';
Search WWH ::




Custom Search