<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 02:55:41 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[SERVER-969] There is a limit on the number regexes in a query</title>
                <link>https://jira.mongodb.org/browse/SERVER-969</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;When querying with more than 4 regex  clauses, the serve emits an error message:&lt;br/&gt;
ERROR: too many regexes in query. &lt;br/&gt;
The resultant reply is a set of object of the same query but  ignoring the &quot;extra&quot; regex.&lt;/p&gt;

&lt;p&gt;It would be nice to have this limit removed.&lt;/p&gt;

</description>
                <environment>GNU/Linux (Debian)</environment>
        <key id="11705">SERVER-969</key>
            <summary>There is a limit on the number regexes in a query</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="9">Done</resolution>
                                        <assignee username="milkie@mongodb.com">Eric Milkie</assignee>
                                    <reporter username="skc">Shimon Cohen</reporter>
                        <labels>
                    </labels>
                <created>Mon, 5 Apr 2010 23:36:30 +0000</created>
                <updated>Tue, 12 Jul 2016 00:29:04 +0000</updated>
                            <resolved>Wed, 16 Nov 2011 21:48:34 +0000</resolved>
                                                    <fixVersion>2.1.0</fixVersion>
                                    <component>Querying</component>
                                        <votes>5</votes>
                                    <watches>7</watches>
                                                                                                                <comments>
                            <comment id="67209" author="auto" created="Wed, 16 Nov 2011 18:39:33 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;login&apos;: u&apos;milkie&apos;, u&apos;name&apos;: u&apos;Eric Milkie&apos;, u&apos;email&apos;: u&apos;milkie@10gen.com&apos;}
&lt;p&gt;Message: Allow more than four regular expressions in a query &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-969&quot; title=&quot;There is a limit on the number regexes in a query&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-969&quot;&gt;&lt;del&gt;SERVER-969&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
prior behavior was to log an error message and ignore any further regexps past 4&lt;br/&gt;
new behavior is to allow as many regexps as desired.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/62554d064a264f9b6c28099ba71421f250bbbba9&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/62554d064a264f9b6c28099ba71421f250bbbba9&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="33627" author="rgpublic" created="Fri, 20 May 2011 08:30:42 +0000"  >&lt;p&gt;Just accidentally read about this limitation here which might quite soon turn out to be highly problematic for us and severly limit what we are planning to achieve with MongoDB. Has anyone any experience what happens if you remove the above-mentioned limit from the source and recompile? Which file needs to be changed exactly? We would even accept if the query is running slower. Or is it better to replace all regexes beyond 4 to $function?&lt;/p&gt;</comment>
                            <comment id="33573" author="mponton" created="Thu, 19 May 2011 21:17:44 +0000"  >&lt;p&gt;Hi guys,&lt;/p&gt;

&lt;p&gt;This limitation is really bugging me. I do a GeoSpatial search to return a limited number of documents that I then want to filter using multiple regexes but I just found out (the long way) that I am limited to 4. I could do it client-side, but it complicates things and I have to deal with &quot;skip&quot; and &quot;limit&quot; logic. Its ugly. If this limit was put there for performance reasons, why not just remove it and let the end-user deal with any issue?&lt;/p&gt;

&lt;p&gt;On another note: I don&apos;t want to complain too much because you are doing an incredible job and we all appreciate the hard work put in MongoDB. Still, I am a bit frustrated by the way this limitation is handled. Seriously? A one-liner in the server log? I&apos;ve spent way to much time tracking down this issue because when it happens, the server just happily spit out results matching the first 4 regexes. Notifying the client of the error would be the least you should until the limitation is removed. If this alone is too much work, could you please update the documentation for &quot;Regular Expressions&quot; in &quot;Advanced Queries&quot; to clearly mention this limitation?&lt;/p&gt;

&lt;p&gt;Thanks!&lt;/p&gt;
</comment>
                            <comment id="25672" author="plasma" created="Thu, 10 Mar 2011 05:19:25 +0000"  >&lt;p&gt;Looking at the source its just a hard coded, arbitrary limit:&lt;/p&gt;

&lt;p&gt;...&lt;/p&gt;


&lt;p&gt;    void Matcher::addRegex(const char *fieldName, const char *regex, const char *flags, bool isNot) {&lt;/p&gt;

&lt;p&gt;        if ( nRegex &amp;gt;= 4 ) &lt;/p&gt;
{
            out() &amp;lt;&amp;lt; &quot;ERROR: too many regexes in query&quot; &amp;lt;&amp;lt; endl;
        }
&lt;p&gt;....&lt;/p&gt;

&lt;p&gt;I assume the reason for it is because any more regexes and performance may begin to suffer?&lt;/p&gt;</comment>
                            <comment id="25664" author="eliot" created="Thu, 10 Mar 2011 00:48:32 +0000"  >&lt;p&gt;Note the &quot;Fix Version&quot; above.&lt;br/&gt;
That means its stuff we hope to get done this year, but the # of votes is not that high compared to other enhancements.&lt;/p&gt;</comment>
                            <comment id="25662" author="prashs1983" created="Thu, 10 Mar 2011 00:21:45 +0000"  >&lt;p&gt;Hi,&lt;/p&gt;

&lt;p&gt;I am using 1.6.5. I was wondering if this issue is likely to be fixed soon?&lt;/p&gt;

&lt;p&gt;Prashant&lt;/p&gt;</comment>
                            <comment id="24945" author="vpavlov" created="Tue, 1 Mar 2011 11:40:15 +0000"  >&lt;p&gt;Very important bug. Because we cant use this database in big portals, which needs to filter data by many expressions.&lt;br/&gt;
Please resolve it.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>7.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Tue, 1 Mar 2011 11:40:15 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        12 years, 14 weeks ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10057" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comment by Customer</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10056" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last commenter</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>ramon.fernandez@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            12 years, 14 weeks ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10000" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Old_Backport</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10000"><![CDATA[No]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>plasma</customfieldvalue>
            <customfieldvalue>auto</customfieldvalue>
            <customfieldvalue>eliot</customfieldvalue>
            <customfieldvalue>milkie@mongodb.com</customfieldvalue>
            <customfieldvalue>mponton</customfieldvalue>
            <customfieldvalue>prashs1983</customfieldvalue>
            <customfieldvalue>rgpublic</customfieldvalue>
            <customfieldvalue>skc</customfieldvalue>
            <customfieldvalue>vpavlov</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hrpo87:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hrgd0f:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9017</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10053" key="com.atlassian.jira.ext.charting:timeinstatus">
                        <customfieldname>Time In Status</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_22870" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Triagers</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|ht0ayf:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                    </customfields>
    </item>
</channel>
</rss>