Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
janpisl committed Jun 28, 2018
1 parent e72076e commit 6702802
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pywps/inout/storage/db/pg.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,10 @@ def store_raster_output(self, file_name, identifier):

from subprocess import call, run, Popen, PIPE

# Convert raster to an SQL query
command1 = ["raster2pgsql", "-a", file_name, self.schema_name + "." + identifier]
p = Popen(command1,stdout=PIPE)
# Apply the SQL query
command2 = ["psql", "-h", "localhost", "-p", "5432", "-d", self.dbname]
run(command2,stdin=p.stdout)

Expand Down

0 comments on commit 6702802

Please sign in to comment.