From Fund Company to Lei

I am trying to retrieve LEI codes of issuing company from ISIN codes of open end funds.

The code works decently but there is a problem that should be addressed. There are companies for which there exists LEI code in Refinitiv but the code cannot retrieve it. In particular one should focus on the part:


fund_company = 'AXA Investment Managers Paris SA'
# get the PermID from name:
perm_id = rd.discovery.search(
view=rd.discovery.Views.SEARCH_ALL,
filter=f"CommonName eq '{fund_company}'",
select="PI"
)
# get the LEI code from PermID:
print(rd.get_data(perm_id['PI'][0], ['TR.LegalEntityIdentifier', 'TR.CommonName']))


creates this error:

Traceback (most recent call last):

File "/Users/francescofabirs/Library/Python/3.9/lib/python/site-packages/pandas/core/indexes/base.py", line 3802, in get_loc

return self._engine.get_loc(casted_key)

File "pandas/_libs/index.pyx", line 138, in pandas._libs.index.IndexEngine.get_loc

File "pandas/_libs/index.pyx", line 165, in pandas._libs.index.IndexEngine.get_loc

File "pandas/_libs/hashtable_class_helper.pxi", line 5745, in pandas._libs.hashtable.PyObjectHashTable.get_item

File "pandas/_libs/hashtable_class_helper.pxi", line 5753, in pandas._libs.hashtable.PyObjectHashTable.get_item

KeyError: 'PI'



However, if you input AXA Investment Managers Paris SA DIB manually into Workspace, you can find LEI code.


Best Answer

  • raksina.samasiri
    Answer ✓

    Hi @francesco.fabris01 ,

    I'd like to confirm that it can be found with 'AXA Investment Managers Paris'

    1696244787535.png

    The moderators
    on this forum are expertise on Refinitiv APIs usage. However, they do not have
    deep expertise in every type of content available through Refinitiv products.
    Such expertise is available through Refinitiv Helpdesk, which can be reached
    via MyRefinitiv and the support team is going to contact you soon to assist with this.



    Hope this helps
    and please let me know in case you have any further questions

Answers

  • Hi @francesco.fabris01
    ''AXA Investment Managers Paris SA' cannot be found, please try with "'AXA Investment Managers Paris'

  • But I cannot try manually for all companies. I need it to be standardised. Also, how come I use the output from Refinitiv as an input to find the LEI code but this input is not valid?