Class: DB2Fog::PsqlAdaptor
- Inherits:
-
BaseAdaptor
- Object
- BaseAdaptor
- DB2Fog::PsqlAdaptor
- Defined in:
- lib/db2fog.rb
Instance Method Summary collapse
Methods inherited from BaseAdaptor
Constructor Details
This class inherits a constructor from DB2Fog::BaseAdaptor
Instance Method Details
#dump_command(dump_file) ⇒ Object
134 135 136 137 |
# File 'lib/db2fog.rb', line 134 def dump_command(dump_file) cmd = "pg_dump --clean --format=p --compress=9 #{}" cmd += " > #{dump_file.path}" end |
#restore(path) ⇒ Object
139 140 141 |
# File 'lib/db2fog.rb', line 139 def restore(path) run "gunzip -c #{path} | psql #{}" end |