A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
I have a custom app that uses a bulk operation GraphQL query to fetch data and it's worked fine until last week. Last week, I noticed it was returning incomplete data. I query for orders and products and it only returns either orders or products but not both.
When I reduce the size of the requested data by reducing the date window for the orders, complete data is returned. Do bulk operations have a limit on requested data size?
mutation { bulkOperationRunQuery( query: """ { products(query:"NOT product_type:Sets") { edges { node { id title status featuredImage { url } variants { edges { node { id sku title availableForSale sellableOnlineQuantity inventoryItem { unitCost { amount } } } } } } } } orders(query: "created_at:>=2022-10-07T00:00:00Z") { edges { node { createdAt id lineItems { edges { node { id unfulfilledQuantity variant { id } quantity } } } } } } } """ ) { bulkOperation { id status } userErrors { field message } } }
Hi un-tethered,
Thanks for your post. Bulk queries do have some internal resource limitations which we're working to improve the documentation about. At this time simplifying the query is the best option.
It does seem particularly unusual that only part of the results would be returned. If that is a result that can be replicated it would be great if you could report this specific example with a few more details to [Partner Support using the email option] and selecting the 'App Development & API' topic.
Some additional info that would be helpful for an investigation is a date, time, and timezone from within the past 7 days that this happened and the store it occurred in.
Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog