I have a little question, regarding the gdal_translate-utility:

I want to extract raster-files from database-stored gridfiles using the gdal_translate:

gdal_translate -ot Float32 -of SAGA PG: "host='localhost' port='5432' dbname='$dbname' user='$dbowner' schema='grids' table='testrun' mode='2'" /output/...

But instead of delivering output it shows me "Too many command options." Then it lists usage and supported output formats. What does this message mean? I was searching the net already but found nothing which could be helpful.

Thanks for an answer in advance, knutella

  • 1
    It probably means that you haven't specified the command args in a valid way. You have either supplied incorrect args or the formatting has caused gdal to parse it in a way that is not expected.
    – DavidF
    Jan 9, 2013 at 14:09
  • Thanks David, for your quick reply. It seems that connection-arguments are committed properly through the script/me. About the input format from database I'm not sure now, because there is complex function behind. I guess I must dive a bit deeper into the dbase. Thanks David.
    – knutella
    Jan 9, 2013 at 14:34
  • UPDATE: It was indeed my fault: I forgot to put the mode=2 into inverted comma... %) In question-post its corrected already.
    – knutella
    Jan 9, 2013 at 14:43


Browse other questions tagged or ask your own question.