growthbook / growthbook

Open Source Feature Flagging and A/B Testing Platform

Home Page:https://www.growthbook.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Feature] Support Postgres 12+ CTE or Custom experiment queries

overborn opened this issue · comments

Description of Feature

After upgrading our RDS from version 11 to 15, we have noticed that growthbook experiment queries, which previously took about minute to complete, hang for hours with no result.
The reason is that postgres reapproched common table expressions.
In order for generated query to be able to run in reasonable time, we should be able to extend expressions like WITH __rawExperiment as ( ... withWITH__ rawExperiment as MATERIALIZED ( ...
I believe the most convenient solution would be ability to save and change pre-generated experiment queries, with option to reset to default ones.