Add a way to unescape constant values
In some situations escaping a constant value is undesirable. See the query below which causes Postgres to complain that the selection is not in the group by.
Select
date_trunc($1,"sessions1"."started") as "g0",
count("sessions1"."user_id") as "c0"
From
"sessions" "sessions1"
Where
(((date_trunc($2,"sessions1"."started") >= $3) and (date_trunc($4,"sessions1"."started") <= $5)) and "sessions1"."user_id" is not null)
Group By
date_trunc($6,"sessions1"."started")
Order By
date_trunc($7,"sessions1"."started") Asc
Leave a comment