I need to iterate over a layer without the need of geometries.
I rembember I used this flag time ago and it worked fine. Now, if I set
this on the feature request, I get an empty set of features from the
iterator. Am I doing something wrong?

req = QgsFeatureRequest(QgsExpression('$area>1000,00'))
reg.setFlags(QgsFeatureRequest.NoGeometry)
feats = [f for f in mylayer.getFeatures(req)]

if a set the flags to QgsFeatureRequest.Noflags the iterator returns the
correct features.

giovanni

-- 
Giovanni Allegri
http://about.me/giovanniallegri
Twitter: https://twitter.com/_giohappy_
blog: http://blog.spaziogis.it
GEO+ geomatica in Italia http://bit.ly/GEOplus
_______________________________________________
Qgis-developer mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Reply via email to