![]() ![]() Should be a hash where keys are option names and values are option values. The OPTIONS clause to use for foreign tables. An array can be specified to inherit from multiple tables. The value should be the name of the foreign server that was specified in CREATE SERVER. Should only be specified when creating a temporary table.Ĭreate a foreign table. If this option is used, a block should not be given to the method.Įither :preserve_rows (default), :drop or :delete_rows. create_table :posts do primary_key :id column :title, String String :content index :title endĬreate the table using the value, which should be either a dataset or a literal SQL string. Set to true to not create the primary key.Ĭreates a table with the columns given in the provided block: DB. Set to true not to create the second index. Some table options are handled specially: :index_options In many cases, complex database defaults cannot be parsed into ruby objects, in which case nil will be used as the value.Ī symbol specifying the type, such as :integer or :string. The database default for the column, as a ruby object. If this column is not present, it means that primary key information is unavailable, not that the column is not a primary key. Whether the columns is a primary key column. The database default for the column, as a database specific string, or nil if there is no default value. The database type for the column, as a database specific string. Whether NULL is an allowed value for the column. If schema parsing is supported by the database, the column information hash should contain at least the following entries: :allow_null It may also be implicitly provided via the table name. Ignore any cached results, and get fresh information from the database.Īn explicit schema to use. ![]() The table argument can also be a dataset, as long as it only has one table. Returns the schema for the given table as an array with all members being arrays of length 2, the first member being the column name, and the second member being a hash of column information. supports_views_with_local_check_option?.supports_savepoints_in_prepared_transactions?.supports_deferrable_foreign_key_constraints?. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |