Unable to resolve identifier when requesting data through refinitiv data api

import refinitiv.data as rd

index_ric = '0#.KS200'

summary = rd.get_history(

universe = index_ric,

fields = [

"TR.CompanyMarketCap",

# "TR.GICSSector",

],

start = "2024-06-01",

end = "2024-06-30"


)

summary
When running the above

I get the following error


RDError: Error code -1 | Unable to resolve all requested identifiers in ['0#.KS200'].




Note i've also tried .KS200

This seems to work for other indices

Answers

  • Hi @prit.savani ,

    With the Data Library for Python, chain function can be used to retrieve constituents under each chain. Example code of this function can be found at EX-1.01.07-Chains.ipynb

    import refinitiv.data as rd
    from refinitiv.data.discovery import Chain

    rd.open_session()

    index_ric = Chain(name="0#.KS200")

    #print(index_ric.constituents)

    summary = rd.get_data(
    universe = index_ric,
    fields = [
    "TR.CompanyMarketCap.date",
    "TR.CompanyMarketCap"
    ],
    parameters={
    'SDate': '2024-06-01',
    'EDate': '2024-06-30'
    }
    )
    summary

    1730706081679.png

    or the data can be retrieved with get_history function as below

    summary = rd.get_history(
    universe = index_ric,
    fields = [
    "TR.CompanyMarketCap.date",
    "TR.CompanyMarketCap"
    ],
    start = "2024-06-01",
    end = "2024-06-30"
    )
    summary

    1730706112775.png