question

Upvotes
Accepted
3 1 2 3

python index constituents

Hello,

I would like to get the constituents of the index JPMGCOC. I've tried to add "L" and "|L" but it doesn't work. Could you help me please?

python#contentdatastream-apiindexconstituents
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvote
Accepted
85.9k 292 53 78

@marco.bolognesi

Thanks for reaching out to us.

I tried LJPMGCOC with the following code.

df = ds.get_data("LJPMGCOC",['NAME'], kind=0)
df

The output is:

1670928427168.png

I hope that this information is of help.


1670928427168.png (62.3 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
3 1 2 3

Thank you very much for this feedback. I confirm I'm not able to get the list you showed. Is it possible because I do not have access to index constituents of this index? the formula return basically an empty df without any error message.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
85.9k 292 53 78

@marco.bolognesi

It could be a permission issue. You can test the request with the Datastream Test REST Service.

First, use the Get Token service method, to get a token.

Then, use the retrieved token with the Get Data service method to request the data.

1670936118486.png

You can check the retrieved response.

1670936151207.png


1670936118486.png (56.0 KiB)
1670936151207.png (26.4 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
3 1 2 3

thanks for the support. I received an empty token then I'm quite sure it is a permission issue

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@marco.bolognesi

Please contact the Datastream support team directly via MyRefintiv to verify your permission.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.