Using entity\getLinkColumn returning none

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jonesm
    Junior Member
    • Sep 2021
    • 3

    Using entity\getLinkColumn returning none

    Hi,

    I have been trying to get a value from a linked multiple entity using entity\getLinkColumn(LINK, ID, COLUMN) but all i receive is "None".

    I have confirmed that the relationship exists using entity\hasLinkMultipleId and entity\isRelated both of which return true.

    What value should i be providing for COLUMN in the function above. I have been using Field names and no values have been returning.


    example code running in formula
    PHP Code:
      $currentNpsId=array\at(npsIds, 0);
      currentNps = entity\getLinkColumn('nps', $currentNpsId, 'name'); 
    


    Last edited by jonesm; 09-29-2021, 12:07 PM.
  • jonesm
    Junior Member
    • Sep 2021
    • 3

    #2
    Have i posted this in the right place for Formula help?

    Thanks

    Comment

    • yuri
      Member
      • Mar 2014
      • 8469

      #3
      This function is intended for getting columns of relation tables, not fields of related entities. Use record\attribute instead.
      If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

      Comment


      • jonesm
        jonesm commented
        Editing a comment
        Thank you so much I must have got confused seeing that I knew it was a link. Thank you for the clarification.
    Working...