                 :columns ["NAME" "ID"],
                 :cols [{:extra_info {} :special_type nil, :base_type :TextField, :description nil, :name "NAME", :table_id (table->id :venues), :id (field->id :venues :name)}
                        {:extra_info {} :special_type :id, :base_type :BigIntegerField, :description nil, :name "ID", :table_id (table->id :venues), :id (field->id :venues :id)}]}}
-        (process-and-run {:type :query
-                          :database @db-id
-                          :query {:source_table (table->id :venues)
-                                  :filter [nil nil]
-                                  :aggregation ["rows"]
-                                  :fields [(field->id :venues :name)
-                                           (field->id :venues :id)]
-                                  :breakout [nil]
-                                  :limit 10
-                                  :order_by [[(field->id :venues :id) "ascending"]]}}))
+  (driver/process-query {:type :query
+                         :database @db-id
+                         :query {:source_table (table->id :venues)
+                                 :filter [nil nil]
+                                 :aggregation ["rows"]
+                                 :fields [(field->id :venues :name)
+                                          (field->id :venues :id)]
+                                 :breakout [nil]
+                                 :limit 10
+                                 :order_by [[(field->id :venues :id) "ascending"]]}}))
 
 ;; ## "ORDER_BY" CLAUSE
 ;; Test that we can tell the Query Processor to return results ordered by multiple fields

                :cols [{:extra_info {:target_table_id (table->id :users)} :special_type :fk, :base_type :IntegerField, :description nil, :name "USER_ID", :table_id (table->id :checkins), :id (field->id :checkins :user_id)}
                       {:extra_info {:target_table_id (table->id :venues)} :special_type :fk, :base_type :IntegerField, :description nil, :name "VENUE_ID", :table_id (table->id :checkins), :id (field->id :checkins :venue_id)}
                       {:base_type :IntegerField, :special_type :number, :name "count", :id nil, :table_id nil, :description nil}]}}
        (process-and-run {:type :query
                          :database @db-id
                          :query {:source_table (table->id :checkins)
                                  :limit 10
                                  :aggregation ["count"]
                                  :breakout [(field->id :checkins :user_id)
                                             (field->id :checkins :venue_id)]}}))

;; ### "BREAKOUT" - MULTIPLE COLUMNS W/ EXPLICIT "ORDER_BY"
;; `breakout` should not implicitly order by any fields specified in `order_by`

                :columns ["CAST(LAST_LOGIN AS DATE)" "ID"]
                :cols [{:extra_info {} :special_type :category :base_type :DateTimeField, :description nil, :name "LAST_LOGIN", :table_id (table->id :users), :id (field->id :users :last_login)}
                       {:extra_info {} :special_type :id, :base_type :BigIntegerField, :description nil, :name "ID", :table_id (table->id :users), :id (field->id :users :id)}]}}
  (-> (driver/process-query {:type :query
                             :database @db-id
                             :query {:limit nil
                                     :source_table (table->id :users)
                                     :filter [nil nil]
                                     :breakout [(field->id :users :last_login)]
                                     :aggregation ["cum_sum" (field->id :users :id)]}})
      ;; Rows come back like `[value timestamp]` but it is hard to compare timestamps directly since the values that come back are casted
      ;; to Dates and the exact value depends on the locale of the machine running the tests. So just drop the timestamps from the results.
      (update-in [:data :rows] (partial map last))))
