locked
Difference between LeadId and Id RRS feed

  • Question

  • Hi guys,

    I'm really new to CRM 2011, so I have what I hope is a very simple question.

    What is the difference between the LeadId and Id field for a Lead? (Same question for the other entities)/

    Thanks a bunch,

    Helen


    Helen

    Saturday, February 11, 2012 4:51 PM

Answers

  • Hi Helen,
                    They are the same, since all entities in CRM inherits from the same base class called Entity this inherited class has generic attribute Id for all the entities. And all the other entities also implement their own field to host the id for example, the account will have AccountId, contact will have ContactId, etc. but all the entities will still have the inherited field Id.





    Regards,
    Damian Sinay

    • Marked as answer by Helen W Sunday, February 12, 2012 1:42 AM
    Sunday, February 12, 2012 12:29 AM

All replies

  • Hi Helen,
                    They are the same, since all entities in CRM inherits from the same base class called Entity this inherited class has generic attribute Id for all the entities. And all the other entities also implement their own field to host the id for example, the account will have AccountId, contact will have ContactId, etc. but all the entities will still have the inherited field Id.





    Regards,
    Damian Sinay

    • Marked as answer by Helen W Sunday, February 12, 2012 1:42 AM
    Sunday, February 12, 2012 12:29 AM
  • Yes, I looked at Contact and Lead Entities in the debugger, and the contactID & leadID were always the same as the respective Id field. Is this just to make late binding easier? It seems very strange.

    Anyway, thanks for clearing it up for me.

    Cheers!


    Helen

    Sunday, February 12, 2012 1:44 AM