Hi,

you can use the layer filter for this. The exact filter expression depends on 
the data source you use, because you have to use the SQL-Syntax of your data 
source.
To filter a layer with data source in an geopackage you can use:
"HubDist" = (select min(HubDist) from hubs)

min() is the minimum function in SQLite (geopackage uses SQLite-Syntax), hubs 
is the name of the layer.
In PostgreSQL the function is also called min(). In other data source it may be 
another function (if there is one).

Regards Dirk

Von: QGIS-User [mailto:qgis-user-boun...@lists.osgeo.org] Im Auftrag von Igor 
Oliveira Ribeiro via QGIS-User
Gesendet: Freitag, 17. Februar 2023 20:25
An: qgis-user <qgis-user@lists.osgeo.org>
Betreff: [Qgis-user] [FILTER] How to filter a layer by minimum attribute value

Hi,
how can I filter layer by the minimum value of the field "HubDist" in the 
attribute table?
See my attribute table below. As result, I expect only one attribute being 
showed in my map related to "HubDist" equal 111.3546... (the value in the first 
line).
[image.png]

Thanks for your help.

--


See our last paper: <https://doi.org/10.1016/j.envpol.2020.114029>

Impact of biomass burning on a metropolitan area in the Amazon during the 2015 
El Niño: The enhancement of carbon monoxide and levoglucosan 
concentrations.<https://doi.org/10.1016/j.envpol.2020.114029>


[https://lh5.googleusercontent.com/-bliIGlTBH64UHBAAns8Ubhxgih0cgNVZjNAWPkBZSkYIa-o9idb3Km_x571oZ3NL0nZVMvFmclRedyzJDfv00BMdZPjcKg4zD1y1yGGErKoPszFJuTRjvN_0fmLsa4Ah_2YTtxJ]


Igor Oliveira Ribeiro

Post-Doc on Regional Climate Change, Vulnerability, Impacts and Adaptation - 
Cuomo Foundation/UEA


+55 92 98103 7136 | skype: igorflorestal


Universidade do Estado do Amazonas | Instituto Nacional de Pesquisas da Amazônia


Visite: www.geoescrita.com.br<http://www.geoescrita.com.br>


[https://lh4.googleusercontent.com/2py0KXy5JccNXFC-38-2TT9wnYCQAXMRBlM5H0eOS83jy2Sz-PUr9_1C57srnad478ma9o9_fAYHjUhFN7Hza3OOCSiFHFpboznBl1PpVLavbfnjGYoU1usFc0W8j9pS4VzAKwCV]<https://www.linkedin.com/in/igoroliveiraribeiro/>[https://lh4.googleusercontent.com/-FUMJ4HbrYAwwTKB49CF6r39wVYnoWf1AD9ZLKvD6Z1Cu1yqyo8NRk-InWHOa34J87OHDcJcCstkC_khG2_jCc6qDGop64cV2F0OL-IZ1S3Jgf9SfxVF08U9xfx47ov24InhjsqE]<https://www.instagram.com/geoescrita/>[https://lh6.googleusercontent.com/ert1Bk_3idA2Vb4MK8Hd3B1p2vdcL52JrOmNjaGhhbS7caCNQiZwRKKX55B9pB7-3j2nPFttXJezhSxrHQeBpnEnpeD_CRjzBQgPo5hG5C68qhY1wRFMu0PDv9LbQ8iY8-K4bwIk]<https://www.researchgate.net/profile/Igor_Oliveira_Ribeiro>[https://lh6.googleusercontent.com/z9emf1sj2DW-tYYJZ6Qkd3RxvB23DjQdH7bLcTDIv9zyi-XnZRAroZBc8OPJqQkDIvZJBpd7GCa-2ClAT2gT3ubJ4yZj1BA0-T8hGgBboms-kjpowUuhBQO4z4EcWDwF9w25FGiy]<http://lattes.cnpq.br/3909691804095045>[https://lh4.googleusercontent.com/fOmYAxdij-Q_UFG3dFFnhy_zegLQSPZcgxSE-l8u9XuSz6LvnUGItsmoPZL_GCcfoYF2yl9dqYGs3842AcozPLqY103OWAe1x-js_lNLXym1Wcde7j4r19_vICiJXP5xaE_-KPIL]<https://orcid.org/0000-0002-3529-0525>[https://lh3.googleusercontent.com/H041znsV0LChyhfdBIDwXHwIh5BUG2TCmQYBSI1d4eF1NX80_T79MtdQqif3DHpBIDgzvXhuXDLc0l77eylJCPuW7jbalTIbVqBg-dm8S-JHOxZh458R0UX8SsJINhcqw7nG7_Pw]<https://www.geoescrita.com.br/>


Think globally, act locally!


_______________________________________________
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to