Hello , How to get S&P500 all stock by phthon API ? thank you.
Upgrade from Eikon -> Workspace. Learn about programming differences.
For a deeper look into our Eikon Data API, look into:
Overview | Quickstart | Documentation | Downloads | Tutorials | Articles
Hello , How to get S&P500 all stock by phthon API ? thank you.
@ethan.lin, thank you for your participation in the forum. Are any of the replies below satisfactory in resolving your query? If yes please click the 'Accept' text beneath the most appropriate reply. This will guide all community members who have a similar question. Otherwise please post again offering further insight into your question. Thanks, AHS
Hi,
Thank you for your participation in the forum.
Is the reply below satisfactory in answering your question?
If yes please click the 'Accept' text next to the most appropriate reply. This will guide all community members who have a similar question.
Otherwise please post again offering further insight into your question.
Thanks,
AHS
Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.
Thanks,
AHS
Hi @ethan.lin
You can retrieve index RIC constituents along with their names using the syntax
ek.get_data("0#.SPX","TR.COMMONNAME")
@ethan.lin, another way is to query the fundamental database for index constituents (current or historical):
ek.get_data('.SPX', 'TR.IndexConstituentRIC')