<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -11,15 +11,15 @@
 
 	&lt;div class=&quot;halftitlepage&quot;&gt;
 		&lt;h1 class=&quot;no-toc&quot;&gt;Ruby on Rails 2.1&lt;/h1&gt;
-		&lt;h2 class=&quot;no-toc&quot;&gt;What's New&lt;/h2&gt;
-		&lt;h3 class=&quot;no-toc&quot;&gt;Second Edition&lt;/h3&gt;
+		&lt;h2 class=&quot;no-toc&quot;&gt;&#26032;&#29305;&#24615;&#20171;&#32461;&lt;/h2&gt;
+		&lt;h3 class=&quot;no-toc&quot;&gt;&#31532;&#20108;&#29256; (&#20013;&#25991;&#29256;)&lt;/h3&gt;
 	&lt;/div&gt;
 
 	&lt;div class=&quot;titlepage&quot;&gt;
 	&lt;h1 class=&quot;no-toc&quot;&gt;Ruby on Rails 2.1&lt;/h1&gt;
 
-	&lt;h2 class=&quot;no-toc&quot;&gt;What's New&lt;/h2&gt;
-	&lt;h3 class=&quot;no-toc&quot;&gt;Second Edition&lt;/h3&gt;
+	&lt;h2 class=&quot;no-toc&quot;&gt;&#26032;&#29305;&#24615;&#20171;&#32461;&lt;/h2&gt;
+	&lt;h3 class=&quot;no-toc&quot;&gt;&#31532;&#20108;&#29256; (&#20013;&#25991;&#29256;)&lt;/h3&gt;
 
 	&lt;p class=&quot;no-toc&quot;&gt;Carlos Brando&lt;br/&gt;Marcos Tapaj&#243;s&lt;/p&gt;
 	&lt;!-- also, the publisher's name would typically be printed here --&gt;</diff>
      <filename>layout/pdf_template.html</filename>
    </modified>
    <modified>
      <diff>@@ -42,8 +42,8 @@ class Prince
     path &lt;&lt; ' --silent - -o -'
 
     # Show the command used...
-    puts &quot;\n\nPRINCE XML PDF COMMAND&quot;
-    puts path
+    #logger.info &quot;\n\nPRINCE XML PDF COMMAND&quot;
+    #logger.info path
     #logger.info ''
 
     # Actually call the prince command, and pass the entire data stream back.</diff>
      <filename>script/prince.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,10 +1,11 @@
-#Introduction
+#&#27010;&#36848;(Introduction)
 
-Around July of 2004 David Heinemeier Hansson publicly released the Ruby on Rails framework. The framework had been extracted from a web application called he was working on called Basecamp. More than three years later, on the December 7th 2007, Ruby on Rails version 2.0 was released with numerous important changes.
+2004&#24180;7&#26376;&#65292;David Heinemeier Hansson&#20174;&#20854;&#39033;&#30446; Basecamp&#20013;&#25277;&#21462;&#24182;&#21457;&#24067;&#20102; Ruby On Rails&#26694;&#26550;&#12290;&#19977;&#24180;&#21518;&#30340;2007&#24180;12&#26376;7&#26085;&#65292;&#20855;&#26377;&#21010;&#26102;&#20195;&#24847;&#20041;&#30340; Ruby On Rails 2.0&#29256;&#26412;&#21457;&#24067;&#20102;&#65292;&#20854;&#20013;&#21253;&#21547;&#20102;&#19968;&#31995;&#21015;&#30340;&#26032;&#20869;&#23481;&#12290;
 
-Six months have passed since then, and during this time more than **1400 developers** from all around the world have contributed  **1600 patches** to the framework. Today, June 1st 2008, version 2.1 of the Ruby on Rails framework was released.
+&#25509;&#19979;&#26469;&#30340;&#20845;&#20010;&#26376;&#65292;&#20840;&#19990;&#30028;**1400**&#22810;&#21517;&#24320;&#21457;&#32773;&#20026; Rails&#36129;&#29486;&#20102;**1600**&#22810;&#20010;patch&#65292;&#20170;&#22825;,2008&#24180;6&#26376;1&#26085;,Ruby On Rails 
+2.1&#21457;&#24067;&#20102;&#12290;
 
-Major new features according to David Heinemeier Hansson:
+&#26412;&#27425;&#21457;&#24067;&#21253;&#21547;&#20294;&#19981;&#38480;&#20110;&#22914;&#19979;&#21151;&#33021;&#28857;:
 
 * Timezones
 * Dirty tracking
@@ -13,42 +14,69 @@ Major new features according to David Heinemeier Hansson:
 * UTC-based migrations
 * Better caching
 
-As always, to update or install the new version:
+&#21644;&#20197;&#24448;&#19968;&#26679;&#65292;&#26356;&#26032;Rails&#24456;&#31616;&#21333;&#65306;
 
 	gem install rails
 
-##Acknowledgment
+##&#33268;&#35874;
 
-To Marcos Tapaj&#243;s, co-author of this book. If it wasn't for him, you probably you wouldn't be reading this right now.
+&#24863;&#35874;Marcos Tapaj&#243;s,&#22914;&#26524;&#27809;&#26377;&#20182;&#65292;&#25105;&#20204;&#21040;&#29616;&#22312;&#32943;&#23450;&#30475;&#19981;&#21040;&#36825;&#26412;&#20070;&#65307;&#24863;&#35874;Daniel Lopes&#32473;&#26412;&#20070;&#21046;&#20316;&#20102;&#28418;&#20142;&#30340;&#23553;&#38754;&#65307;
 
-To Daniel Lopes who made the beautiful cover for this edition.
+&#36824;&#26377;Ruby on Rails Brazilian&#20013;&#37027;&#20123;&#30452;&#25509;&#25110;&#32773;&#38388;&#25509;&#32473;&#26412;&#20070;&#25552;&#20379;&#24110;&#21161;&#30340;&#26379;&#21451;&#20204;&#65292;&#24744;&#20204;&#30340;&#35780;&#35770;&#21644;&#24314;&#35758;&#37117;&#24357;&#36275;&#29645; &#36149;&#65292;&#27491;&#20687;&#25105;&#20197;&#24448;&#35828;&#30340;&#19968;&#26679;&#65292;Rails&#20013;&#26368;&#31934;&#21326;&#30340;&#26159;&#20854;&#20805;&#28385;&#28608;&#24773;&#12289;&#21019;&#36896;&#21147;&#21644;&#20998;&#20139;&#31934;&#31070;&#30340;&#31038;&#21306;&#65307;
 
-To all of the Ruby on Rails Brazilian community that helped directly or indirectly with this book, commenting on blog posts and giving suggestions. It's like I always say, the best of Rails is its community! Keep creating, inventing, and specially sharing.
+&#36824;&#26377;chinaonrails.com&#31038;&#21306;&#20013;&#30340;&#26379;&#21451;&#20204;&#65292;&#27491;&#26159;&#22823;&#23478;&#30340;&#36763;&#21220;&#24037;&#20316;&#65292;&#25165;&#20351;&#24471;&#25105;&#20204;&#33021;&#36825;&#20040;&#30701;&#30340;&#26102;&#38388;&#20869;&#21363;&#21487;&#23436;&#25104; 
+&#32763;&#35793;&#65292;&#35874;&#35874;&#20320;&#20204;&#12290;
 
-## Translators
+##&#20013;&#25991;&#35793;&#32773;
 
-This book was proudly translated to english by these Brazilian guys:
+&#26412;&#20070;&#27491;&#26159;&#30001;China on Rails&#31038;&#21306;&#20013;&#19968;&#20123;&#26379;&#21451;&#32763;&#35793;&#25104;&#20013;&#25991;&#30340;,&#25105;&#20204;&#26159;&#65306;
 
-**Pedro Pimentel** - [http://www.pedropimentel.com](http://www.pedropimentel.com)
+**IceskYsl**
+[http://iceskysl.1sters.com/](http://iceskysl.1sters.com/)
 
-Chapters 3-8 and 10-13
+&#31532;1&#31456;(Introduction)&#65292;&#31532;9&#31456;(Rake Tasks, Plugins and Scripts) 
+&#31532;11&#31456;(Ruby 1.9)&#65292;&#31532;14&#31456;(Additional Information). 
 
-**Rafael Barbosa** - [http://www.act-as-newbie.com](http://www.act-as-newbie.com/)
+**jesse.cai**
+[http://www.caiwangqin.com/](http://www.caiwangqin.com)
 
-Introduction and chapter 1
+&#31532;5&#31456;(ActionPack)&#65292;&#31532;12&#31456;(Debug)
 
-**Ricardo S Yasuda** - [http://blog.shadowmaru.org](http://blog.shadowmaru.org/)
+**suave.su**
+[http://chinaonrails.com/u/suave](http://chinaonrails.com/u/suave)
+&#31532;1&#31456;(Introduction) 
 
-Chapter 14
+**dongbin**
+[http://dongbin.org/](http://dongbin.org/)
 
-**Caike Souza** - [http://tech-death.blogspot.com](http://tech-death.blogspot.com/)
+&#31532;3&#31456;(ActiveSupport)
 
-Chapter 2
+**&#28023;&#38451;**
+[http://rubyjin.cn/](http://rubyjin.cn/)
 
-**Abra&#227;o Coelho** - [http://abrcoelho.net](http://abrcoelho.net/)
+&#31532;6&#31456;(ActionController) 
 
-Chapter 9
+**404**
+[http://chinaonrails.com/u/404](http://chinaonrails.com/u/404)
 
-**Bruno Miranda** - [http://brunomiranda.com](http://brunomiranda.com)
+&#31532;8&#31456;(Railties) 
 
-Reviser
\ No newline at end of file
+**ashchan**
+[http://blog.ashchan.com/](http://blog.ashchan.com/)
+
+&#31532;4&#31456;(ActiveResource),&#31532;10&#31456;(Prototype and script.aculo.us) 
+
+**cash.zhao**
+[http://www.cashplk.com/](http://www.cashplk.com/)
+
+&#31532;7&#31456;(ActionView),&#31532;13&#31456;(Bugs and Fixes) 
+
+**snow zhang**
+[http://blog.snowonrails.com](http://blog.snowonrails.com)
+
+&#31532;2&#31456;(ActiveRecord)
+
+**Libin Pan**
+[http://blog.libinpan.com](http://blog.libinpan.com)
+
+Markdown Editor
\ No newline at end of file</diff>
      <filename>text/0/0_Title.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,3 @@
 # ActiveRecord
-              
-ActiveRecord is an object-relational mapping layer responsible for the interoperability among application
-and database and also responsible for data abstraction. (wikipedia)
\ No newline at end of file
+
+ActiveRecord&#26159;&#19968;&#20010;&#23545;&#35937;-&#20851;&#31995;&#26144;&#23556;&#23618;&#65292;&#20027;&#35201;&#36127;&#36131;&#24212;&#29992;&#23618;&#21644;&#25968;&#25454;&#23618;&#20043;&#38388;&#30340;&#20114;&#25805;&#20316;&#24615;(&#35299;&#32806;)&#20197;&#21450;&#25968;&#25454;&#25277;&#35937;&#12290;(wikipedia)
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/00.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,15 +1,13 @@
-## The **sum** method
+## **sum**&#26041;&#27861;
 
-### Expressions in the **sum** method
-            
-Now we can use expressions in **ActiveRecord** methods that deal with calculation, like **sum**, for example:
+### **sum**&#26041;&#27861;&#20013;&#30340;&#34920;&#36798;&#24335;
 
-	Person.sum(&quot;2 * age&quot;)
+&#29616;&#22312;&#25105;&#20204;&#21487;&#20197;&#22312;**ActiveRecord**&#26041;&#27861;&#24403;&#20013;&#20351;&#29992;&#34920;&#36798;&#24335;&#26469;&#22788;&#29702;&#35832;&#22914;**sum**&#31561;&#21508;&#31181;&#35745;&#31639;&#65292;&#22914;&#65306;
 
-### Change in the default return value of the sum method
+	Person.sum(&quot;2 * age&quot;)
 
-On previous versions, when we used **ActiveRecord**'s **sum** method to calculate the addition of all rows in a table and no row matched the conditions expressed during the method invocation, then the default return value would be **nil**.
+### **sum**&#26041;&#27861;&#40664;&#35748;&#36820;&#22238;&#20540;&#30340;&#25913;&#21464;
 
-In Rails 2.1 the default return value (that is when no row is found) is 0. See the example:
+&#22312;&#20043;&#21069;&#30340;&#29256;&#26412;&#20013;&#65292;&#24403;&#25105;&#20204;&#20351;&#29992;**ActiveReocrd**&#30340;**sum**&#26041;&#27861;&#26469;&#35745;&#31639;&#34920;&#20013;&#25152;&#26377;&#35760;&#24405;&#30340;&#21644;&#30340;&#26102;&#20505;&#65292;&#22914;&#26524;&#27809;&#26377;&#36319;&#25152;&#38656;&#26465;&#20214;&#21305;&#37197;&#30340;&#35760;&#24405;&#30340;&#26102;&#20505;&#65292;&#21017;&#40664;&#35748;&#30340;&#36820;&#22238;&#20540;&#26159;**nil** &#12290;&#22312; Rails2.1 &#20013;&#65292;&#40664;&#35748;&#36820;&#22238;&#20540;(&#24403;&#27809;&#26377;&#21305;&#37197;&#30340;&#35760;&#24405;&#30340;&#26102;&#20505;)&#26159;0&#12290;&#22914;:
 
 	Account.sum(:balance, :conditions =&gt; '1 = 2') #=&gt; 0</diff>
      <filename>text/01_ActiveRecord/01_sum.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,8 @@
 ## Has\_one
 
-### Support for the option through   
+### &#25903;&#25345; through &#36873;&#39033;   
 
-The **has\_one** method now has the option **through**. It works just like **has_many :through**, but it represents the association to a single **ActiveRecord** object.
+**has\_one**&#26041;&#27861;&#29616;&#22312;&#25903;&#25345;**through**&#36873;&#39033;&#12290;&#20182;&#30340;&#29992;&#27861;&#19982;**has_many:through**&#30456;&#21516;&#65292;&#19981;&#36807;&#20195;&#34920;&#30340;&#26159;&#21644;&#21333;&#19968;&#19968;&#20010;**ActiveRecord**&#23545;&#35937;&#30340;&#20851;&#32852;.
 
 	class Magazine &lt; ActiveRecord::Base
 	  has_many :subscriptions
@@ -19,19 +19,17 @@ The **has\_one** method now has the option **through**. It works just like **has
 		        :conditions =&gt; ['subscriptions.active = ?', true]
 	end
 	
-### Has\_one with :source\_type             
-                               
-The **has\_one :through** method, just mentioned above, can also take **:source\_type**. I will try to explain this through some examples. Let's start with these two classes:
+### Has\_one :source\_type &#36873;&#39033;
+
+&#19978;&#36793;&#25552;&#21040;&#30340;**has\_one :through**&#26041;&#27861;&#36824;&#33021;&#25509;&#25910;&#19968;&#20010;**:source\_type**&#36873;&#39033;&#65292;&#25105;&#20250;&#35797;&#30528;&#36890;&#36807;&#19968;&#20123;&#20363;&#23376;&#26469;&#35299;&#37322;&#12290;&#25105;&#20204;&#20808;&#26469;&#30475;&#30475;&#36825;&#20010;&#31867;&#65306;
 
 	class Client &lt; ActiveRecord::Base
 	  has_many :contact_cards 
 
 	  has_many :contacts, :through =&gt; :contact_cards
 	end 
-         
-What we are looking at here is a **Client** class which **has_many** kinds of contacts, since the **ContactCard** class has a polymorphic relationship.
 
-Next step in our example, let's create two classes to represent a **ContactCard**:
+&#19978;&#36793;&#30340;&#20195;&#30721;&#26159;&#19968;&#20010;**Client**&#31867;&#65292;**has_many**&#31181;&#32852;&#31995;&#20154;(contacts)&#65292;&#30001;&#20110;**ContactCard**&#31867;&#20855;&#26377;&#22810;&#24577;&#24615;&#65292;&#19979;&#19968;&#27493;&#65292;&#25105;&#20204;&#21019;&#24314;2&#20010;&#31867;&#26469;&#20195;&#34920;**ContractCard**&#65306; 
 
 	class Person &lt; ActiveRecord::Base
 	  has_many :contact_cards, :as =&gt; :contact
@@ -41,15 +39,13 @@ Next step in our example, let's create two classes to represent a **ContactCard*
 	  has_many :contact_cards, :as =&gt; :contact
 	end
           
-**Person** and **Business** relate to my **Client** class through the **ContactCard** table. In other words, I have two kinds of contacts, personal and business. 
-
-This is not going to work, however. Watch what happens when I try to retrieve a contact:
+**Person**&#21644;**Business**&#36890;&#36807;**ContactCard**&#34920;&#19982;**Client**&#31867;&#20851;&#32852;&#65292;&#25442;&#21477;&#35805;&#35828;&#65292;&#25105;&#26377;&#20004;&#31867;&#32852;&#31995;&#20154;&#65292;&#31169;&#20154;&#30340;(personal)&#21644;&#24037;&#20316;&#19978;&#30340;(business)&#12290;&#28982;&#32780;&#65292;&#36825;&#26679;&#20570;&#21364;&#34892;&#19981;&#36890;&#65292;&#30475;&#30475;&#24403;&#25105;&#35797;&#22270;&#33719;&#21462;&#19968;&#20010;contact&#26102;&#20505;&#21457;&#29983;&#20102;&#20160;&#20040;&#65306;
 
 	&gt;&gt; Client.find(:first).contacts
 	# ArgumentError: /&#8230;/active_support/core_ext/hash/keys.rb:48:
 	# in `assert_valid_keys&#8217;: Unknown key(s): polymorphic 
                        
-To make this work we have to use **:source_type**. Let's change our **Client** class:
+&#20026;&#20102;&#35753;&#19978;&#36848;&#20195;&#30721;&#25104;&#21151;&#65292;&#25105;&#20204;&#38656;&#35201;&#20351;&#29992;**:source_type**&#12290;&#25105;&#20204;&#26356;&#25913;&#19968;&#19979;**Client**&#31867;&#65306;
 
 	class Client &lt; ActiveRecord::Base
 	  has_many :people_contacts,
@@ -63,7 +59,7 @@ To make this work we have to use **:source_type**. Let's change our **Client** c
 	           :source_type =&gt; :business
 	end
 	                       
-Notice how we now have two different ways of retrieving our contacts and we can say what contact **:source_type** we are expecting.
+&#27880;&#24847;&#21040;&#29616;&#22312;&#25105;&#20204;&#26377;&#20004;&#31181;&#33719;&#24471;&#32852;&#31995;&#20154;&#30340;&#26041;&#24335;&#65292;&#25105;&#20204;&#21487;&#20197;&#36873;&#25321;&#25105;&#20204;&#26399;&#24453;&#21738;&#31181;**:source_type**&#12290;
 
 	Client.find(:first).people_contacts
 	Client.find(:first).business_contacts</diff>
      <filename>text/01_ActiveRecord/02_has_one.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,8 @@
 ## Named_scope
-              
-The *has\_finder* gem has been added to Rails with a different name: **named\_scope**.
-                       
-To fully understand what this adition brought to Rails let's look at the following examples:
+
+*has\_finder* gem&#24050;&#32463;&#28155;&#21152;&#21040;Rails&#24403;&#20013;&#20102;&#65292;&#26377;&#19968;&#20010;&#26032;&#21517;&#23383;**:named_scope**&#12290;
+
+&#20026;&#20102;&#20840;&#38754;&#20102;&#35299;&#19968;&#19979;&#36825;&#20026;Rails&#24102;&#26469;&#20102;&#20160;&#20040;&#65292;&#25105;&#20204;&#30475;&#30475;&#19979;&#36793;&#30340;&#20363;&#23376;&#65306;
 
 	class Article &lt; ActiveRecord::Base
 	  named_scope :published, :conditions =&gt; {:published =&gt; true}
@@ -14,7 +14,7 @@ To fully understand what this adition brought to Rails let's look at the followi
 	Article.containing_the_letter_a.find(:first)
 	Article.containing_the_letter_a.find(:all, :conditions =&gt; {&#8230;})
  
-Instead of creating a new method named **published** to return all published posts, I'm using a **named\_scope** to do it for me. But it can go even further than this. Let's look at another example of how it can be used:
+&#36890;&#24120;&#25105;&#20250;&#21019;&#24314;&#19968;&#20010;&#26032;&#30340;&#21483;&#20570;**published**&#30340;&#26041;&#27861;&#26469;&#36820;&#22238;&#25152;&#26377;&#30340;&#24050;&#32463;&#21457;&#24067;&#30340;&#24086;&#23376;&#65292;&#19981;&#36807;&#22312;&#36825;&#37324;&#25105;&#26159;&#29992;&#20102;**named\_scope**&#26469;&#20570;&#21516;&#26679;&#30340;&#20107;&#24773;&#65292;&#32780;&#19988;&#36824;&#33021;&#24471;&#21040;&#20854;&#20182;&#30340;&#25928;&#26524;&#12290;&#30475;&#30475;&#21478;&#19968;&#20010;&#20363;&#23376;&#65306;
 
 	named_scope :written_before, lambda { |time|
 	  { :conditions =&gt; ['written_on &lt; ?', time] }
@@ -31,11 +31,9 @@ Instead of creating a new method named **published** to return all published pos
 	named_scope :multiple_extensions, 
 		:extend =&gt; [MultipleExtensionTwo, MultipleExtensionOne]
 
-## Testing named\_scope with proxy\_options 
+## &#29992;proxy\_options&#26469;&#27979;&#35797;named\_scope
                                                                                  
-**Named scopes** is a very interesting new feature for Rails 2.1, but after using it awhile you might have a hard time creating tests for more complex situations.
-
-Let's look at an example:
+**Named scopes**&#26159;Rails 2.1&#20013;&#24456;&#26377;&#36259;&#30340;&#26032;&#21151;&#33021;&#65292;&#19981;&#36807;&#20351;&#29992;&#19968;&#27573;&#26102;&#38388;&#20197;&#21518;&#20320;&#23601;&#20250;&#21457;&#29616;&#24819;&#21019;&#24314;&#19968;&#20123;&#22797;&#26434;&#24773;&#20917;&#30340;&#27979;&#35797;&#20250;&#26377;&#28857;&#40635;&#28902;&#65292;&#30475;&#20010;&#20363;&#23376;&#65306;
 
 		class Shirt &lt; ActiveRecord::Base
 		  named_scope :colored, lambda { |color|
@@ -43,9 +41,9 @@ Let's look at an example:
 		  }
 		end
 
-How to create a test that validates the generation of the scope ?
+&#22914;&#20309;&#21019;&#24314;&#19968;&#20010;&#33021;&#27979;&#35797;scope&#32467;&#26524;&#30340;&#27979;&#35797;&#21602;&#65311;
 
-To solve this issue, the method **proxy\_options** was created. It allows us to examine the options used in **named_scope**. To test the code above we could write:
+&#20026;&#20102;&#35299;&#20915;&#36825;&#20010;&#38382;&#39064;&#65292;**proxy\_options**&#34987;&#21019;&#24314;&#20102;&#20986;&#26469;&#12290;&#23427;&#20801;&#35768;&#25105;&#20204;&#26469;&#26816;&#27979;**named_scope**&#20351;&#29992;&#30340;&#36873;&#39033;&#12290;&#20026;&#20102;&#27979;&#35797;&#19978;&#36848;&#20195;&#30721;&#65292;&#25105;&#20204;&#21487;&#20197;&#36825;&#26679;&#20889;&#27979;&#35797;&#65306;
 
 		class ShirtTest &lt; Test::Unit
 		  def test_colored_scope</diff>
      <filename>text/01_ActiveRecord/03_named_scope.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,8 @@
-## Increment and decrement
+## Increment &#21644; decrement
 
-**ActiveRecord**'s methods **increment**, **increment!**, **decrement** and **decrement!** can now take a new optional parameter. On previous verions of Rails you could use these methods to add or subtract 1 (one) from a given column. In Rails 2.1 you can tell which value that is to be added or subtracted. Like this:
+**ActiveRecord**&#30340;&#26041;&#27861;**increment**,**increment!**,**decrement**&#21644;**descriment!**&#29616;&#22312;&#25903;&#25345;&#19968;&#20010;&#26032;&#30340;&#21487;&#36873;&#21442;&#25968;&#12290;&#20043;&#21069;&#29256;&#26412;&#30340;Rails&#20013;&#20320;&#21487;&#20197;&#36890;&#36807;&#36825;&#20123;&#26041;&#27861;&#25351;&#23450;&#30340;&#23646;&#24615;&#20540;&#21152;1&#25110;&#20943;1&#12290;&#22312;Rails 2.1&#20013;&#65292;&#20320;&#21487;&#20197;&#25351;&#23450;&#35201;&#22686;&#21152;&#25110;&#32773;&#20943;&#23569;&#30340;&#20540;&#65292;&#20687;&#36825;&#26679;&#65306;
 
 	player1.increment!(:points, 5)
 	player2.decrement!(:points, 2)
                                       
-In the above example I am adding 5 points to player1 and subtracting 2 points from player2. Since this is an optional parameter, legacy code is not affected.
\ No newline at end of file
+&#19978;&#36793;&#30340;&#20363;&#23376;&#20013;&#65292;&#25105;&#21521;player1&#21152;&#20102;5&#20998;&#65292;&#20174;player2&#20943;&#20102;2&#20998;&#12290;&#30001;&#20110;&#36825;&#26159;&#19968;&#20010;&#21487;&#36873;&#30340;&#21442;&#25968;&#65292;&#25152;&#20197;&#20043;&#21069;&#30340;&#20195;&#30721;&#19981;&#20250;&#21463;&#21040;&#24433;&#21709;&#12290;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/04_increment_and_decrement.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -2,29 +2,29 @@
 
 ### Conditions
             
-From now on, you can pass an object as a parameter to **ActiveRecord**'s **find** method. See this example:
+&#20174;&#29616;&#22312;&#24320;&#22987;&#65292;&#20320;&#21487;&#20197;&#21521;**ActiveRecord**&#30340;**find**&#26041;&#27861;&#20013;&#20256;&#19968;&#20010;&#23545;&#35937;&#20316;&#20026;&#21442;&#25968;&#12290;&#30475;&#19979;&#36793;&#30340;&#20363;&#23376;&#65306;
 
 	class Account &lt; ActiveRecord::Base
 	  composed_of :balance, :class_name =&gt; &quot;Money&quot;, :mapping =&gt; %w(balance amount)
 	end
-            
-In this case, you can pass an instance of **Money** as a parameter to the **find** method from the **Account** class, like this:
+
+&#36825;&#20010;&#20363;&#23376;&#20013;&#65292;&#20320;&#33021;&#21521;**Account**&#31867;&#30340;**find**&#26041;&#27861;&#20013;&#20256;&#20837;&#19968;&#20010;**Money**&#23454;&#20363;&#20316;&#20026;&#21442;&#25968;&#65292;&#20687;&#36825;&#26679;&#65306;         
 
 	amount = 500
 	currency = &quot;USD&quot;
 	Account.find(:all, :conditions =&gt; { :balance =&gt; Money.new(amount, currency) })
 	
 ### Last
-           
-Up to now we could only use three operators to look for data using **ActiveRecord**'s **find** method. These are: **:first**, **:all** and the object's own id (in this case whe don't pass any argument to **find** besides the id itself)
 
-In Rails 2.1 there is a fourth operator named **:last**. A few examples:
+&#21040;&#29616;&#22312;&#20026;&#27490;&#25105;&#20204;&#21482;&#33021;&#22312;**ActiveRecord**&#30340;**find**&#26041;&#27861;&#20013;&#20351;&#29992;&#19977;&#20010;&#25805;&#20316;&#31526;&#26469;&#26597;&#25214;&#25968;&#25454;&#65292;&#20182;&#20204;&#26159;**:first**,**:all**&#21644;&#23545;&#35937;&#33258;&#24049;&#30340;id(&#36825;&#31181;&#24378;&#20917;&#19979;&#65292;&#25105;&#20204;&#38500;&#20102;id&#20197;&#22806;&#19981;&#20877;&#20256;&#20837;&#20854;&#20182;&#30340;&#21442;&#25968;)&#12290;
+
+&#22312;Rails 2.1&#24403;&#20013;&#65292;&#26377;&#20102;&#31532;&#22235;&#20010;&#25805;&#20316;&#31526;**:last**&#65292;&#20960;&#20010;&#20363;&#23376;&#65306; 
 
 	Person.find(:last)
 	Person.find(:last, :conditions =&gt; [ &quot;user_name = ?&quot;, user_name])
 	Person.find(:last, :order =&gt; &quot;created_on DESC&quot;, :offset =&gt; 5)
 	                                                             
-To fully understand how this new operator works, just look at the following test:
+&#20026;&#20102;&#33021;&#26126;&#30333;&#36825;&#20010;&#26032;&#30340;&#25805;&#20316;&#31526;&#22914;&#20309;&#24037;&#20316;&#65292;&#25105;&#20204;&#30475;&#30475;&#19979;&#36793;&#30340;&#27979;&#35797;&#65306;
 
 	def test_find_last
 	  last  = Developer.find :last
@@ -32,26 +32,26 @@ To fully understand how this new operator works, just look at the following test
 	end
 	
 ### All
-                      
-The static method **all** is an alias to the also static **find(:all)**. Example:
+
+&#31867;&#26041;&#27861;**all**&#26159;&#21478;&#19968;&#20010;&#31867;&#26041;&#27861;**find(:all)**&#30340;&#21035;&#21517;&#12290;&#22914;&#65306;
 	
 	Topic.all is the same as Topic.find(:all)
 
 ### First
               
-The static method **first** is an alias to the also static **find(:first)**. Example:
+&#31867;&#26041;&#27861;**first**&#26159;&#21478;&#19968;&#20010;&#31867;&#26041;&#27861;**find(:first)**&#30340;&#21035;&#21517;&#12290;&#22914;&#65306;
 
 	Topic.first is the same as Topic.find(:first)
 
 ### Last
 
-The static method **last** is an alias to the also static **find(:last)**. Example:
+&#31867;&#26041;&#27861;**last**&#26159;&#21478;&#19968;&#20010;&#31867;&#26041;&#27861;**find(:last)**&#30340;&#21035;&#21517;&#12290;&#22914;&#65306;
 
 	Topic.last is the same as Topic.find(:last)
 
              
-## Using **first** and **last** methods in named\_scope
+## &#22312;**named\_scope**&#20013;&#20351;&#29992;**first**&#21644;**last**&#26041;&#27861;
 
-All the methods mentioned above also work in **named\_scope**. Suppose we create a **named\_scope** named **recent**. The following is legal:
+&#25152;&#26377;&#19978;&#36848;&#30340;&#26041;&#27861;&#21516;&#26679;&#36866;&#29992;&#20110;**named\_scope**&#12290;&#27604;&#22914;&#25105;&#20204;&#21019;&#24314;&#19968;&#20010;&#21483;**recnet**&#30340;**named\_scope**&#65292;&#19979;&#21015;&#20195;&#30721;&#26159;&#26377;&#25928;&#30340;&#65306; 
 
 		post.comments.recent.last</diff>
      <filename>text/01_ActiveRecord/05_find.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,11 +1,10 @@
 ##Eager Loading
 
-To explain this new funcionality, let's look at the following code:
+&#20026;&#20102;&#35299;&#37322;&#36825;&#20010;&#26032;&#30340;&#21151;&#33021;&#65292;&#25105;&#20204;&#30475;&#22914;&#19979;&#20195;&#30721;&#65306;
 
 	Author.find(:all, :include =&gt; [:posts, :comments])
 	
-I'm searching through table **authors** and also including tables **posts** and **comments** in my query through the **author_id** column, which is the default column name according to Rails' convention for foreign_key names. 
-This search used to generate SQL queries like this:
+&#25105;&#22312;&#26597;&#35810;**authors**&#36825;&#20010;&#34920;&#30340;&#35760;&#24405;&#65292;&#21516;&#26102;&#36890;&#36807;**author_id**&#21253;&#21547;&#36827;**posts**&#21644;**comments**&#34920;&#12290;&#36825;&#20010;&#26597;&#35810;&#21407;&#26469;&#20250;&#20135;&#29983;&#36825;&#26679;&#30340;sql&#26597;&#35810;&#35821;&#21477;&#65306;
 
 	SELECT
 	  authors.&quot;id&quot;          AS t0_r0,
@@ -24,12 +23,13 @@ This search used to generate SQL queries like this:
 	  LEFT OUTER JOIN posts ON posts.author_id = authors.id
 	  LEFT OUTER JOIN comments ON comments.author_id = authors.id
 
-Exactly one long SQL query with **joins** between tables **authors**, **posts** and **comments**. We call this **cartesian product**.	
 
-This type of query is not always good performance-wise, so it was changed for Rails 2.1. The same query for **Author** class now uses a different approach to retrieve information from all three tables. Instead of using one SQL query with all three tables, Rails now uses three different queries - one for each table - which are shorter queries than the former that used to be generated. The result can be seen in the log after executing the previous ruby on rails code:
+&#36825;&#20010;sql&#21487;&#30495;&#26159;&#22815;&#38271;&#30340;&#65292;&#22312;**authors**&#65292;**posts**&#21644;**comments**&#19977;&#20010;&#34920;&#20043;&#38388;&#29992;&#20102;joins&#12290;&#25105;&#20204;&#31649;&#36825;&#21483;&#20570;&#31515;&#21345;&#23572;&#20056;&#31215;(**cartesian product**)&#12290; 
+
+&#36825;&#31867;&#26597;&#35810;&#24448;&#24448;&#22312;&#25928;&#29575;&#19978;&#36793;&#19981;&#39640;&#65292;&#25152;&#20197;&#22312;Rails 2.1&#20013;&#26377;&#20102;&#19968;&#20123;&#25913;&#36827;&#12290;&#21516;&#26679;&#30340;&#23545;&#20110;**Author**&#34920;&#30340;&#26597;&#35810;&#65292;&#29616;&#22312;&#20351;&#29992;&#20102;&#19968;&#31181;&#19981;&#21516;&#30340;&#26041;&#24335;&#20174;&#25152;&#26377;&#19977;&#20010;&#34920;&#24403;&#20013;&#21462;&#24471;&#20449;&#24687;&#12290;&#21407;&#26469;&#29992;&#20102;&#19968;&#26465;sql&#35821;&#21477;&#33719;&#24471;&#19977;&#20010;&#34920;&#35760;&#24405;&#65292;&#29616;&#22312;Rails&#29992;&#19977;&#26465;&#19981;&#21516;&#30340;&#26597;&#35810;&#35821;&#21477;&#65292;&#27599;&#20010;&#34920;&#19968;&#26465;&#65292;&#36825;&#35201;&#27604;&#20043;&#21069;&#29983;&#25104;&#30340;&#26597;&#35810;&#35821;&#21477;&#26356;&#30701;&#12290;&#26032;&#30340;&#32467;&#26524;&#21487;&#20197;&#22312;&#25191;&#34892;&#20102;&#19978;&#36848;&#20195;&#30721;&#21518;&#30340;log&#20013;&#30475;&#21040;&#65306;
 
 	SELECT * FROM &quot;authors&quot;
 	SELECT posts.* FROM &quot;posts&quot; WHERE (posts.author_id IN (1))
 	SELECT comments.* FROM &quot;comments&quot; WHERE (comments.author_id IN (1))
 
-In **most cases** three simpler queries will run faster than a complex and long query.
+&#32477;&#22823;&#22810;&#25968;&#24773;&#20917;&#19979;&#65292;&#19977;&#20010;&#31616;&#21333;&#30340;&#26597;&#35810;&#35201;&#27604;&#19968;&#20010;&#22797;&#26434;&#30340;&#22330;&#26597;&#35810;&#35821;&#21477;&#25191;&#34892;&#30340;&#26356;&#24555;&#12290;</diff>
      <filename>text/01_ActiveRecord/06_eager_loading.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,6 @@
 ## Belongs_to
-       
-The **belongs\_to** method was changed in order to allow the use of **:dependent =&gt; :destroy** and **:delete** in associations.
-For example:
+
+&#20026;&#20102;&#33021;&#22312;&#20851;&#32852;&#20013;&#20351;&#29992;**:dependent=&gt;:destroy**&#21644;**:delete**, **belongs\_to**&#26041;&#27861;&#20570;&#20102;&#19968;&#20123;&#26356;&#25913;&#65292;&#27604;&#22914;&#65306;
 
 	belongs_to :author_address
 	belongs_to :author_address, :dependent =&gt; :destroy</diff>
      <filename>text/01_ActiveRecord/07_belongs_to.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,10 +1,10 @@
 ## Polymorphic url
 
-Helper methods for polymorphic URL are used as a more elegant solution to renamed routes when you're working with **ActiveRecord**.
-                                    
-These methods come in handy when you want to generate the URL for a **RESTful** resource without specifying the type it is going to be associated with.
-                                      
-It is very simple to work with them. Take a look at a few examples (commented out is how the same thing is done in versions of Rails prior to 2.1):                             
+&#19968;&#20123;&#22810;&#24577;URL&#30340;&#36741;&#21161;&#26041;&#27861;&#20063;&#34987;&#24341;&#20837;&#21040;&#26032;&#30340;Rails&#24403;&#20013;&#65292;&#29992;&#26469;&#25552;&#20379;&#19968;&#31181;&#26356;&#20026;&#31616;&#27905;&#20248;&#38597;&#30340;&#25805;&#20316;routes&#30340;&#26041;&#24335;&#12290; 
+
+&#36825;&#20123;&#26041;&#27861;&#22312;&#20320;&#24819;&#29983;&#25104;&#22522;&#20110;**RESTful**&#36164;&#28304;&#30340;URL&#65292;&#21516;&#26102;&#21448;&#19981;&#24517;&#26174;&#31034;&#25351;&#23450;&#36164;&#28304;&#30340;&#31867;&#22411;&#30340;&#26102;&#20505;&#65292;&#20250;&#29616;&#24471;&#21313;&#20998;&#26377;&#29992;&#12290;
+
+&#20351;&#29992;&#26041;&#38754;&#65292;&#38750;&#24120;&#30340;&#31616;&#21333;&#65292;&#26469;&#30475;&#30475;&#19968;&#20123;&#20363;&#23376;&#65288;&#27880;&#37322;&#30340;&#37096;&#20998;&#26159;Rails 2.1&#20043;&#21069;&#30340;&#20570;&#27861;&#65289;                         
 
 	record = Article.find(:first) 
 	polymorphic_url(record) #-&gt; article_url(record)
@@ -16,13 +16,13 @@ It is very simple to work with them. Take a look at a few examples (commented ou
 	record = Comment.new
 	polymorphic_url(record)  #-&gt;  comments_url()
 	                  
-Notice how the **polymorphic_url** method is able to identify the type that is given to him and generates the correct routes. **Nested resources** and **namespaces** are also supported:
+&#27880;&#24847;&#21040;**polymorphic_url**&#26041;&#27861;&#26159;&#22914;&#20309;&#30830;&#35748;&#20256;&#20837;&#21442;&#25968;&#30340;&#31867;&#22411;&#24182;&#19988;&#29983;&#25104;&#27491;&#30830;&#30340;routes&#12290;&#20869;&#23884;&#36164;&#28304;&#65288;**Nested resources**&#65289;&#21644;**namespaces**&#20063;&#21516;&#26679;&#25903;&#25345;&#65306;
 
 	polymorphic_url([:admin, @article, @comment])
 	#-&gt; this will return:
 	admin_article_comment_url(@article, @comment)
 	           
-You can also use prefixes such as **new**, **edit** and **formatted**. Take a look at a few examples:
+&#20320;&#21516;&#26679;&#33021;&#22815;&#20351;&#29992;**new**, **edit**, **formatted**&#31561;&#21069;&#32512;&#12290;&#30475;&#30475;&#19979;&#36793;&#30340;&#20363;&#23376;&#65306;
 
 	edit_polymorphic_path(@post)
 	#=&gt; /posts/1/edit</diff>
      <filename>text/01_ActiveRecord/08_polymorphic_url.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-## Readonly relationships
+## &#21482;&#35835;&#20851;&#32852; (Readonly relationships)
 
-A new feature is added to the relationship among models. To avoid change in a models' state you can now use **:readonly** when describing associations. Let's take a look at a few examples:
+&#19968;&#20010;&#26032;&#30340;&#21151;&#33021;&#34987;&#28155;&#21152;&#21040;&#20102;models&#20043;&#38388;&#30340;&#20851;&#32852;&#24403;&#20013;&#12290;&#20026;&#20102;&#36991;&#20813;&#26356;&#25913;&#20851;&#32852;&#27169;&#22411;&#30340;&#29366;&#24577;&#65292;&#20320;&#29616;&#22312;&#21487;&#20197;&#20351;&#29992;**:readonly**&#26469;&#25551;&#36848;&#19968;&#20010;&#20851;&#32852;&#12290;&#25105;&#20204;&#30475;&#20960;&#20010;&#20363;&#23376;&#65306;
 
 	has_many :reports, :readonly =&gt; true
 
@@ -10,4 +10,4 @@ A new feature is added to the relationship among models. To avoid change in a mo
 
 	has_and_belongs_to_many :categories, :readonly =&gt; true
 	      
-This way your associated models are safe from being edited from within this model. If you try editing any of them you will get an **ActiveRecord::ReadOnlyRecord** exception.
\ No newline at end of file
+&#36825;&#26679;&#65292;&#20851;&#32852;&#30340;models&#23601;&#33021;&#22815;&#36991;&#20813;&#22312;model&#20013;&#34987;&#26356;&#25913;&#65292;&#22914;&#26524;&#35797;&#22270;&#26356;&#25913;&#20182;&#20204;&#65292;&#37027;&#20040;&#23558;&#24471;&#21040;&#19968;&#20010;**ActiveRecord::ReadOnlyRecord**&#24322;&#24120;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/09_readonly.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-## Methods add\_timestamps and remove\_timestamps       
+## add\_timestamps&#21644;remove\_timestamps&#26041;&#27861;     
   
-We now have two new methods: **add\_timestamps** and **remove\_timestamps**. They add and remove, respectively, **timestamp** columns. Let's take a look at an example:
+&#29616;&#22312;&#25105;&#20204;&#26377;&#20004;&#20010;&#26032;&#30340;&#26041;&#27861;**add\_timestamps**&#21644;**remove\_timestamps**&#65292;&#20182;&#20204;&#20998;&#21035;&#28155;&#21152;&#65292;&#21024;&#38500;**timestamp**&#21015;&#12290;&#30475;&#20010;&#20363;&#23376;&#65306;
 
 	def self.up
 	  add_timestamps :feeds</diff>
      <filename>text/01_ActiveRecord/10_migration.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
 ## Calculations 
                          
-**ActiveRecord::Calculations** has changed a bit to support table names. This comes in handy when we have relationships among different tables with the same column name. You have these two options now:
+**ActiveRecord::Calculations**&#20570;&#20102;&#19968;&#20123;&#26356;&#25913;&#20197;&#25903;&#25345;&#25968;&#25454;&#24211;&#34920;&#21517;&#12290;&#36825;&#20010;&#21151;&#33021;&#22312;&#20960;&#20010;&#19981;&#21516;&#34920;&#20043;&#38388;&#23384;&#22312;&#20851;&#32852;&#19988;&#30456;&#20851;&#21015;&#21517;&#30456;&#21516;&#26102;&#20250;&#38750;&#24120;&#26377;&#29992;&#12290;&#25105;&#20204;&#26377;&#20004;&#20010;&#36873;&#39033;&#21487;&#36873;&#65306;
 
 	authors.categories.maximum(:id)
 	authors.categories.maximum(&quot;categories.id&quot;)</diff>
      <filename>text/01_ActiveRecord/11_calculations.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,13 +1,13 @@
-## ActiveRecord::Base.create accepts blocks
+## ActiveRecord::Base.create&#25509;&#21463;blocks
 
-We are already used to **ActiveRecord::Base.new** accepting blocks. Now we can do the same thing in the **create** method:
+&#25105;&#20204;&#24050;&#32463;&#20064;&#24815;&#20102;**ActiveRecord::Base.new**&#25509;&#21463;block&#20316;&#20026;&#21442;&#25968;&#20102;&#65292;&#29616;&#22312;**create**&#20063;&#21516;&#26679;&#25509;&#21463;blocks&#20102;&#65306;
 
 	# Creating an object and passing it a block describing its attributes
 	User.create(:first_name =&gt; 'Jamie') do |u|
 	  u.is_admin = false
 	end
 
-We can also use the same method to create many objects at once:
+&#25105;&#20204;&#20063;&#33021;&#29992;&#21516;&#26679;&#30340;&#26041;&#27861;&#19968;&#27425;&#21019;&#24314;&#22810;&#20010;&#23545;&#35937;&#65306;
 
 	# Creating an array of new objects using a block.
 	# The block is executed once for each of object that is created.
@@ -15,11 +15,11 @@ We can also use the same method to create many objects at once:
 	  u.is_admin = false
 	end
 
-And it also works with associations:
+&#21516;&#26679;&#22312;&#20851;&#32852;&#24403;&#20013;&#21487;&#20197;&#20351;&#29992;&#65306;
 
 	author.posts.create!(:title =&gt; &quot;New on Edge&quot;) {|p| p.body = &quot;More cool stuff!&quot;}
 
-	# ou
+	# or
 
 	author.posts.create!(:title =&gt; &quot;New on Edge&quot;) do |p|
 	  p.body = &quot;More cool stuff!&quot;</diff>
      <filename>text/01_ActiveRecord/12_blocos.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,8 @@
 ## change\_table
         
-The creation of **migrations** in Rails 2.0 was a lot sexier than on previous verions, but to alter a table using **migrations** was not sexy at all.
+&#22312;Rails 2.0&#24403;&#20013;&#65292;&#21019;&#24314;&#30340;**migrations**&#35201;&#27604;&#20043;&#21069;&#29256;&#26412;&#26356;&#20026;&#24615;&#24863;&#65292;&#19981;&#36807;&#35201;&#24819;&#29992;**migrations**&#20462;&#25913;&#19968;&#20010;&#34920;&#21487;&#23601;&#19981;&#37027;&#20040;&#24615;&#24863;&#20102;&#12290;
 
-In Rails 2.1, alter table became also sexy with the new method **change\_table**. Let's take a look at an example:
+&#22312;Rails 2.1&#20013;&#65292;&#20462;&#25913;&#34920;&#20063;&#30001;&#20110;&#26032;&#26041;&#27861;**change\_table**&#32780;&#21464;&#24471;&#21516;&#26679;&#24615;&#24863;&#20102;&#12290;&#25105;&#20204;&#26469;&#30475;&#20010;&#20363;&#23376;&#65306;
 
 	change_table :videos do |t|
 	  t.timestamps # this adds columns created_at and updated_at
@@ -11,7 +11,7 @@ In Rails 2.1, alter table became also sexy with the new method **change\_table**
 	  t.remove :name, :email # this removes columns name and email
 	end
               
-The new method **change\_table** works just like his cousin **create\_table** but instead of creating a new table it just alters an already existing table by adding or removing columns and indexes.
+&#26032;&#26041;&#27861;**change\_table**&#30340;&#20351;&#29992;&#23601;&#21644;&#20182;&#30340;&#34920;&#20804;**create\_table**&#19968;&#26679;&#65292;&#21482;&#19981;&#36807;&#19981;&#26159;&#21019;&#24314;&#19968;&#20010;&#26032;&#34920;&#65292;&#32780;&#26159;&#36890;&#36807;&#28155;&#21152;&#25110;&#32773;&#21024;&#38500;&#21015;&#25110;&#32034;&#24341;&#26469;&#26356;&#25913;&#29616;&#26377;&#30340;&#34920;&#12290;
 
 	change_table :table do |t|
 	  t.column # adds an ordinary column. Ex: t.column(:name, :string)</diff>
      <filename>text/01_ActiveRecord/13_change_table.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
 ## Dirty Objects
                   
-Now in Rails we are able to keep track of changes made to **ActiveRecord**. It is possible to know if an object has been changed or not. In case it has been changed, we can track down its latest changes. Let's take look at a few examples:
+&#22312;&#26032;Rails&#24403;&#20013;&#65292;&#25105;&#20204;&#21516;&#26679;&#21487;&#20197;&#36319;&#36394;&#23545;**ActiveRecord**&#25152;&#20570;&#30340;&#26356;&#25913;&#12290;&#25105;&#20204;&#33021;&#22815;&#30693;&#36947;&#26159;&#21542;&#19968;&#20010;&#23545;&#35937;&#34987;&#36827;&#34892;&#20102;&#20462;&#25913;&#65292;&#22914;&#26524;&#26377;&#26356;&#25913;&#65292;&#37027;&#20040;&#25105;&#20204;&#23601;&#33021;&#36319;&#36394;&#21040;&#26368;&#26032;&#30340;&#26356;&#25913;&#12290;&#25105;&#20204;&#26469;&#30475;&#20960;&#20010;&#20363;&#23376;&#65306;
 
   article = Article.find(:first)
 	article.changed?  #=&gt; false
@@ -15,7 +15,7 @@ Now in Rails we are able to keep track of changes made to **ActiveRecord**. It i
 	# before and after the change
 	article.title_change  #=&gt; [&quot;Title&quot;, &quot;New Title&quot;]
 
-As you can see it is very simple. You can also list all changes made to the object in one of two ways:
+&#21487;&#20197;&#30475;&#21040;&#65292;&#20351;&#29992;&#19978;&#36793;&#38750;&#24120;&#30340;&#31616;&#21333;&#65292;&#21516;&#26102;&#20320;&#20063;&#33021;&#22815;&#36890;&#36807;&#19979;&#21015;&#20004;&#31181;&#26041;&#27861;&#30340;&#20219;&#24847;&#19968;&#31181;&#21015;&#20986;&#23545;&#19968;&#20010;&#23545;&#35937;&#30340;&#25152;&#26377;&#26356;&#25913;&#65306;
 
 	# returns a list with all of the attributes that were changed
 	article.changed  #=&gt; ['title']
@@ -24,13 +24,13 @@ As you can see it is very simple. You can also list all changes made to the obje
 	# along with its values before and after
 	article.changes  #=&gt; { 'title&#8217; =&gt; [&quot;Title&quot;, &quot;New Title&quot;] }
              
-Notice that when an object is saved, its status changes:
+&#27880;&#24847;&#21040;&#24403;&#19968;&#20010;&#23545;&#35937;&#34987;&#20445;&#23384;&#21518;&#65292;&#20182;&#30340;&#29366;&#24577;&#20063;&#38543;&#20043;&#25913;&#21464;&#65306;
 
 	article.changed?  #=&gt; true
 	article.save  #=&gt; true
 	article.changed?  #=&gt; false
    
-In case you want to change an object's state without using **attr=**, you will need to explicitly inform that the attribute was changed by using the method **attr\_name\_will\_change!** (replace **attr** with an object's real attribute). Let's look at one last example:
+&#22914;&#26524;&#20320;&#19981;&#36890;&#36807;**attr=**&#26469;&#26356;&#25913;&#19968;&#20010;&#23545;&#35937;&#30340;&#29366;&#24577;&#65292;&#37027;&#20040;&#20320;&#38656;&#35201;&#26174;&#31034;&#30340;&#35843;&#29992;**attr\_name\_will\_change!**&#26041;&#27861;(&#29992;&#23545;&#35937;&#30340;&#23454;&#38469;&#23646;&#24615;&#21517;&#31216;&#26367;&#25442;**attr**)&#26469;&#36890;&#30693;&#23646;&#24615;&#24050;&#32463;&#34987;&#26356;&#25913;&#12290;&#25105;&#20204;&#20877;&#30475;&#26368;&#21518;&#19968;&#20010;&#20363;&#23376;&#65306;
     
 	article = Article.find(:first)
 	article.title_will_change!</diff>
      <filename>text/01_ActiveRecord/14_dirty_objects.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,12 +1,12 @@
 ## Partial Updates
 
-The implementation of **Dirty Objects** was the starting point for another very interesting feature.
-                                                                                                         
-Since we can now track down what has changed in an object's state, why not use it to avoid unnecessary updates to the database ?
-  
-On previous versions of Rails when we called **save** from an already existing **ActiveRecord** object, all of its fields would be updated in the database. Even the ones that had not suffered any change.
+**Dirty Objects**&#30340;&#23454;&#29616;&#35753;&#21478;&#19968;&#20010;&#38750;&#24120;&#26377;&#36259;&#30340;&#21151;&#33021;&#21464;&#20026;&#21487;&#33021;&#12290; 
 
-This action could be greatly enhanced with the use of **Dirty Objects** and it is exactly what happened. Take a look at the SQL query generated in Rails 2.1 when trying to save an object that suffered a slight change: 
+&#30001;&#20110;&#25105;&#20204;&#29616;&#22312;&#21487;&#20197;&#36319;&#36394;&#19968;&#20010;&#23545;&#35937;&#30340;&#29366;&#24577;&#26159;&#21542;&#21457;&#29983;&#25913;&#21464;&#65292;&#37027;&#20040;&#20026;&#20160;&#20040;&#19981;&#29992;&#23427;&#26469;&#36991;&#20813;&#37027;&#20123;&#19981;&#24517;&#35201;&#30340;&#23545;&#25968;&#25454;&#35044;&#30340;&#26356;&#26032;&#21602;&#65311; 
+
+&#22312;&#20043;&#21069;&#29256;&#26412;&#30340;Rails&#24403;&#20013;&#65292;&#24403;&#25105;&#20204;&#23545;&#19968;&#20010;&#24050;&#32463;&#23384;&#22312;&#30340;**ActiveRecord**&#23545;&#35937;&#35843;&#29992;**save**&#26041;&#27861;&#30340;&#26102;&#20505;&#65292;&#25152;&#26377;&#25968;&#25454;&#24211;&#20013;&#30340;&#23383;&#27573;&#37117;&#20250;&#34987;&#26356;&#26032;&#65292;&#21363;&#20351;&#37027;&#20123;&#27809;&#26377;&#20570;&#20219;&#20309;&#26356;&#25913;&#30340;&#23383;&#27573;&#12290; 
+
+&#36825;&#31181;&#26041;&#24335;&#22312;&#20351;&#29992;&#20102;Dirty Objects&#20197;&#21518;&#24212;&#35813;&#20250;&#26377;&#24456;&#22823;&#30340;&#25913;&#36827;&#65292;&#32780;&#23454;&#38469;&#24773;&#20917;&#20063;&#30340;&#30830;&#22914;&#27492;&#12290;&#30475;&#30475;&#22312;&#20445;&#23384;&#19968;&#20010;&#26377;&#19968;&#28857;&#26356;&#25913;&#30340;&#23545;&#35937;&#26102;&#65292;Rails 2.1&#29983;&#25104;&#30340;SQL&#26597;&#35810;&#35821;&#21477;&#65306;
 
 	article = Article.find(:first)
 	article.title  #=&gt; &quot;Title&quot;
@@ -19,19 +19,19 @@ This action could be greatly enhanced with the use of **Dirty Objects** and it i
 	article.save
 	#=&gt;  &quot;UPDATE articles SET title = 'New Title' WHERE id = 1&quot;
 	
-Notice how only the fields that were changed in the application were updated in the database. If no field had been updated in the application, then **ActiveRecord** would not execute any update.
-                                
-To enable/disable this new feature you change the **partial\_updates** property related to your model.
+&#27880;&#24847;&#21040;&#65292;&#21482;&#26377;&#37027;&#20123;&#22312;&#24212;&#29992;&#20013;&#34987;&#26356;&#25913;&#30340;&#23646;&#24615;&#25165;&#22312;&#34987;&#26356;&#26032;&#12290;&#22914;&#26524;&#27809;&#26377;&#23646;&#24615;&#34987;&#26356;&#25913;&#65292;&#37027;&#20040;**ActiveRecord**&#23601;&#19981;&#25191;&#34892;&#20219;&#20309;&#26356;&#26032;&#35821;&#21477;&#12290; 
+
+&#20026;&#20102;&#24320;&#21551;/&#20851;&#38381;&#36825;&#20010;&#26032;&#21151;&#33021;&#65292;&#20320;&#35201;&#26356;&#25913;model&#30340;**partial\_updates**&#23646;&#24615;&#12290;
 
 	# To enable it
 	MyClass.partial_updates = true
          
-If you wish to enable/disable this feature to all of your models, then you must edit the file *config/initializers/new\_rails\_defaults.rb*:
+&#22914;&#26524;&#24076;&#26395;&#23545;&#25152;&#26377;&#30340;models&#24320;&#21551;/&#20851;&#38381;&#36825;&#20010;&#21151;&#33021;&#65292;&#37027;&#20040;&#20320;&#24517;&#39035;&#32534;&#36753;*config/initializers/new\_rails\_defaults.rb*&#65306;
 
 	# Enable it to all models
 	ActiveRecord::Base.partial_updates = true
       
-Don't forget to also inform Rails through *config/initializers/new\_rails\_defaults.rb* if you plan to edit a field without using the method **attr=**, like this:
+&#21035;&#24536;&#20102;&#22914;&#26524;&#20320;&#19981;&#36890;&#36807;attr=&#26356;&#25913;&#23383;&#27573;&#65292;&#21516;&#26679;&#35201;&#36890;&#36807;*config/initializers/new\_rails\_defaults.rb*&#26469;&#36890;&#30693;Rails&#65292;&#20687;&#36825;&#26679;:
 
 	# If you use **attr=**, 
 	# then it's ok not informing
@@ -45,4 +45,4 @@ Don't forget to also inform Rails through *config/initializers/new\_rails\_defau
 	person.name &lt;&lt; 'by'
 	person.name_change    # =&gt; ['bob', 'bobby']
          
-If you don't inform changes like these will be occurring, then they won't be able to be tracked down and your database table won't be correctly updated.
+&#22914;&#26524;&#20320;&#19981;&#36890;&#30693;Rails&#65292;&#37027;&#20040;&#19978;&#36848;&#30340;&#20195;&#30721;&#21516;&#26679;&#20250;&#26356;&#25913;&#23545;&#35937;&#30340;&#23646;&#24615;&#65292;&#20294;&#26159;&#21364;&#19981;&#33021;&#34987;&#36319;&#36394;&#21040;&#65292;&#20174;&#32780;&#20063;&#23601;&#26080;&#27861;&#27491;&#30830;&#30340;&#26356;&#26032;&#25968;&#25454;&#24211;&#20013;&#30340;&#30456;&#24212;&#23383;&#27573;&#12290;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/15_partial_updates.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-## Smallint, int or bigint in MySQL?
+## MySQL&#20013;&#20351;&#29992;Smallint, int&#36824;&#26159;bigint&#65311;
                        
-The **MySQL** adapter for **ActiveRecord** is now smarter when creating or altering columns in the database using integer types. According to the option **:limit**, it will now tell if the column will be a **smallint**, **int** or **bigint**. Let's take a look at an example that does just that:
+&#29616;&#22312;&#22312;&#21019;&#24314;&#25110;&#32773;&#26356;&#25913;&#25972;&#22411;&#21015;&#30340;&#26102;&#20505;**ActiveRecord**&#30340;**MySQL**&#36866;&#37197;&#22120;&#20250;&#22788;&#29702;&#30340;&#26356;&#20026;&#32874;&#26126;&#65292;&#23427;&#21487;&#20197;&#26681;&#25454;**:limit**&#23646;&#24615;&#30830;&#23450;&#19968;&#20010;&#23383;&#27573;&#30340;&#31867;&#22411;&#24212;&#35813;&#26159;**smallint**&#65292;**int**&#36824;&#26159;**bigint**&#12290;&#25105;&#20204;&#26469;&#30475;&#20010;&#23454;&#29616;&#19978;&#36848;&#21151;&#33021;&#30340;&#20363;&#23376;&#65306;
 
 	case limit
 	when 0..3
@@ -13,7 +13,7 @@ The **MySQL** adapter for **ActiveRecord** is now smarter when creating or alter
 	  'int(11)'
 	end
 
-Now let's map it in a **migration** file and see what column type will be created for each column:
+&#29616;&#22312;&#25105;&#20204;&#22312;**migration**&#20013;&#20351;&#29992;&#23427;&#65292;&#30475;&#30475;&#27599;&#19968;&#20010;&#23383;&#27573;&#24212;&#35813;&#21305;&#37197;&#20160;&#20040;&#31867;&#22411;&#65306;
 
 	create_table :table_name, :force =&gt; true do |t|
 
@@ -30,4 +30,4 @@ Now let's map it in a **migration** file and see what column type will be create
 	  t.integer :column_four # int(11)
 	end
       
-The **PostgreSQL** adapter had this feature already and **MySQL** just caught up.
+**PostgreSQL**&#36866;&#37197;&#22120;&#24050;&#32463;&#26377;&#36825;&#20010;&#21151;&#33021;&#20102;&#65292;&#29616;&#22312;**MySQL**&#20063;&#19981;&#29976;&#33853;&#21518;&#20102;&#12290;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/16_mysql.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,9 +1,9 @@
-## Option :select in has\_one and belongs\_to
+## has\_one&#21644;belongs\_to&#20013;&#30340;:select&#36873;&#39033;
 
-The already known methods **has\_one** and **belongs\_to** just got a now option: **:select**.
+&#24050;&#32463;&#20026;&#20154;&#29087;&#30693;&#30340;**has\_one**&#21644;**belongs\_to**&#26041;&#27861;&#29616;&#22312;&#25509;&#25910;&#19968;&#20010;&#26032;&#23646;&#24615;**:select**&#12290; 
 
-Its default value is &quot;*&quot; (as in &quot;SELECT * FROM table&quot;), but you can edit it to retrieve only the columns you are going to be using.
-     
-Don't forget to include the **primary** and **foreign keys**, otherwise you will get an error.
+&#23427;&#30340;&#40664;&#35748;&#20540;&#26159;&#8220;*&#8221;(&#27491;&#22914;&quot;SELECT * FROM table&quot;)&#65292;&#19981;&#36807;&#20320;&#21487;&#20197;&#26356;&#25913;&#40664;&#35748;&#20540;&#26469;&#33719;&#24471;&#20219;&#20309;&#20320;&#24076;&#26395;&#30340;&#21015;&#12290;
 
-The **belongs_to** method does not have the option **:order** anymore. But don't worry, because it didn't really have a use.
+&#21035;&#24536;&#20102;&#21253;&#25324;&#36827;&#20027;&#38190;&#21644;&#22806;&#38190;&#65292;&#21542;&#21017;&#20320;&#20250;&#24471;&#21040;&#19968;&#20010;&#38169;&#35823;&#12290;
+
+**belongs_to**&#26041;&#27861;&#19981;&#20877;&#25903;&#25345;**:order**&#36873;&#39033;&#20102;&#65292;&#19981;&#36807;&#19981;&#35201;&#25285;&#24515;&#65292;&#22240;&#20026;&#37027;&#22522;&#26412;&#19978;&#27809;&#20160;&#20040;&#29992;&#22788;&#12290;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/17_select_has_many.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-## Storing the complete name of a class when using STI
+## &#20351;&#29992;&#21333;&#34920;&#32487;&#25215;(STI)&#30340;&#26102;&#20505;&#23384;&#20648;&#31867;&#30340;&#20840;&#21517;
 
-Whenever we use **models** with **namespace** and **STI**, **ActiveRecord** stores just the name of the class, without its **namespace** (*demodulized*). This will only work when all of the classes in the **STI** are in the same **namespace**. Let's look at an example:
+&#24403;&#25105;&#20204;&#30340;**models**&#26377;**namespace**&#65292;&#24182;&#19988;&#26159;&#21333;&#34920;&#32487;&#25215;(STI)&#30340;&#26102;&#20505;&#65292;**ActiveRecord**&#20165;&#20165;&#23558;&#31867;&#21517;&#65292;&#32780;&#19981;&#26159;&#21253;&#25324;n**amespace**(**demodulized**)&#22312;&#20869;&#30340;&#20840;&#21517;&#23384;&#36215;&#26469;&#12290;&#36825;&#31181;&#24773;&#20917;&#20165;&#20165;&#24403;&#21333;&#34920;&#32487;&#25215;&#30340;&#25152;&#26377;&#31867;&#22312;&#19968;&#20010;**namespace**&#30340;&#26102;&#20505;&#26377;&#25928;&#65292;&#30475;&#20010;&#20363;&#23376;&#65306;
 
 	class CollectionItem &lt; ActiveRecord::Base; end
 	class ComicCollection::Item &lt; CollectionItem; end
@@ -12,10 +12,9 @@ Whenever we use **models** with **namespace** and **STI**, **ActiveRecord** stor
 	# returns an error, because it can't find
 	# the class Item
       
-This change adds a new option that makes **ActiveRecord** store the whole name of the class 
-
-To enable/disable this feature, you should include or edit the following in your **environment.rb**.
+&#26032;&#30340;Rails&#28155;&#21152;&#20102;&#19968;&#20010;&#23646;&#24615;&#65292;&#20174;&#32780;&#20351;**ActiveRecord**&#33021;&#23384;&#20648;&#31867;&#30340;&#20840;&#21517;&#12290; 
+&#21487;&#20197;&#22312;**environment.rb**&#24403;&#20013;&#28155;&#21152;&#22914;&#19979;&#20195;&#30721;&#26469;&#21551;&#21160;/&#20851;&#38381;&#36825;&#20010;&#21151;&#33021;&#65306;
 
 	ActiveRecord::Base.store_full_sti_class = true
                              
-Its default value is true.
\ No newline at end of file
+&#40664;&#35748;&#20540;&#26159;true&#12290;
\ No newline at end of file</diff>
      <filename>text/01_ActiveRecord/18_sti.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-## Method table_exists?
+##table_exists?&#26041;&#27861;
            
-New method for the **AbstractAdapter** class: **table\_exists**. It is very simple to use:
+**AbstractAdapter**&#31867;&#26377;&#20010;&#26032;&#26041;&#27861;**table\_exists**&#65292;&#29992;&#27861;&#38750;&#24120;&#31616;&#21333;&#65306;
 
 	&gt;&gt; ActiveRecord::Base.connection.table_exists?(&quot;users&quot;)
 	=&gt; true</diff>
      <filename>text/01_ActiveRecord/19_tables_exists.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,20 +1,20 @@
-## Timestamped Migrations
+## &#22522;&#20110;&#26102;&#38388;&#25139;&#30340;Migrations (Timestamped Migrations)
               
-When you are just starting Rails or developing something on your own, **migrations** seem to be the best solution to all of your problems. However, when with a team of developers on a project, you will find out (if you haven't already) that it becomes a bit more troublesome to handle race conditions on migrations. The new timestamped migrations in Rails 2.1 to the rescue.
+&#24403;&#20320;&#19968;&#20010;&#20154;&#20351;&#29992;Rails&#24320;&#21457;&#30340;&#26102;&#20505;&#65292;**migrations**&#20284;&#20046;&#26159;&#25152;&#26377;&#38382;&#39064;&#30340;&#26368;&#22909;&#35299;&#20915;&#26041;&#26696;&#12290;&#19981;&#36807;&#65292;&#24403;&#21644;&#22242;&#38431;&#30340;&#20854;&#20182;&#25104;&#21592;&#20849;&#21516;&#24320;&#21457;&#19968;&#20010;&#39033;&#30446;&#30340;&#26102;&#20505;&#65292;&#20320;&#23601;&#20250;&#21457;&#29616;(&#22914;&#26524;&#20320;&#23578;&#26410;&#21457;&#29616;)&#22788;&#29702;**migrations**&#21516;&#27493;&#30340;&#38382;&#39064;&#38750;&#24120;&#26840;&#25163;&#12290;Rails 2.1&#20013;&#22522;&#20110;&#26102;&#38388;&#25139;&#30340;**migrations**&#35299;&#20915;&#26041;&#26696;&#24456;&#22909;&#30340;&#35299;&#20915;&#20102;&#36825;&#20010;&#38382;&#39064;&#12290; 
 
-Before the introduction of **timestamped migrations**, each new migration created had a number which prefaced the migration name. If two migrations were generated by different developers and not committed instantly, they could end up having the same number preface by different migration info. At this point your schema_info is out of date and you have a conflict in your source control.
-        
-There were many ways to &quot;try&quot; to solve this problem. Many plugins were created with different approaches to solve this issue. Despite the plugins available, one thing was clear: the old way simply didn't work.     
+&#22312;&#22522;&#20110;&#26102;&#38388;&#25139;&#30340;**migrations**&#24341;&#20837;&#20043;&#21069;&#65292;&#21019;&#24314;&#27599;&#19968;&#20010;migration&#37117;&#20250;&#22312;&#20854;&#21517;&#23383;&#20043;&#21069;&#29983;&#25104;&#19968;&#20010;&#25968;&#23383;&#65292;&#22914;&#26524;&#20004;&#20010;**migrations**&#20998;&#21035;&#30001;&#20004;&#20010;&#24320;&#21457;&#32773;&#29983;&#25104;&#65292;&#24182;&#19988;&#37117;&#27809;&#26377;&#21363;&#26102;&#30340;&#25552;&#20132;&#21040;&#29256;&#26412;&#24211;&#20013;&#65292;&#37027;&#20040;&#26368;&#21518;&#23601;&#26377;&#21487;&#33021;&#23384;&#22312;&#30456;&#21516;&#21069;&#32512;&#25968;&#23383;&#65292;&#20294;&#26159;&#19981;&#21516;&#20869;&#23481;&#30340;**migrations**&#65292;&#36825;&#26102;&#20320;&#30340;schema_info&#34920;&#23601;&#20250;&#36807;&#26399;&#65292;&#21516;&#26102;&#22312;&#29256;&#26412;&#25511;&#21046;&#31995;&#32479;&#20013;&#20986;&#29616;&#20914;&#31361;&#12290;
 
-If you were using Git, then you would be digging an even deeper hole, since your team would probably have a couple of working branches and out-of-date **migrations** in all of them. You would have serious conflict problems when merging branches.
-                 
-To solve this huge problem, the core team changed how **migrations** works in Rails.  Instead of prefacing each migration file with a number from corresponding to the current schema_info's version count, it is now prefaced with a string based on the **UTC** time and following the format YYYYMMDDHHMMSS.
+&#35797;&#22270;&#35299;&#20915;&#36825;&#20010;&#38382;&#39064;&#30340;&#23581;&#35797;&#26377;&#24456;&#22810;&#65292;&#20154;&#20204;&#21019;&#24314;&#20102;&#24456;&#22810;plugins&#20197;&#19981;&#21516;&#30340;&#26041;&#24335;&#35299;&#20915;&#36825;&#20010;&#38382;&#39064;&#12290;&#23613;&#31649;&#26377;&#19968;&#20123;plugins&#21487;&#29992;&#65292;&#19981;&#36807;&#19968;&#28857;&#26159;&#38750;&#24120;&#28165;&#26970;&#30340;&#65292;&#26087;&#30340;&#26041;&#24335;&#19981;&#33021;&#28385;&#36275;&#25105;&#20204;&#30340;&#35201;&#27714;&#20102;&#12290;
 
-Also a new table called **schema_migrations** was created and it stores which **migrations** that have already been executed. That way, if anyone creates a **migration** with a smaller number, rails will **rollback** migrations until the previous version and then run everything up to the current version.
+&#22914;&#26524;&#20320;&#20351;&#29992;Git&#65292;&#37027;&#20040;&#20320;&#21487;&#33021;&#22312;&#32473;&#33258;&#24049;&#25366;&#19968;&#20010;&#26356;&#22823;&#30340;&#38519;&#38449;&#65292;&#22240;&#20026;&#20320;&#30340;&#22242;&#38431;&#21487;&#33021;&#21516;&#26102;&#26377;&#20960;&#20010;working branches&#65292;&#36807;&#26399;&#20102;&#30340;migrations&#21017;&#22312;&#27599;&#19968;&#20010;branch&#20013;&#37117;&#23384;&#22312;&#12290;&#36825;&#26679;&#24403;&#21512;&#24182;&#36825;&#20123;branches&#30340;&#26102;&#20505;&#23601;&#20250;&#26377;&#20005;&#37325;&#30340;&#20914;&#31361;&#38382;&#39064;&#12290;
 
-Apparently, it solves the conflict problem with **migrations**.
+&#20026;&#20102;&#35299;&#20915;&#36825;&#20010;&#22823;&#38382;&#39064;&#65292;Rails&#26680;&#24515;&#22242;&#38431;&#24050;&#32463;&#25913;&#21464;&#20102;**migrations**&#30340;&#24037;&#20316;&#26041;&#24335;&#12290;&#20182;&#20204;&#24223;&#24323;&#20102;&#21407;&#26377;&#30340;&#20197;&#24403;&#21069;schema_info&#20013;version&#21015;&#30340;&#20540;&#20316;&#20026;migration&#21069;&#32512;&#30340;&#20381;&#25454;&#30340;&#26041;&#27861;&#65292;&#21462;&#32780;&#20195;&#20043;&#30340;&#26159;&#22522;&#20110;**UTC**&#26102;&#38388;&#65292;&#25353;&#29031;YYYYMMDDHHMMSS&#26684;&#24335;&#30340;&#23383;&#31526;&#20018;&#34920;&#36798;&#26041;&#24335;&#20316;&#20026;&#21069;&#32512;&#12290; 
 
-There are also two new rake tasks to &quot;walk through&quot; **migrations**:
+&#21516;&#26102;&#21019;&#24314;&#20102;&#19968;&#20010;&#26032;&#30340;&#21483;**schema_migrations**&#30340;&#34920;&#65292;&#34920;&#20013;&#23384;&#30528;&#21738;&#20123;**migrations**&#24050;&#32463;&#34987;&#25191;&#34892;&#20102;&#65292;&#36825;&#26679;&#22914;&#26524;&#21457;&#29616;&#26377;&#20154;&#21019;&#24314;&#20102;&#19968;&#20010;&#26377;&#36739;&#23567;&#20540;&#30340;**migration**&#65292;rails&#20250;&#22238;&#28378;**migrations**&#21040;&#20043;&#21069;&#30340;&#37027;&#20010;&#29256;&#26412;&#65292;&#28982;&#21518;&#37325;&#26032;&#25191;&#34892;&#25152;&#26377;&#30340;**migration**&#30452;&#21040;&#24403;&#21069;&#30340;&#29256;&#26412;&#12290; 
+
+&#26174;&#28982;&#65292;&#36825;&#26679;&#20570;&#35299;&#20915;&#20102;migrations&#24102;&#26469;&#30340;&#20914;&#31361;&#38382;&#39064;&#12290; 
+
+&#26377;&#20004;&#20010;&#26032;&#30340;&#21644;**migrations**&#30456;&#20851;&#30340;rake&#21629;&#20196;&#65306;
 
 	rake db:migrate:up
 	rake db:migrate:down</diff>
      <filename>text/01_ActiveRecord/20_utc_migrations.markdown</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>2c0b20c50e9e90d2cb9e8603189791229109a4c8</id>
    </parent>
  </parents>
  <author>
    <name>Libin Pan</name>
    <email>libin.pan@gmail.com</email>
  </author>
  <url>http://github.com/libin/rails21-book-cn/commit/80c4507313cea9d6db44ad438877da6d61ab0c20</url>
  <id>80c4507313cea9d6db44ad438877da6d61ab0c20</id>
  <committed-date>2008-06-21T14:24:25-07:00</committed-date>
  <authored-date>2008-06-21T14:24:25-07:00</authored-date>
  <message>2 done, 12 to go</message>
  <tree>b7e764e562e9c3e5ca954b3521f46ac064ab83ec</tree>
  <committer>
    <name>Libin Pan</name>
    <email>libin.pan@gmail.com</email>
  </committer>
</commit>
