<div dir="ltr"><div>Hi,</div><div>Depending on the version you are running (i don't know if all the functions are in 3.4, otherwise you have the "array plus" - I think- plugin), <i><b>array_find( array_reverse( array_agg( "$area",order_by:= "$area") ), "$area") +1</b> </i>might do the trick<br></div><div><div>array_agg will create a "list" of the features surface in your dataset, ordered from the smallest to the largest</div><div>array_reverse is obvious I think</div><div>and array_find will return the order in which the current feature's area appears in the list. The index is 0 based.<br></div><div> </div><div>Hope that helps,</div><div>Harrissou<br></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le jeu. 25 juil. 2019 à 17:09, GILLEN Finbar <<a href="mailto:finbar.gillen@axa.ie">finbar.gillen@axa.ie</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div lang="EN-US">
<div class="gmail-m_7011799110433320473WordSection1">
<p class="MsoNormal">Hi,<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I'd like to create a new field in the attribute table which gives the rank of a polygon based upon a figure in another field.
<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">For example, the polygon of the largest figure would be rank 1 and the smallest rank N.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Is there any way to do this.. can’t see a function in the field calculator.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Regards<u></u><u></u></p>
<p class="MsoNormal">Finbar<u></u><u></u></p>
</div>
<div>
*********************************************************************<br>
<br>
The contents and any attachments of this electronic mail message are confidential and intended only for the named addressees. Dissemination, forwarding, publication or other use of the message or attachments by any unauthorised person is strictly prohibited.<br>
<br>
Unless stated to the contrary, any opinions expressed in this message are personal and may not be attributed to AXA Insurance dac or any member of the AXA Group of Companies.<br>
<br>
AXA Insurance dac is regulated by the Central Bank of Ireland. For business in Northern Ireland, AXA Insurance dac is authorised by the Central Bank of Ireland and subject to limited regulation by the Financial Conduct Authority. Details about the extent of our regulation by the Financial Conduct Authority are available from us on request. AXA Insurance dac is a private company limited by shares, registered in Ireland number 136155. Registered Office Wolfe Tone House, Wolfe Tone Street, Dublin 1.<br>
<br>
"AXA Supporting Road Safety in Ireland"<br>
<br>
Internet e-mails are not necessarily secure. AXA Group does not accept responsibility for changes made to this message after it was sent. To help promote the use of electronic documents and to be kinder to the environment, please consider whether you really need to print this<br>
email.<br>
<br>
*********************************************************************<br>
</div></div>
_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a></blockquote></div>