title: Ordering|Sorting records with condition in RoR
body: <p>I want to order my records with a condition. Lets say i have a <code>Model</code>. And fields are <code>[x,y,z]</code>. </p>
  
  <p>These are all string typed colums. I want to sort records by condition </p>
  
  <pre><code>z = "YGS-1" and y DESC
  </code></pre>
  
  <p>for example. So z has a condition if value is "YGS-1" and y with DESC condition.
  How can i sort|order my records. with these conditions. </p>
  
  <p>Any idea?</p>
  
  <p>Thanks.</p>