Skip to content
Snippets Groups Projects
Commit c0dc5074 authored by Ryan Senior's avatar Ryan Senior
Browse files

Add type information to expression columns

Expressions aren't columns, but they have an entry in the cols
property which currently doesn't have type info. This adds that which
allows it to be used as the Y-axis in graphs.

Fixes #3952
parent 835dae9c
No related branches found
No related tags found
No related merge requests found
......@@ -69,7 +69,10 @@
:field-display-name (humanization/name->human-readable-name (:field-name this)))]
metabase.query_processor.interface.ExpressionRef
[(assoc this :field-display-name (:expression-name this))]
[(assoc this
:field-display-name (:expression-name this)
:base-type :type/Float
:special-type :type/Number)]
;; for every value in a map in the query we'll descend into the map and find all the fields contained therein and mark the key as each field's source.
;; e.g. if we descend into the `:breakout` columns for a query each field returned will get a `:source` of `:breakout`
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment