Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Field Definitions

Re: Field Definitions

From: DA Morgan <damorgan_at_x.washington.edu>
Date: Mon, 21 Mar 2005 13:23:57 -0800
Message-ID: <1111440034.584602@yasure>


mike wrote:

> Is there a field where I can put what the field is used for?
>
> For example, if I have a field called site then the definition of that
> field would be: 'Location or site where the activity is conducted'.
>
> I'd then like to be able to do a query of the meta-data using something
> like:
>
> select column_name, data_type, data_length from all_tab_columns where
> table_name='mytable'
>
> and be able to get the field definition data as well.
>
> Any help is appreciated.
>
> Mike

Others have answered but I do want to point out that you can comment tables too:

COMMENT ON TABLE zip_code IS 'US Postal Service Zip Codes';

SELECT table_name, comments
FROM user_tab_comments;

COMMENT ON COLUMN zip_code.zip_code IS '5 Digit Zip Code';

SELECT table_name, column_name, comments FROM user_col_comments;

HTH

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace 'x' with 'u' to respond)
Received on Mon Mar 21 2005 - 15:23:57 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US