Whilst creating segment made up of multiple rows and relationships you might be confused when you try to to save and you get the error message “SegmentQuery: You have exceeded the maximum number of 2000 characters for this field”.
The reason for this is the query field. Like any text field in Dynamics there is a maximum character count and by default the query is capped at 2000. When you add your conditions and relationship there is query field being populated with text. The maximum number of characters can be increased with these simple steps.
First of all you need to go to Settings > Customisations
Next you open up customise the system
Find the Segment entity and open up the Query Definition field.
In the field you can increase the maximum character account to a more suitable number. I decided on 20,000.
Now you should be able to save your segment with no issues.
If you would like to read more about creating segments then why not check out our other blog post: https://www.crmcs.co.uk/content/dynamics-355-for-marketing-segments.aspx