Class: ActiveRecord::ConnectionAdapters::YugabyteDB::DatabaseTasks

Inherits:
Tasks::PostgreSQLDatabaseTasks
  • Object
show all
Defined in:
lib/active_record/connection_adapters/yugabytedb/database_tasks.rb

Instance Method Summary collapse

Instance Method Details

#structure_load(filename, extra_flags) ⇒ Object



7
8
9
10
11
12
13
# File 'lib/active_record/connection_adapters/yugabytedb/database_tasks.rb', line 7

def structure_load(filename, extra_flags)
  # todo
  args = ["--set", ON_ERROR_STOP_1, "--quiet", "--no-psqlrc", "--output", File::NULL, "--file", filename]
  args.concat(Array(extra_flags)) if extra_flags
  args << db_config.database
  run_cmd("psql", args, "loading")
end