lib/dm-migrations/adapters/dm-mysql-adapter.rb
# Return SQL statement for the text column
#
# @param [Integer] length
#   the max allowed length
#
# @return [String]
#   the statement to create the text column
#
# @api private
Return SQL statement for the text column
Return SQL statement for the text column
def text_column_statement(length)
          if    length < 2**8  then 'TINYTEXT'
          elsif length < 2**16 then 'TEXT'
          elsif length < 2**24 then 'MEDIUMTEXT'
          elsif length < 2**32 then 'LONGTEXT'
          else
            raise ArgumentError, "length of #{length} exceeds maximum size supported"
          end
        end
def text_column_statement ( length ) if length < 2 ** 8 then 'TINYTEXT' elsif length < 2 ** 16 then 'TEXT' elsif length < 2 ** 24 then 'MEDIUMTEXT' elsif length < 2 ** 32 then 'LONGTEXT' else raise ArgumentError , "length of #{length} exceeds maximum size supported" end end
Return SQL statement for the text column
Return SQL statement for the text column
# http://www.postgresql.org/files/documentation/books/aw_pgsql/node90.html # Implies that PostgreSQL doesn't have a size limit on text # fields, so this param validation happens here instead of # DM::Property#initialize.
the statement to create the text column
the statement to create the text column
String
length
<not_specific>
<not_specific>
length the max allowed length
length the max allowed length
api
None