materialize the cte and pretty print the json for powerbi consumption

This commit is contained in:
Paul Trowbridge 2025-08-07 12:58:40 -04:00
parent d9ccc7b2a8
commit 34f390478e

View File

@ -14,7 +14,7 @@ lq AS MATERIALIZED (
qstat LIKE '%Submitted%'
)
---------------------guidance logic---------------------------------------
,lqg AS (
,lqg AS MATERIALIZED (
SELECT
lq.qid
,lq.qline
@ -105,7 +105,7 @@ lq AS MATERIALIZED (
-- ,jsonb_pretty(pricing) pricing
,p.guidance_price
,p.guidance_reason
,p.expl
,jsonb_pretty(p.expl) expl
FROM
lq
LEFT OUTER JOIN "CMS.CUSLG".itemm i ON