Class: Flydata::SourcePostgresql::SyncGenerateTableDdl
Defined Under Namespace
Classes: TableMissingError
Instance Attribute Summary
#dp
Instance Method Summary
collapse
#generate_flydata_tabledef, inherited, #initialize
#initialize
Instance Method Details
#data_entry_prefs ⇒ Object
17
18
19
|
# File 'lib/flydata/source_postgresql/sync_generate_table_ddl.rb', line 17
def data_entry_prefs
de['postgresql_data_entry_preference']
end
|
#data_source_type_display_name ⇒ Object
13
14
15
|
# File 'lib/flydata/source_postgresql/sync_generate_table_ddl.rb', line 13
def data_source_type_display_name
"PostgreSQL database"
end
|
#each_source_tabledef(tables, options, &block) ⇒ Object
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
# File 'lib/flydata/source_postgresql/sync_generate_table_ddl.rb', line 21
def each_source_tabledef(tables, options, &block)
tables = tables.clone
missing_tables = []
begin
if tables.to_s == '' || tables.to_s == '[]'
raise ArgumentError, "tables is nil or empty"
end
_each_tabledef(tables, options, &block)
rescue TableMissingError => e
tables.delete e.table
missing_tables << e.table
return missing_tables if tables.empty?
retry
end
missing_tables
end
|
#run_compatibility_check ⇒ Object
9
10
11
|
# File 'lib/flydata/source_postgresql/sync_generate_table_ddl.rb', line 9
def run_compatibility_check
end
|