Formula that can pull up INPJ.J for GB00B17BBQ50 using Python API

How to pull RIC using ISIN and select specific market without using RSearch formula
It seems RSearch formula below in Eikon will not work in Python API

=RSearch("EQUITY","Search:'"&A2&"' ExchangeCode:"&B2&"",,)


where A2 is GB00B17BBQ50 B2 is JNB

Sort by:
1 - 1 of 11
    User: "Alex Putkov.1"
    ✭✭✭✭✭
    Accepted Answer

    @kenley.macandog123

    You can use RDP Library to achieve what you're looking for. The example below returns the RIC 'INPJ.J', given the ISIN 'GB00B17BBQ50' and exchange code 'JNB' as inputs.

    rdp.lookup(view=rdp.SearchViews.EquityQuotes, scope='IssueISIN', 
               terms='GB00B17BBQ50', filter="ExchangeCode eq 'JNB'",
    select='RIC')

    For a comprehensive review of using RDP Library to access the Search service on RDP, see the article titled "Building Search into your Application Workflow".