web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Migration product cata...
Power Apps
Unanswered

Migration product catalog fails with "TooManyConditionsInQuery"

(0) ShareShare
ReportReport
Posted on by 601

Hi, 

I am trying to migrate data for a Dynamics 365 Sales product catalog from one environment to another.

I made a migration schema file with CRM Configuration Manager (v4.0.0.110 64bit) and tried to export the data from the source environment.

Whatever I try, even if I only select 2 fields (productid and nam) from the Products table (in which there are about 3500 products in the source environment), I get the error:

 

ApiOriginalExceptionKey : Microsoft.Crm.CrmException: Number of conditions in query exceeded maximum limit. ---> Microsoft.Crm.CrmException: Number of conditions in query exceeded maximum limit.
at Microsoft.Crm.Query.EntityExpression.FromSdkQueryVisitor.Visit(ConditionExpression condition)
...
ApiExceptionMessageName : TooManyConditionsInQuery

Is there any setting that I need to set to overcome this? If I use the same export schema on a smaller product catalog (from another source environment), with only around ten products, the export works fine...

I have the same question (0)
  • cchannon Profile Picture
    4,702 Moderator on at

    the "number of conditions" refers not to the columns you select, but the conditions you put on the query ("XXX equals YYY"). Is your query especially complex in that regard?

  • KoJaPD Profile Picture
    601 on at

    Hi @cchannon , the export schema (which is created by the CRM migration tool) does not include *any* filter, it only defines the fields (columns) that have to be exported/imported

  • cchannon Profile Picture
    4,702 Moderator on at

    Interesting. Can you provide the query?

  • KoJaPD Profile Picture
    601 on at

    @cchannon , here the *complete* XML file that is created...

    <entities>
    <entity name="product" displayname="Product" etc="1024" primaryidfield="productid" primarynamefield="name" disableplugins="false">
    <fields>
    <field updateCompare="true" displayname="Product" name="productid" type="guid" primaryKey="true"/>
    <field displayname="Name" name="name" type="string"/>
    </fields>
    </entity>
    </entities>

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 542 Most Valuable Professional

#2
Haque Profile Picture

Haque 206

#3
Kalathiya Profile Picture

Kalathiya 201 Super User 2026 Season 1

Last 30 days Overall leaderboard