question

Upvotes
Accepted
3 0 0 1

How to get all the search result from refinitiv.data.discovery.search?

I ran below search. But got Error message: refinitiv.data._errors.RDError: Error code 400 | Validation error: json.Top in body should be less than or equal to 10000

rd.discovery.search(
view = rd.discovery.Views.FUND_QUOTES,
top = 56364,
filter = "(AssetState ne 'DC' and SearchAllCategoryv2 eq 'Funds' and (RCSAssetCategoryGenealogy in ('A:KZ') and (RCSIssueCountryRegisteredForSale xeq 'G:6V' or RCSIssueCountryRegisteredForSale xeq 'G:90' or RCSIssueCountryRegisteredForSale xeq 'G:19' or RCSIssueCountryRegisteredForSale xeq 'G:3N')))",
select = "DTSubjectName,RIC,BusinessEntity,PI,SearchAllCategoryv3,SearchAllCategoryv2,SearchAllCategory,IssueISIN,IssueLipperGlobalSchemeName,RCSAssetCategoryLeaf,RCSIssuerDomicileCountryLeaf,RCSIssueCountryRegisteredForSale,RCSCurrencyLeaf,ExchangeName,iNAVRIC,RCSAssetCategoryGenealogy"
)

Is there a way to dice and slice the result and get all the rows in batches?

python apirefinitiv-data-librariesrdp search
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.

Hello @yang.yang01

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?


If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,


AHS

1 Answer

· Write an Answer
Upvotes
Accepted
10.2k 18 6 9

@yang.yang01 Thanks for your question - we have written an article on working with our search functions - and in particular on working within the limit of 10,000 results per search API call. We also have an accompanying jupyter notebook you can use which is filled with example code. Please let us know if this of use. I hope this can help.

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.

Thank you! It's helpful

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.