Module: Schema

Defined in:
lib/utils/schema.rb

Class Method Summary collapse

Class Method Details

.convert_type_to_postgres(data_type_id) ⇒ Object



4
5
6
7
# File 'lib/utils/schema.rb', line 4

def self.convert_type_to_postgres(data_type_id)
  type = PG_TYPES.find { |t| data_type_id == t[:oid] }&.dig(:typname)
  type || 'varchar'
end