aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/active_record_querying.textile
Commit message (Collapse)AuthorAgeFilesLines
* ActiveRecord::Relation#pluck methodBogdan Gusiev2011-11-301-0/+9
|
* finders guide: adds some pointers to help users interpret the output of EXPLAINXavier Noria2011-11-251-0/+11
|
* add the query to AR::Relation#explain outputXavier Noria2011-11-251-0/+5
| | | | | | | Rationale: this is more readable if serveral queries are involved in one call. Also, it will be possible to let AR log EXPLAINs automatically in production mode, where queries are not even around.
* Merge branch 'master' of github.com:lifo/docrailsVijay Dev2011-11-081-10/+10
|\ | | | | | | | | Conflicts: railties/guides/source/active_record_querying.textile
| * fix markups for plus in AR guideVijay Dev2011-11-061-10/+10
| |
* | adds trailing +s to the output of EXPLAIN for MySQLXavier Noria2011-11-071-6/+6
|/
* implements AR::Relation#explainXavier Noria2011-11-051-0/+65
| | | | | | | | | | | | | | | | | | | This is a first implementation, EXPLAIN is highly dependent on the database and I have made some compromises. On one hand, the method allows you to run the most common EXPLAIN and that's it. If you want EXPLAIN ANALYZE in PostgreSQL you need to do it by hand. On the other hand, I've tried to construct a string as close as possible to the ones built by the respective shells. The rationale is that IMO the user should feel at home with the output and recognize it at first sight. Per database. I don't know whether this implementation is going to work well. Let's see whether people like it.
* Add ActiveRecord::Relation#uniq for toggling DISTINCT in the SQL queryJon Leighton2011-11-051-4/+20
|
* quoting 'and' to make it more distinct.Craig Monson2011-10-121-1/+1
|
* Heavy copy editing of the find_each and find_in_batches sectionmhutchin2011-10-111-26/+34
|
* Undid previous change which violated the convention regarding output (use "# ↵Manuel Menezes de Sequeira2011-10-061-13/+13
| | | | =>") used in these guides. Corrected typo in previous correction. (Thanks for pointing this out, vijaydev.)
* Some small corrections and improvements to the text.Manuel Menezes de Sequeira2011-10-051-30/+32
|
* Corrected a typo.Michael Hutchinson2011-09-271-1/+1
|
* No more changelogs inside guidesVijay Dev2011-09-151-9/+0
|
* change first_or_new to first_or_initialize as per 11870117, and some editsVijay Dev2011-09-141-10/+12
|
* Merge pull request #2757 from andmej/first_or_create_pull_requestJon Leighton2011-09-081-7/+68
|\ | | | | Add first_or_create family of methods to Active Record
| * Adding `first_or_new` documentation to the AR Querying guide.Nicolas Hock Isaza2011-08-301-1/+1
| |
| * Adding first_or_create, first_or_create!, first_or_new and first_or_build to ↵Andrés Mejía2011-08-301-7/+68
| | | | | | | | | | | | | | | | | | | | Active Record. This let's you write things like: User.where(:first_name => "Scarlett").first_or_create!(:last_name => "Johansson", :hot => true) Related to #2420.
* | some of the changes for validation earlier reverted from d20281aVijay Dev2011-09-031-2/+2
|/
* fixes generation of the AR querying guideXavier Noria2011-08-171-2/+2
|
* document the change in edge rails which makes a more strict check on the ↵Vijay Dev2011-07-231-0/+1
| | | | arity of the dynamic finders
* Updated active_record_querying.textile: intro paragraph of 'Conditions' to ↵Christopher Scott Hernandez2011-07-081-1/+1
| | | | change 'find method' to 'where method'
* correct invalid HAVING queryAkira Matsuda2011-06-291-3/+3
| | | | | * GROUP BY value must appear in SELECT clause * ("created_at < ?", 1.month.ago) wasn't a very good example for HAVING. you'd better use WHERE for such a simple condition
* correct invalid GROUP BY queryAkira Matsuda2011-06-291-2/+2
| | | | GROUP BY value must appear in SELECT clause
* minor indentation fixes on a6293ffVijay Dev2011-06-261-10/+10
|
* Update changelog for querying guideRyan Bigg2011-06-261-1/+2
|
* Querying guide: add mention of scoped, unscoped and default_scope to ↵Ryan Bigg2011-06-261-0/+41
| | | | querying guide
* document Active Record's reverse_order methodVijay Dev2011-06-201-0/+27
|
* Fix incorrect description of the returned results.Ben Orenstein2011-05-271-2/+2
|
* Copy edits 64148ab96b47a9904fdd839bc69971b4e156bb04 (previous commit). ↵Ben Orenstein2011-05-261-1/+1
| | | | Please squash at will.
* Improve 'Joining Tables' section with additional examples and explanation.Ben Orenstein2011-05-261-1/+29
|
* Don't you lie to me!Ben Orenstein2011-05-261-2/+2
|
* document the reorder method(fb215110401c70cfc7013c6e2ad5753fa4e374e9)Vijay Dev2011-04-281-4/+31
|
* Exception got moved to ActiveModel with Rails 3Eric Anderson2011-04-201-1/+1
|
* Remove extra whitespaces from guidesSebastian Martinez2011-04-141-2/+2
|
* Making colon usage consistentMatt Duncan2011-04-131-1/+1
|
* fix example queryVijay Dev2011-04-061-1/+1
|
* Delegate first!, last!, any? and many? to scopedAndrew White2011-03-291-0/+20
|
* impact recent updates to #first! and #last! methodsSebastian Martinez2011-03-251-3/+3
|
* Update AR querying guide with #first! and #last! new methodsSebastian Martinez2011-03-251-0/+34
|
* Querying guide: mention that performing a where on an relation that contains ↵Ryan Bigg2011-03-221-1/+3
| | | | an includes statement will generate a LEFT OUTER JOIN rather than an INNER JOIN or another query
* Querying guide: mention that performing a where on an relation that contains ↵Ryan Bigg2011-03-221-0/+14
| | | | an includes statement will generate a LEFT OUTER JOIN rather than an INNER JOIN or another query
* wrong SQL statementAkira Matsuda2011-03-061-1/+1
|
* Documented the except and only conditions in the guides. Took the cue from ↵Vijay Dev2011-01-151-2/+30
| | | | Jordi Ramero's commit (b31ef7ee83f3fe808f7534172ce2bf22ef6c7cc0)
* fixed query outputVijay Dev2011-01-091-2/+2
|
* highlighted find(array of keys) behaviour when one or more record is not foundVijay Dev2010-12-251-4/+2
|
* Revert "Query guide: arel_table, eq and eq_any" along with other commits ↵Ryan Bigg2010-12-241-131/+0
| | | | | | | | | | that added documentation involving the arel_table method This reverts commit 578f9711fdb42ca9fc4b8248c494afe755cd1c17. Conflicts: railties/guides/source/active_record_querying.textile
* Query guide: visists => visitsRyan Bigg2010-12-241-1/+1
|
* Query guide: add or conditionsRyan Bigg2010-12-231-0/+11
|
* Query guide: cover further ARel methodsRyan Bigg2010-12-231-7/+76
|