Re: [QGIS-Developer] QgsFeatureRequest SortByOrder

2018-06-04 Thread Matthias Kuhn
Hi Jorge, There are two possibilities, one is to use the full-blown API with OrderBy class etc. And then there is a shorthand for this, called QgsFeatureRequest.addOrderBy which is enough in 90% of the cases. Short version: request = QgsFeatureRequest() request.addOrderBy('field_name')

[QGIS-Developer] QgsFeatureRequest SortByOrder

2018-06-01 Thread Jorge Almerio
Can anyone help me how to iterate through features using a Field as a sort order? I saw that there is a function setOrderBy on QgsFeatureRequest, by it seems to request a OrderBy Class argument, but I