1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/lib/active_record
schneems 0ec45cd15d Tell how to Create a Database in Error Message
Currently if you attempt to use a database that does not exist  you get an error:

```
PG::ConnectionBad FATAL:  database "db_error" does not exist
```

The solution is easy, create and migrate your database however new developers may not know these commands by memory. Instead of requiring the developer to search for a solution, tell them how to fix the problem in the error message:

```
ActiveRecord::NoDatabase: FATAL:  database "db_error" does not exist
Run `$ bin/rake db:create db:migrate` to create your database
```

Active Record should not know about `rake db:migrate` so this additional information needs to come from the railtie. Potential alternative implementation suggestions are welcome.
2013-12-23 10:23:48 -05:00
..
associations On destroying do not touch destroyed belongs to association. 2013-12-23 15:44:48 +02:00
attribute_methods Fix typo: data --> date 2013-12-19 16:13:18 +10:00
coders
connection_adapters Tell how to Create a Database in Error Message 2013-12-23 10:23:48 -05:00
fixture_set Introduce a context for rendering fixtures ERB. 2013-12-03 02:52:26 -05:00
locale Revert "Merge pull request #11416 from tigrish/master" 2013-07-22 09:57:51 +03:00
locking pass the pk to compile_update 2013-11-16 14:20:22 -08:00
migration Make 'enable_extension' revertible 2013-08-10 03:25:04 -04:00
railties db:test:clone and prepare must load environment 2013-12-14 17:33:50 -05:00
relation fix default select when from is used 2013-12-19 14:40:13 -07:00
scoping Don't need to check if the scope respond to call 2013-08-31 14:53:28 -03:00
serializers
tasks Revert "Explicitly exit with status "1" for create and drop failures" 2013-11-19 13:07:28 -02:00
validations Cleanups in API docs: his => their 2013-12-02 00:34:52 -05:00
aggregations.rb Remove conditional adding a new method 2013-09-11 21:24:59 -03:00
association_relation.rb Move #proxy_association method to AssociationRelation 2013-05-10 16:39:27 +02:00
associations.rb remove HABTM associations 2013-10-02 16:03:45 -07:00
attribute_assignment.rb assign_attributes should return if argument is blank. 2013-09-24 13:22:59 -05:00
attribute_methods.rb fix typos and grammar mistake [ci skip] 2013-12-19 12:02:01 +05:30
autosave_association.rb Save association when primary key is manually set 2013-10-24 22:30:30 -02:00
base.rb Remove deprecated cattr_* requires 2013-12-03 00:28:15 +02:00
callbacks.rb Fix ActiveRecord::Callbacks sample code [ci skip] 2013-12-03 23:27:23 +09:00
connection_handling.rb
core.rb [ci skip] used new syntax for scopes 2013-11-27 12:23:23 +05:30
counter_cache.rb Spelling and Grammar checks 2013-12-12 18:28:34 +05:30
dynamic_matchers.rb Prevent invalid code when using dynamic finders with Ruby's reserved words. 2013-12-11 01:00:32 -02:00
enum.rb Fix comment example in AR enum [ci skip] 2013-12-23 13:18:06 -02:00
errors.rb Tell how to Create a Database in Error Message 2013-12-23 10:23:48 -05:00
explain.rb
explain_registry.rb
explain_subscriber.rb Don't try to EXPLAIN select_db calls 2013-05-10 16:21:59 +02:00
fixtures.rb Merge branch 'master' of github.com:lifo/docrails 2013-12-20 00:10:30 +05:30
inheritance.rb no need to to_sym 2013-10-09 16:09:59 -07:00
integration.rb Fix to_param when attribute has multibyte character 2013-12-19 05:29:16 +09:00
log_subscriber.rb type casted PG bytea values are represented as a Hash. 2013-11-09 20:55:01 +01:00
migration.rb ActiveRecord migration exception message formatting 2013-12-03 12:23:43 -05:00
model_schema.rb added schema_migrations_table_name to ActiveRecord::Base in order that the name of the schema migrations table can be configured. 2013-10-27 08:50:35 -05:00
nested_attributes.rb Renamed generated_feature_methods to generated_association_methods. 2013-09-28 12:26:23 +09:00
no_touching.rb add #no_touching on ActiveRecord models 2013-11-13 08:42:38 +01:00
null_relation.rb Mark the arguments needed by activerecord-deprecated_finders with a TODO 2013-12-11 13:35:34 -02:00
persistence.rb [ci skip]removed obsolete information about options parameter in create method 2013-11-27 13:53:19 +05:30
query_cache.rb
querying.rb Delegate #rewhere to all on the class like all other relation methods 2013-11-02 19:45:03 -07:00
railtie.rb Tell how to Create a Database in Error Message 2013-12-23 10:23:48 -05:00
readonly_attributes.rb Remove instance level attr_readonly setting was deprecated. 2013-06-02 10:25:41 +09:00
reflection.rb scope_chain should not be mutated for other reflections 2013-10-14 11:59:59 -04:00
relation.rb Fix ActiveRecord::Relation#unscope 2013-11-20 22:23:16 +00:00
result.rb Also dup column_types in AR::Result initialize_copy 2013-11-10 00:25:57 +05:30
runtime_registry.rb Stop using method missing for singleton delegation. 2013-11-06 16:32:47 -08:00
sanitization.rb Add nodoc to method 2013-10-13 16:54:04 -03:00
schema.rb Call assume_migrated_upto_version on connection 2013-05-11 22:39:39 -04:00
schema_dumper.rb Push default_function to superclass to avoid method check 2013-10-14 01:46:41 -03:00
schema_migration.rb added schema_migrations_table_name to ActiveRecord::Base in order that the name of the schema migrations table can be configured. 2013-10-27 08:50:35 -05:00
scoping.rb
serialization.rb
statement_cache.rb
store.rb improve Active Record Store docs when using PG types. [ci skip]. 2013-11-09 21:05:28 +01:00
timestamp.rb Refactor logic to grab the max time of the list of timestamp names in #cache_key 2013-11-04 13:14:07 -02:00
transactions.rb Fixed typo with after_commit docs 2013-10-25 16:59:48 -04:00
translation.rb
validations.rb
version.rb Get ready to release 4.1.0.beta1 2013-12-17 16:05:28 -08:00