Bug report #1746

ogr provider functions uniqueValues(), minimum(), maximum() only work for file based datasources

Added by Marco Hugentobler over 11 years ago. Updated over 11 years ago.

Status:Closed
Priority:Low
Assignee:nobody -
Category:Data Provider
Affected QGIS version: Regression?:No
Operating System:All Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:11806

Description

The ogr provider functions uniqueValues(), minimum(), maximum() only work for file based datasources. Also, if a sublayer of the datasouce is requested, the function only returns an empty variant:

QFileInfo fi( dataSourceUri() );
if ( !fi.exists() )
return QVariant();

Better approach would be to find out the layername and change the SQL accordingly

Associated revisions

Revision ce8a9fc8
Added by Jürgen Fischer over 11 years ago

OGR provider update (fixes #1746)
- use OGR and not the filename to deduce the layername
- fall back to QgsVectorDataProvider methods if OGR SQL doesn't work
- check error code of OGR_L_SetFeature

git-svn-id: http://svn.osgeo.org/qgis/trunk/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

Revision 36b1cb73
Added by Jürgen Fischer over 11 years ago

OGR provider update (fixes #1746)
- use OGR and not the filename to deduce the layername
- fall back to QgsVectorDataProvider methods if OGR SQL doesn't work
- check error code of OGR_L_SetFeature

git-svn-id: http://svn.osgeo.org/qgis/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

History

#1 Updated by Jürgen Fischer over 11 years ago

fixed in

#2 Updated by Jürgen Fischer over 11 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

Also available in: Atom PDF