Commit Graph

162 Commits

Author SHA1 Message Date
Collin Graves
69d657db6f English explanation to multi-level nested join
Added an "Or, in English..." explanation to the "Joining Nested Associations (Multiple Level)" example.
2016-01-27 21:54:34 -06:00
Kasper Timm Hansen
426b3127dd Merge pull request #23099 from vipulnsward/change_start_at_end_at
Changed options for find_each and variants to have options start/finish
2016-01-18 19:57:10 +01:00
Jon Moss
5f302eabae Merge pull request #22705 from RochesterinNYC/add-order-explanation-to-first-last-guides
Add clarification about `first` and `last` behavior when using `order` [ci skip]
2016-01-18 10:31:39 -05:00
Vipul A M
da26934313 Changed options for find_each and variants to have options start/finish instead of start_at/end_at based on comments
at https://github.com/rails/rails/pull/12257#issuecomment-74688344
2016-01-18 12:40:30 +05:30
ankit1910
390067161e [ci skip] fix typo in docs 2016-01-14 20:50:48 +05:30
James Wen
c70c42891e Add clarification about first and last behavior when using order [ci skip] 2015-12-20 03:34:00 -05:00
Genadi Samokovarov
2067fff9e3 Introduce ApplicationRecord, an Active Record layer supertype
It's pretty common for folks to monkey patch `ActiveRecord::Base` to
work around an issue or introduce extra functionality. Instead of
shoving even more stuff in `ActiveRecord::Base`, `ApplicationRecord` can
hold all those custom work the apps may need.

Now, we don't wanna encourage all of the application models to inherit
from `ActiveRecord::Base`, but we can encourage all the models that do,
to inherit from `ApplicationRecord`.

Newly generated applications have `app/models/application_record.rb`
present by default. The model generators are smart enough to recognize
that newly generated models have to inherit from `ApplicationRecord`,
but only if it's present.
2015-12-16 10:30:09 +01:00
Yves Senn
0dfca1db2a Merge pull request #22367 from andreynering/docs-ar-enums
Adding Enums section to AR Querying. [ci skip]
2015-12-10 14:40:06 +01:00
Andrey Nering
785043b81d Adding Enums section to Active Record Querying Guide. [ci skip] 2015-12-08 08:31:56 -02:00
Jeff Minnear
b20ef7e92f Modify unscoped usage guide to include chaining 2015-11-30 09:27:58 -05:00
r11runner
db45df361a [ci skip] querying guide methods first and last: mentioning the influence of the default scope 2015-10-31 23:36:27 +01:00
Sean Griffin
e038975c29 Merge pull request #12071 from Crunch09/outer_joins
added ActiveRecord::Relation#outer_joins
2015-10-30 09:42:02 -06:00
oesgalha
e1ca69713c Use #distinct instead of #uniq in the guides [ci skip]
* #uniq is an alias of #distinct
* #uniq will be deprecated, see: rails/rails@adfab2dcf4
2015-10-29 10:22:42 -02:00
Eileen M. Uchitelle
b455cadbfd Merge pull request #21333 from imtayadeway/ar-querying-docs
Improve the AR querying docs
2015-09-09 11:19:23 -04:00
Tim Wade
736ee9e104
[ci skip] Update MySQL docs reference to latest
Bumps to 5.7
2015-09-09 08:15:38 -07:00
Tim Wade
a0d7db760d
[ci skip] Improve readability in AR querying guide
* rewords a few awkwardly worded sentences
* adds some punctuation
* adds a few missing words
2015-09-09 08:15:23 -07:00
Yves Senn
5abff7cff7 guides, move incomplete example to corresponding option. #21349
[ci skip]

This example is dependent on the `:end_at` option and has been removed
from `4-2-stable` (d167b811520a6f800b86c77b805d15505a251bb8)
2015-08-24 11:47:59 +02:00
Mauro George
2ef1de02ed Add a note about default_scope and create records
[ci skip]
2015-07-16 18:24:39 -03:00
Florian Thomas
3f46ef1dda added ActiveRecord::Relation#left_outer_joins
Example:
  User.left_outer_joins(:posts)
  => SELECT "users".* FROM "users" LEFT OUTER JOIN "posts" ON "posts"."user_id" = "users"."id"
2015-05-19 10:43:01 +02:00
Yves Senn
e99d909928 Merge pull request #20119 from yui-knk/fix/active_record_querying
[ci skip] Fix `transaction` code example
2015-05-12 08:24:50 +02:00
yui-knk
7656d672aa [ci skip] Fix transaction code example 2015-05-12 13:49:27 +09:00
Tim Wade
663ffe9216
[ci skip] Improve phrasing on #explain pretty printing. 2015-05-10 09:43:13 -07:00
Alexey Markov
bd41f68f40 Fix find_each options [ci skip] 2015-04-22 21:37:38 +03:00
Vijay Dev
8ac458ad2e Merge branch 'master' of github.com:rails/docrails 2015-04-14 02:07:26 +00:00
yui-knk
66bf962a7a [ci skip] Add : 2015-04-01 19:59:54 +09:00
yui-knk
8f73c3ff61 [ci skip] Fix :having option with having method 2015-04-01 13:45:56 +09:00
Santosh Wadghule
2816494f5a Correct doc sentence [ci skip] 2015-03-27 12:25:58 +05:30
Anton Davydov
a290294175 [skip ci] Fix typos in guides 2015-03-15 23:55:06 +03:00
Konstantinos Rousis
793ff7585b Improve wording on find_by note regarding returning only one record [ci skip] 2015-02-21 16:44:05 +01:00
Vipul A M
6598272770 Deprecated passing of start value to find_in_batches and find_each in favour of begin_at value. 2015-02-17 14:10:35 +05:30
Vipul A M
3dc432068b Add an option end_at to find_in_batches
that complements the `start`parameter to specify where to stop batch processing
2015-02-09 01:33:57 +05:30
Oge Nnadi
3686513de7 Fixed extraneous quoting 2015-01-16 21:56:34 -08:00
Oge Nnadi
c0be81cfad Typo fix 2015-01-16 21:22:29 -08:00
Xavier Noria
7ba24831d7 Merge pull request #18503 from vipulnsward/guides-in-on
Changed `IN` to `ON` in markdown renderer condition
2015-01-14 11:35:34 +01:00
Vipul A M
5cfaf5a46e - Changed IN to ON in markdown renderer condition
- Changed `IN` to `ON` in all note sentences in guides.
2015-01-14 11:52:13 +05:30
Ahmad Al-kheat
edbc9468d5 Updated active_record_querying.md
Added the SQL equivalent of the find_by method

Update active_record_querying.md

Update active_record_querying.md
2015-01-12 18:19:48 -05:00
Max Katz
52a7873863 Add missing information regarding callbacks 2015-01-04 00:18:49 -07:00
Robin Dupret
d0703280c7 Avoid displaying new lines inside note paragraphs
Commit 65a2977 added a `pre-wrap` style for white spaces on `.note`
paragraphs. However, this is first inconsistent as other notes like
warnings don't have this style applied. Furthermore, it seems to be
unneeded for mobile devices.

Also revert changes made in #18147 since they aren't needed anymore.

Cross-refs #18138.

[ci skip]
2015-01-03 12:58:19 +01:00
Rafael Mendonça França
78dab2a856 Remove support to activerecord-deprecated_finders 2015-01-02 12:06:24 -03:00
Robin Dupret
73fe108d70 Minor documentation edits [ci skip] 2014-12-28 22:55:09 +01:00
Xavier Noria
7702974281 warn about reading guides in GitHub
References #18148.
2014-12-23 23:32:50 +01:00
Andrey Nering
024edd365b Do not use line breaks on notes [ci skip]
References #18138
2014-12-22 15:25:32 -02:00
Andrey Nering
75f389419d Improving Method Chaining section [ci skip] 2014-12-16 19:50:36 -02:00
Zachary Scott
7a7f44d1bd Merge pull request #18034 from andreynering/ar-guides-querying
Adding method chaining section on ActiveRecord querying guide [ci skip]
2014-12-15 18:34:07 -08:00
Andrey Nering
1cd8e71d21 Adding method chaining section on ActiveRecord querying guide [ci skip] 2014-12-15 18:38:58 -02:00
Andrey Nering
3cb11a3596 Already deprecated [ci skip] 2014-12-15 15:35:39 -02:00
tanmay3011
2e51d6f917 [ci skip] #find_in_batches doesn't support :include option 2014-09-12 17:14:24 +05:30
Cristian Bica
9e7f4a94ca Updated rdoc / guides / release notes related to ActiveJob / ActionMailer 2014-08-20 17:48:34 +03:00
Jay Shepherd
b494e94bc9 Small grammar fix in pluck description 2014-08-12 23:32:25 -04:00
Juanito Fatas
59b93dfda7 [ci skip] Remove duplicated last! section.
Reference: d4fd0bd177

cc @schneems
2014-07-16 23:12:13 +08:00