{"id":980,"date":"2018-01-20T12:14:41","date_gmt":"2018-01-20T11:14:41","guid":{"rendered":"http:\/\/hannes.enjoys.it\/blog\/?p=980"},"modified":"2018-01-20T12:15:38","modified_gmt":"2018-01-20T11:15:38","slug":"specifying-the-read-open-driver-format-with-gdal-ogr","status":"publish","type":"post","link":"https:\/\/hannes.enjoys.it\/blog\/2018\/01\/specifying-the-read-open-driver-format-with-gdal-ogr\/","title":{"rendered":"Specifying the read\/open driver\/format with GDAL\/OGR"},"content":{"rendered":"<p>For the commandline utilities you can&#8217;t. One possible workaround is using <a href=\"https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#GDAL_SKIP\">https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#GDAL_SKIP<\/a> and <a href=\"https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#OGR_SKIP\">https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#OGR_SKIP<\/a> to blacklist drivers until the one you want is its first choice. A feature request exists  at <a href=\"https:\/\/trac.osgeo.org\/gdal\/ticket\/5917\">https:\/\/trac.osgeo.org\/gdal\/ticket\/5917<\/a> but it seems that the option is not exposed as commandline option (yet?).<\/p>\n<p>PS: If what you are trying to do is reading a .txt (or whatever) file as .csv and you get angry at the CSV driver only being selected if the file has a .csv extension, use CSV:yourfilename.txt<\/p>\n<p>PPS: This post was motivated by not finding above information when searching the web. Hopefully this will rank high enough for *me* to find it next time. ;)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For the commandline utilities you can&#8217;t. One possible workaround is using https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#GDAL_SKIP and https:\/\/trac.osgeo.org\/gdal\/wiki\/ConfigOptions#OGR_SKIP to blacklist drivers until the one you want is its first choice. A feature request exists at https:\/\/trac.osgeo.org\/gdal\/ticket\/5917 but it seems that the option is not exposed as commandline option (yet?). PS: If what you are trying to do is reading [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[22,24,29,30,40],"tags":[],"class_list":["post-980","post","type-post","status-publish","format-standard","hentry","category-commandline","category-gdal","category-gis","category-ogr","category-small-things"],"_links":{"self":[{"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/posts\/980","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/comments?post=980"}],"version-history":[{"count":2,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/posts\/980\/revisions"}],"predecessor-version":[{"id":983,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/posts\/980\/revisions\/983"}],"wp:attachment":[{"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/media?parent=980"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/categories?post=980"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/hannes.enjoys.it\/blog\/wp-json\/wp\/v2\/tags?post=980"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}