 
 (defn- pre-expand [qp]
   (fn [query]
-    (qp (resolve/resolve (expand/expand query)))))
+    (if (structured-query? query)
+      (qp (resolve/resolve (expand/expand query)))
+      (qp query))))
 
 
 (defn- post-add-row-count-and-status

      (reset! called? true)
      (qp query))))

(defn- process-structured [{:keys [driver], :as query}]
  (let [driver-process-query      (:process-query driver)
        driver-wrap-process-query (or (:process-query-in-context driver)
                                      (fn [qp] qp))]

;; |                                     QP INTERNAL IMPLEMENTATION                                     |
;; +----------------------------------------------------------------------------------------------------+

(defn structured-query?
  "Predicate function which returns `true` if the given query represents a structured style query, `false` otherwise."
  [query]
  (= :query (keyword (:type query))))


(defn- wrap-catch-exceptions [qp]
  (fn [query]
    (try (qp query)
