                                         :column cinfo
                                         :value (su/munge-jsonb-for-storage value)})
 
-                :queryable-json
+                (= :queryable-json type)
                 (map->JsonbPathBinaryExpression {:field column-name
                                                  :column-data cinfo
                                                  :value (su/munge-jsonb-for-storage value)


               :relationships certname-relations

               :alias "package_inventory"
               :subquery? false
               :source-table "packages"}))

(def factsets-query
  "Query for the top level facts query"


            [[(op :guard #{">" "<" ">=" "<="}) column-name value]]
            (let [colname (first (str/split column-name #"\."))
                  {:keys [type] :as cinfo} (get-in query-rec [:projections colname])]
              (cond
                (= :timestamp type)
                (map->BinaryExpression {:operator (keyword op)
