class method self.build

Ruby on Rails 7.2.3.2

Since v7.2.3.2

Available in: v7.2.3.2 v8.0.5.1 v8.1.3.1 edge

Signature

self.build(database_name)

No documentation comment.

Parameters

database_name req
Source
# File railties/lib/rails/generators/database.rb, line 9
        def build(database_name)
          case database_name
          when "mysql" then MySQL.new
          when "postgresql" then PostgreSQL.new
          when "trilogy" then MariaDB.new
          when "sqlite3" then SQLite3.new
          else Null.new
          end
        end

Defined in railties/lib/rails/generators/database.rb line 9 · View on GitHub · Improve this page · Find usages on GitHub

Defined in Rails::Generators::Database

Type at least 2 characters to search.

Use the arrow keys to navigate results, Enter to open one, Escape to close.

Keyboard shortcuts

/
Focus search
⌘K / Ctrl-K
Command palette
?
This help
Esc
Close