title: combining slick queries into single query
body: <p>Using Slick 3.1, how do I combine multiple Queries into a single query for the same type?  This is <strong><em>not a join or a union</em></strong>, but combining query "segments" to create a single query request.  These "segments" can be any individually valid query.</p>
  
  <pre><code>val query = TableQuery[SomeThingValid]
  
  // build up pieces of the query in various parts of the application logic
  val q1 = query.filter(_.value &gt; 10)
  val q2 = query.filter(_.value &lt; 40)
  val q3 = query.sortBy(_.date.desc)
  val q4 = query.take(5)
  
  // how to combine these into a single query ?
  val finalQ = ??? q1 q2 q3 q4 ???
  
  // in order to run in a single request
  val result = DB.connection.run(finalQ.result)
  </code></pre>
  
  <p>EDIT:
  the expected sql should be something like:</p>
  
  <pre><code>SELECT * FROM "SomeThingValid" WHERE "SomeThingValid"."value" &gt; 10 AND "SomeThingValid"."valid" &lt; 40 ORDER BY "MemberFeedItem"."date" DESC LIMIT 5
  </code></pre>