title: Converting Sql Query to Rails Syntax
body: <p>I am having trouble in converting this query to Rails syntax. would any one please guide me </p>
  
  <pre><code>SELECT
     "users".*
  FROM
     "affiliates"
  INNER JOIN
     "users"
  ON
     "users"."id" = "affiliates"."user_id"
  WHERE (
     users.email ILIKE'%web%' or
     users.name ILIKE'%web%' or
     users.contact_number ILIKE'%web%'
  )
  LIMIT
     10;
  </code></pre>