views:

39

answers:

1

Salesforce has some built in meta-data fields to describe each Field of each Object.

e.g. you can record a Description and Help Text value for each field.

Is there any way to record more information? e.g. If I want to record notes about each field that are relevant to developers but not to users? Or if I want to flag a field as 'no longer used'?

I'm wondering if there's an app in AppExchange for this?

Or do I have to build my own meta-data database somewhere outside of Salesforce?

edit: One of the reasons I want to do this is for documentation of the data structure - the best place to put developer notes about a field is right there in the meta-data, if there's a suitable place for it to go ...

+2  A: 

Apologies in advance if you already know what I'm about to post, it just wasn't clear from your question whether you knew how existing metadata is exposed.

I'm not sure how you'd extend the schema, but it looks like one of the items you are asking for will be supported...

Once you've instantiated a DescribeFieldResult object, you can call several methods to get a lot of information about the object. For example, I noticed in the help files that there's a method called isDeprecatedAndHidden that looks like it will be used to flag a no longer used field.

So for example, you could do the following to check this.

Schema.DescribeFieldResult FieldResult = Account.AccountNumber.getDescribe();
Boolean isDeprecated = FieldResult.isDeprecatedAndHidden();

There are several other methods that give good information about the fields. These methods are exposed through the DescribeFieldResult object. Take a look at this for more detail: http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_methods_system_fields_describe.htm

Paddyslacker

related questions