API query on get data

Hello Client got the below when he was trying to update the data for Carbon Futures (RICS: CFI2c1, CFI2c2, CFI2c3, … CFI2c19), I received an empty data frame.

 

image.png

df_getdata = ld.get_data(

                                 universe=[‘CFI2c1’, ‘CFI2c2’, ‘CFI2c3’],

                                 fields=[]

)

This is abnormal behavior that I’m encountering for the first time.

I’ve checked with the Excel Addin and there’s no issue there.

For additional reference,

 

get_history returns data just fine. But get_data returns an empty dataframe.

 

Answers

  • Gurpreet
    Gurpreet admin
    edited May 21

    Fields is a required parameter in the get_data call. Please have the user check out the LD library samples and start from there.

    image.png

    The list of available fields can be found through the Data Item Browser in Workspace.

  • Hello @Gurpreet thanks for the help, I have provided the same to the client.

  • Client responded-

    Again, it’s not an issue of the code not functioning. When I run the same code at different times of the day, it doesn’t always return data. Sometimes it’s an empty dataframe, sometimes there’s data.

    I would appreciate your assistance regarding a matter raised by the client. Could you please take a moment to review the details below and share your insights? Your expertise would be invaluable in addressing their concerns

    @Gurpreet

  • The previous answer is complete. They cannot leave the fields part blank! Please ask the client to directly post their questions on the forum.