<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 02:57:17 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-1534] $min, $max field update operators</title>
                <link>https://jira.mongodb.org/browse/SERVER-1534</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;Add $min/max update modifiers which leave/replace the existing field based on the comparison of a provided value.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Note&lt;/b&gt;: if the field is missing then the value supplied will replace it like it was specified via a &lt;tt&gt;$set&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;Examples:&lt;/p&gt;
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.find()&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:1, v:1}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:2, v:2}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:3}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:4}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:1}, {$min: {v: 2}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// do not change the doc, existing value is smaller&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:1}, {$min: {v: 0}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// set v to 0&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.findOne({_id:1})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:1, v:0}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:2}, {$max: {v: 1}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// do not change the doc, existing value is larger&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:2}, {$max: {v: 2}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// do not change the doc, existing value is the same&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:2}, {$max: {v: 200}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// set v to 200&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.findOne({_id:2})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:2, v:200}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:3}, {$min: {v: 2}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// set v to 2&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:3, v:2}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;&amp;gt; db.v.update({_id:4}, {$max: {v: 2}} &lt;/span&gt;&lt;span style=&quot;color: #008200; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;// set v to 2&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{_id:4, v:2}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;

&lt;p&gt;&lt;b&gt;old description&lt;/b&gt;&lt;br/&gt;
I&apos;m working on a realtime website performance analysis tool, were a number of parallel processes import data into a mongodb instance.&lt;/p&gt;

&lt;p&gt;In this context, it would be extremely helpful to have $max and $min update operators which would work similar to $inc.&lt;/p&gt;

&lt;p&gt;{ $min : &lt;/p&gt;
{ field : value }
&lt;p&gt; }&lt;/p&gt;

&lt;p&gt;sets field to new value if field does not exist or value is smaller than current field value.&lt;/p&gt;

&lt;p&gt;{ $max : &lt;/p&gt;
{ field : value }
&lt;p&gt; }&lt;/p&gt;

&lt;p&gt;sets field to new value if field does not exist or value is larger than current field value.&lt;/p&gt;</description>
                <environment></environment>
        <key id="12617">SERVER-1534</key>
            <summary>$min, $max field update operators</summary>
                <type id="2" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14711&amp;avatarType=issuetype">New Feature</type>
                                            <priority id="4" iconUrl="https://jira.mongodb.org/images/icons/priorities/minor.svg">Minor - P4</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="scotthernandez">Scott Hernandez</assignee>
                                    <reporter username="skaes">Stefan Kaes</reporter>
                        <labels>
                    </labels>
                <created>Mon, 2 Aug 2010 05:08:45 +0000</created>
                <updated>Tue, 27 Oct 2015 14:13:14 +0000</updated>
                            <resolved>Sat, 28 Sep 2013 00:07:52 +0000</resolved>
                                                    <fixVersion>2.5.3</fixVersion>
                                    <component>Write Ops</component>
                                        <votes>38</votes>
                                    <watches>33</watches>
                                                                                                                <comments>
                            <comment id="433761" author="auto" created="Tue, 1 Oct 2013 12:52:28 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;scotthernandez&apos;, u&apos;name&apos;: u&apos;Scott Hernandez&apos;, u&apos;email&apos;: u&apos;scotthernandez@gmail.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-1534&quot; title=&quot;$min, $max field update operators&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-1534&quot;&gt;&lt;del&gt;SERVER-1534&lt;/del&gt;&lt;/a&gt; &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-10911&quot; title=&quot;Add $currentDate update modifier&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-10911&quot;&gt;&lt;del&gt;SERVER-10911&lt;/del&gt;&lt;/a&gt;: enable curentDate/min/max mods&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/278f1b43f51a62989ac91741b20fbf3adb6733b2&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/278f1b43f51a62989ac91741b20fbf3adb6733b2&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="432726" author="auto" created="Fri, 27 Sep 2013 23:56:15 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;scotthernandez&apos;, u&apos;name&apos;: u&apos;Scott Hernandez&apos;, u&apos;email&apos;: u&apos;scotthernandez@gmail.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-1534&quot; title=&quot;$min, $max field update operators&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-1534&quot;&gt;&lt;del&gt;SERVER-1534&lt;/del&gt;&lt;/a&gt; $min/$max update mods&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/f294acf6512a11ee06ed88555b02947f2fbe2c79&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/f294acf6512a11ee06ed88555b02947f2fbe2c79&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="432348" author="scotthernandez" created="Fri, 27 Sep 2013 13:10:20 +0000"  >&lt;p&gt;Doug, you will be able to do this with $push + $each + $sort + $slice in 2.6 (2.5.3 dev release will have it to test with) once we can sort on scalar values.&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.c.update({}, {$push: {maxHeartrate: {$each: [94,89], $sort: 1, $slice: -1 }}, minHeartrate: {$each: [94,89], $sort: -1, $slice: -1 }}})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;

&lt;p&gt;Kevin, this will work for your example too, but will require you to store the max/min value as an array which is still effectively a single value, and it will work the same as you need.&lt;/p&gt;</comment>
                            <comment id="345860" author="dpaul@proteuseng.com" created="Sun, 26 May 2013 19:13:15 +0000"  >&lt;p&gt;Just upvoted this. We&apos;d love to use it for dates, as well as for integers in an implementation of HyperLogLog.&lt;/p&gt;

&lt;p&gt;In the meantime, my team is using a workaround: we replace the single field with an array, which contains (in the case of min) possible minima. When writing to the field, we add new values to the array using &lt;tt&gt;$addToSet&lt;/tt&gt;. When reading, our software computes the minimum of all of the values in the array, and then removes all elements but the minimum using &lt;tt&gt;$pullAll&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;For example, suppose we want to track the minimum and maximum heartrate from a series of measurements.&lt;/p&gt;

&lt;ol&gt;
	&lt;li&gt;Our document starts out as:
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ minHeartrate: [], maxHeartrate: [] }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;&lt;/li&gt;
	&lt;li&gt;Then, we receive a measurement of 82, so we use add it to the arrays using &lt;tt&gt;$addToSet&lt;/tt&gt;:
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ minHeartrate: [82], maxHeartrate: [82] }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;&lt;/li&gt;
	&lt;li&gt;We then receive updates of 94, 89, which results in:
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ minHeartrate: [82, 94, 89], maxHeartrate: [82, 94, 89] }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;&lt;/li&gt;
	&lt;li&gt;Now suppose a user of our application requests a view based on this document. Upon reading the document, the application computes the min and max as appropriate from the values in the array, and triggers a write to remove all other values. The minimum heartrate will of course be calculated as 82, and the maximum heartrate will be 94. So we will issue an update with the following modifier:
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ $pullAll: {minHeartrate: [94, 89], maxHeartrate: [82, 89]} }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;
&lt;p&gt;The document will then be:&lt;/p&gt;
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ minHeartrate: [82], maxHeartrate: [94] }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;&lt;/li&gt;
	&lt;li&gt;If we were to read again at this point, no computation would be needed to find the minimum and maximum, because each array has exactly one value.&lt;/li&gt;
&lt;/ol&gt;


&lt;p&gt;This approach has a couple of drawbacks, of course. First, the array could grow too large if too many distinct values are observed between reads. This can be mitigated by a helper thread in your application that finds all documents having min/max arrays with more than a single value and forcing a computation. Second, it offloads some of the work onto the read operations, which isn&apos;t very mongo-like. Third, I&apos;m pretty sure it doesn&apos;t play well if the field(s) in question would be included in an index.&lt;/p&gt;</comment>
                            <comment id="322573" author="justanyone" created="Fri, 26 Apr 2013 20:04:03 +0000"  >&lt;p&gt;Specific usecase match here:  inserting vals into an array.  I have separate (indexed) field for max value in the array.  thus doc: &lt;/p&gt;
{ maxval: 30, vals: [0, 10, 20, 30] }

&lt;p&gt;Then, in two different processes, I $push a vals of 40 then 25.  How do I update maxval to 40 then not update it to 25?  &lt;/p&gt;

&lt;p&gt;This hits the concept of mongo db.update() referring to a value that&apos;s in the record already.  It&apos;s easy in SQL, not so much in Mongo.&lt;/p&gt;</comment>
                            <comment id="305277" author="justanyone" created="Wed, 3 Apr 2013 18:32:33 +0000"  >&lt;p&gt;Thanks, didn&apos;t know about that one!  This is the first I&apos;ve heard of it...&lt;/p&gt;


&lt;p&gt;On Fri, Mar 29, 2013 at 10:09 AM, Scott Hernandez (JIRA)&lt;/p&gt;
</comment>
                            <comment id="301588" author="scotthernandez" created="Fri, 29 Mar 2013 15:08:27 +0000"  >&lt;p&gt;Kevin, you can do things on the insert case using $setOnInsert (&lt;a href=&quot;http://docs.mongodb.org/manual/reference/operator/setOnInsert/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://docs.mongodb.org/manual/reference/operator/setOnInsert/&lt;/a&gt;).&lt;/p&gt;</comment>
                            <comment id="298867" author="justanyone" created="Tue, 26 Mar 2013 15:00:14 +0000"  >&lt;p&gt;with a doc:  &lt;/p&gt;
{ _id:xxx, keyField:7, startDate: 20130310, vals:[3,4]}

&lt;p&gt;During a findAndModify, I have to do an upsert and the resultant record is missing startDate.  That is, I&apos;m finding based on keyField, I&apos;m updating by $push&apos;ing onto vals, setting upsert=True.  Result rec doesn&apos;t have startDate!  I don&apos;t want to modify it if it&apos;s already there, so I&apos;d like to update {..., startDate: { $min: &lt;/p&gt;
{ $curval, 0}
&lt;p&gt;}}.  &lt;/p&gt;

&lt;p&gt;That, or be able to specify the exact value of the new doc during an upsert in findAndModify().&lt;/p&gt;</comment>
                            <comment id="288504" author="jrdn" created="Wed, 13 Mar 2013 20:34:18 +0000"  >&lt;p&gt;Getting this feature would make the world a better place.&lt;/p&gt;</comment>
                            <comment id="260170" author="whardier" created="Thu, 7 Feb 2013 17:29:02 +0000"  >&lt;p&gt;Upvoted.  I have to update specific ranges only and would appreciate using an index to do so.&lt;/p&gt;</comment>
                            <comment id="166950" author="shadowman131" created="Fri, 21 Sep 2012 22:48:34 +0000"  >&lt;p&gt;Added a vote, my use case is dates... for instance, I have several services participating in a general &quot;&apos;we&apos; are available until&quot;, and would like to just use the maximum availability when updating the records.&lt;/p&gt;</comment>
                            <comment id="151509" author="eliot" created="Wed, 8 Aug 2012 11:57:51 +0000"  >&lt;p&gt;Yes - note &quot;fix version&quot; above.&lt;br/&gt;
Just not sure when.&lt;/p&gt;</comment>
                            <comment id="151506" author="franktylerva" created="Wed, 8 Aug 2012 11:36:40 +0000"  >&lt;p&gt;Is this feature still be considered for a future release?&lt;/p&gt;</comment>
                            <comment id="52264" author="eliot" created="Fri, 2 Sep 2011 16:04:05 +0000"  >&lt;p&gt;@paul - no 2.0 is closed for features at this point&lt;/p&gt;</comment>
                            <comment id="52260" author="psadauskas" created="Fri, 2 Sep 2011 15:50:24 +0000"  >&lt;p&gt;Any chance we could get this looked at for 2.0?&lt;/p&gt;</comment>
                            <comment id="43904" author="dick@10gen.com" created="Thu, 21 Jul 2011 21:53:04 +0000"  >&lt;p&gt;Paul,  thanks for tackling this.  I&apos;m going to look it over to get it into the main branch.&lt;/p&gt;</comment>
                            <comment id="35577" author="kamaradclimber" created="Wed, 1 Jun 2011 15:58:40 +0000"  >&lt;p&gt;Great idea, it would be very good if it was merged into the main branch !&lt;/p&gt;</comment>
                            <comment id="28963" author="fields" created="Thu, 14 Apr 2011 16:08:14 +0000"  >&lt;p&gt;It would be really nice if this could work for date/time fields, too.&lt;/p&gt;</comment>
                            <comment id="28893" author="kalleg" created="Wed, 13 Apr 2011 08:08:25 +0000"  >&lt;p&gt;This would be a very useful feature. We have been discussing this with Kyle Banker during consulting sessions, and he agreed it would be useful in many use cases. Especially when using MongoDB for aggregation purposes.&lt;/p&gt;</comment>
                            <comment id="23502" author="blaine" created="Wed, 9 Feb 2011 22:26:13 +0000"  >&lt;p&gt;Great idea. I applied this patch and it is very useful for my project since it avoids unnecessary queries.&lt;br/&gt;
I discovered a bug with $min though: if an entry doesn&apos;t exist $min sets it to null and not to the supplied value.&lt;/p&gt;</comment>
                            <comment id="22833" author="psadauskas" created="Sun, 30 Jan 2011 20:09:55 +0000"  >&lt;p&gt;Ok, I got this working. Here&apos;s the changes that let it work on indexed fields: &lt;a href=&quot;https://github.com/paul/mongo/commit/8250f509af8cb8b1ec1c228d1c4a3409523c9df0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/paul/mongo/commit/8250f509af8cb8b1ec1c228d1c4a3409523c9df0&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The problem is, I think this will perform the update to the same value when the new value is less/greater than the existing one. If I don&apos;t do this, however, the value gets removed. Eg `{_id: 1, val: 2}` becomes `{_id: 1}`. I&apos;d rather just not modify the record at all, but there doesn&apos;t seem to be any way to do that.&lt;/p&gt;

&lt;p&gt;Anyways, what I have here works, and passes the tests.&lt;/p&gt;</comment>
                            <comment id="22820" author="eliot" created="Sun, 30 Jan 2011 06:15:23 +0000"  >&lt;p&gt;yes, you have to implement it for $set.  Not on irc.&lt;/p&gt;</comment>
                            <comment id="22819" author="psadauskas" created="Sun, 30 Jan 2011 06:13:08 +0000"  >&lt;p&gt;I&apos;m doing exactly the same thing as Mod::SET. Unless it has something to do with this `void Mod::appy` function, but I can&apos;t figure out what it does. Are you on IRC #mongodb now?&lt;/p&gt;</comment>
                            <comment id="22817" author="eliot" created="Sun, 30 Jan 2011 06:06:48 +0000"  >&lt;p&gt;Take a look at the other operators like $inc and $set.&lt;/p&gt;</comment>
                            <comment id="22816" author="psadauskas" created="Sun, 30 Jan 2011 06:03:18 +0000"  >&lt;p&gt;You are correct about it not working with indexes. I don&apos;t know anything about mongo internals, what do I need to do to make that work?&lt;/p&gt;

&lt;p&gt;Too bad about not adding the operators, I could really use them for a project I&apos;m working on, and was hoping to get them in for the next unstable branch (1.9?)&lt;/p&gt;</comment>
                            <comment id="22815" author="eliot" created="Sun, 30 Jan 2011 05:56:58 +0000"  >&lt;p&gt;We&apos;re probably not going to add any more operators until we clean some of that code up.&lt;br/&gt;
Also, I think you need to test when there is an index on the field you&apos;re changing.&lt;br/&gt;
I think its broken for that case (which also appears for other reasons).&lt;/p&gt;</comment>
                            <comment id="22814" author="psadauskas" created="Sun, 30 Jan 2011 05:52:28 +0000"  >&lt;p&gt;I&apos;ve taken a stab at implementing this feature. &lt;a href=&quot;https://github.com/mongodb/mongo/pull/21&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/pull/21&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Works for me, and includes tests. I&apos;m fairly new to C/C++, so I&apos;m open to suggestions for improvements.&lt;/p&gt;
</comment>
                            <comment id="19294" author="lehresman" created="Mon, 18 Oct 2010 15:58:29 +0000"  >&lt;p&gt;I would find this very helpful too.  Currently I&apos;m poorly simulating it by pushing values into an array and selecting the min value at query time.  It would be much more efficient to maintain this at update-time.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="43910">SERVER-6399</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="92067">DOCS-2012</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                                        </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>28.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10011" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Backwards Compatibility</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10038"><![CDATA[Fully Compatible]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Mon, 18 Oct 2010 15:58:29 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        10 years, 20 weeks, 1 day ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[<s><a href='https://jira.mongodb.org/browse/SERVER-6399'>SERVER-6399</a></s>]]></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>ian@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            10 years, 20 weeks, 1 day 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>fields</customfieldvalue>
            <customfieldvalue>auto</customfieldvalue>
            <customfieldvalue>dick@10gen.com</customfieldvalue>
            <customfieldvalue>dpaul@proteuseng.com</customfieldvalue>
            <customfieldvalue>eliot</customfieldvalue>
            <customfieldvalue>franktylerva</customfieldvalue>
            <customfieldvalue>kamaradclimber</customfieldvalue>
            <customfieldvalue>blaine</customfieldvalue>
            <customfieldvalue>jrdn</customfieldvalue>
            <customfieldvalue>kalleg</customfieldvalue>
            <customfieldvalue>justanyone</customfieldvalue>
            <customfieldvalue>lehresman</customfieldvalue>
            <customfieldvalue>psadauskas</customfieldvalue>
            <customfieldvalue>scotthernandez</customfieldvalue>
            <customfieldvalue>whardier</customfieldvalue>
            <customfieldvalue>skaes</customfieldvalue>
            <customfieldvalue>shadowman131</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hrpibr:</customfieldvalue>

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

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>20581</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|hrr9in:</customfieldvalue>

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