7

What's wrong with my Lead object that it has no LastModifiedDate?

lead

I can't add it to any view or anything like that. What's going on?

3

Its a system generated date that is not listed in the standard field list. You will also notice that Created Date is not listed there. These field still exist. You can confirm by doing a simple query like below in Apex Anonymous

Lead l = [Select Id, Name, CreatedDate, CreatedDate, LastModifiedDate From Lead limit 1];
system.debug('Created On : ' + l.CreatedDate);
system.debug('Last Modified On : ' + l.LastModifiedDate);
  • You could also use describes. Still +1 but for the vote cap. – Adrian Larson Aug 30 '16 at 23:42
  • Do I then have to make a surrogate field to display the date in the lead detail view with a formula or something? – okay56k Aug 30 '16 at 23:59
  • 2
    No, its not exactly intuitive, but in the UI, on the page layout, the Created By field shows you not only who created it, but also when. Same goes for the Last Modified By field. It shows both who and when. – Chris Duncombe Aug 31 '16 at 0:01
  • 1
    Ah, thank-you. Not intuitive is right. – okay56k Aug 31 '16 at 0:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.