Skip to content

Commit

Permalink
Allow changing query type, as I suddenly find that would be useful.
Browse files Browse the repository at this point in the history
  • Loading branch information
mindreader committed Apr 13, 2023
1 parent 1fffa95 commit 1911e32
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/simpleramix.ex
Original file line number Diff line number Diff line change
Expand Up @@ -510,4 +510,11 @@ defmodule Simpleramix do
}
end
end

def as_query_type(%Simpleramix.Query{} = query, type) when type in [:groupBy, :timeseries, :topN] do
%Simpleramix.Query{
query
| query_type: type
}
end
end

0 comments on commit 1911e32

Please sign in to comment.