# File lib/dm-migrations/sql/postgres.rb, line 39 def change_column_type_statement(name, column) "ALTER TABLE #{quote_name(name)} ALTER COLUMN #{column.to_sql}" end
# File lib/dm-migrations/sql/postgres.rb, line 22 def property_schema_statement(connection, schema) if supports_serial? && schema[:serial] statement = "#{schema[:quote_column_name]} SERIAL PRIMARY KEY" else statement = super if schema.has_key?(:sequence_name) statement << " DEFAULT nextval('#{schema[:sequence_name]}') NOT NULL" end statement end statement end
# File lib/dm-migrations/sql/postgres.rb, line 12 def recreate_database execute 'DROP SCHEMA IF EXISTS test CASCADE' execute 'CREATE SCHEMA test' execute 'SET search_path TO test' end
# File lib/dm-migrations/sql/postgres.rb, line 4 def supports_schema_transactions? true end
# File lib/dm-migrations/sql/postgres.rb, line 18 def supports_serial? true end
Generated with the Darkfish Rdoc Generator 2.