[{"data":1,"prerenderedAt":32484},["ShallowReactive",2],{"tutorial-ecommerce-pipeline\u002Fproject-setup":3,"content-query-UBbc4fVnV4":1566,"content-query-CfBqQbZcXI":2841},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"readingTime":11,"category":12,"tags":13,"difficulty":21,"module":5,"subSteps":22,"step":23,"variants":24,"journeys":25,"learnMore":28,"author":38,"body":42,"_type":1560,"_id":1561,"_source":1562,"_file":1563,"_stem":1564,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fproject-setup","ecommerce-pipeline",false,"","Set Up Your Project & Warehouse","Install Bruin CLI, initialize an ecommerce project, connect your data warehouse, and set up AI-assisted development with Claude Code and the Bruin MCP.","2026-04-09",8,"Tutorial",[14,15,16,17,18,19,20],"Bruin CLI","Claude Code","MCP","ClickHouse","BigQuery","Snowflake","E-commerce","Beginner",true,1,[17,18,19],[26,27],"Data Analyst","Data Engineer",[29,32,35],{"label":30,"url":31},"Bruin project structure (docs)","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fcore-concepts\u002Fproject.html",{"label":33,"url":34},"Connections reference","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fconnections\u002Foverview.html",{"label":36,"url":37},"Bruin MCP setup guide","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fgetting-started\u002Fbruin-mcp.html",{"name":39,"role":40,"image":41},"Bruin Team","Bruin Data","\u002Fbruin-logo-2025.svg",{"type":43,"children":44,"toc":1546},"root",[45,54,60,66,71,131,181,187,192,197,213,219,226,239,321,326,336,342,353,384,411,417,422,1090,1096,1108,1366,1372,1384,1428,1433,1442,1447,1476,1482,1487,1511,1516,1524,1529,1535,1540],{"type":46,"tag":47,"props":48,"children":50},"element","h2",{"id":49},"what-youll-do",[51],{"type":52,"value":53},"text","What you'll do",{"type":46,"tag":55,"props":56,"children":57},"p",{},[58],{"type":52,"value":59},"Create a project, connect your data warehouse, and set up Claude Code with the Bruin MCP so it can help you build the rest of the pipeline.",{"type":46,"tag":47,"props":61,"children":63},{"id":62},"prerequisites",[64],{"type":52,"value":65},"Prerequisites",{"type":46,"tag":55,"props":67,"children":68},{},[69],{"type":52,"value":70},"Before starting, make sure you have these installed:",{"type":46,"tag":72,"props":73,"children":74},"ul",{},[75,107],{"type":46,"tag":76,"props":77,"children":78},"li",{},[79,85,87,96,98,105],{"type":46,"tag":80,"props":81,"children":82},"strong",{},[83],{"type":52,"value":84},"Git",{"type":52,"value":86}," - ",{"type":46,"tag":88,"props":89,"children":93},"a",{"href":90,"rel":91},"https:\u002F\u002Fgit-scm.com\u002Fdownloads",[92],"nofollow",[94],{"type":52,"value":95},"git-scm.com\u002Fdownloads",{"type":52,"value":97},". Verify with ",{"type":46,"tag":99,"props":100,"children":102},"code",{"className":101},[],[103],{"type":52,"value":104},"git --version",{"type":52,"value":106},".",{"type":46,"tag":76,"props":108,"children":109},{},[110,114,116,123,124,130],{"type":46,"tag":80,"props":111,"children":112},{},[113],{"type":52,"value":14},{"type":52,"value":115}," - install from the ",{"type":46,"tag":88,"props":117,"children":120},{"href":118,"rel":119},"https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fgetting-started\u002Fintroduction\u002Finstallation.html",[92],[121],{"type":52,"value":122},"installation docs",{"type":52,"value":97},{"type":46,"tag":99,"props":125,"children":127},{"className":126},[],[128],{"type":52,"value":129},"bruin version",{"type":52,"value":106},{"type":46,"tag":55,"props":132,"children":133},{},[134,136,142,144,150,152,158,159,165,166,172,174,180],{"type":52,"value":135},"If you're new to Bruin, the ",{"type":46,"tag":88,"props":137,"children":139},{"href":138},"\u002Flearn\u002Fcore-concepts",[140],{"type":52,"value":141},"Core Concepts",{"type":52,"value":143}," module covers ",{"type":46,"tag":88,"props":145,"children":147},{"href":146},"\u002Flearn\u002Fcore-concepts\u002Fprojects",[148],{"type":52,"value":149},"projects",{"type":52,"value":151},", ",{"type":46,"tag":88,"props":153,"children":155},{"href":154},"\u002Flearn\u002Fcore-concepts\u002Fpipelines",[156],{"type":52,"value":157},"pipelines",{"type":52,"value":151},{"type":46,"tag":88,"props":160,"children":162},{"href":161},"\u002Flearn\u002Fcore-concepts\u002Fassets",[163],{"type":52,"value":164},"assets",{"type":52,"value":151},{"type":46,"tag":88,"props":167,"children":169},{"href":168},"\u002Flearn\u002Fcore-concepts\u002Fvariables",[170],{"type":52,"value":171},"variables",{"type":52,"value":173},", and ",{"type":46,"tag":88,"props":175,"children":177},{"href":176},"\u002Flearn\u002Fcore-concepts\u002Fcommands",[178],{"type":52,"value":179},"commands",{"type":52,"value":106},{"type":46,"tag":47,"props":182,"children":184},{"id":183},"why-this-step-matters",[185],{"type":52,"value":186},"Why this step matters",{"type":46,"tag":55,"props":188,"children":189},{},[190],{"type":52,"value":191},"Every data pipeline needs two things: an orchestration tool and a destination. Bruin is the orchestrator - it defines what data moves where and when. Your data warehouse is the destination where all your Shopify and ecommerce data will land and get transformed.",{"type":46,"tag":55,"props":193,"children":194},{},[195],{"type":52,"value":196},"We'll use Claude Code throughout this tutorial to help create files, write SQL, run validations, and troubleshoot issues. Setting up the Bruin MCP early gives Claude Code direct access to your pipeline and warehouse from Step 2 onward.",{"type":46,"tag":198,"props":199,"children":200},"note",{},[201],{"type":46,"tag":55,"props":202,"children":203},{},[204,206,212],{"type":52,"value":205},"If you already have a Bruin project, skip ahead to ",{"type":46,"tag":88,"props":207,"children":209},{"href":208},"\u002Flearn\u002Fecommerce-pipeline\u002Fingest-data",[210],{"type":52,"value":211},"Step 2: Ingest Your Data",{"type":52,"value":106},{"type":46,"tag":47,"props":214,"children":216},{"id":215},"instructions",[217],{"type":52,"value":218},"Instructions",{"type":46,"tag":220,"props":221,"children":223},"h3",{"id":222},"_1-initialize-a-project",[224],{"type":52,"value":225},"1) Initialize a project",{"type":46,"tag":55,"props":227,"children":228},{},[229,231,237],{"type":52,"value":230},"Create a folder for your project, initialize git, then run ",{"type":46,"tag":99,"props":232,"children":234},{"className":233},[],[235],{"type":52,"value":236},"bruin init",{"type":52,"value":238}," inside it:",{"type":46,"tag":240,"props":241,"children":245},"pre",{"className":242,"code":243,"language":244,"meta":7,"style":7},"language-bash shiki shiki-themes github-dark","mkdir ecommerce-analytics && cd ecommerce-analytics\ngit init\nbruin init empty ecommerce\n","bash",[246],{"type":46,"tag":99,"props":247,"children":248},{"__ignoreMap":7},[249,283,297],{"type":46,"tag":250,"props":251,"children":253},"span",{"class":252,"line":23},"line",[254,260,266,272,278],{"type":46,"tag":250,"props":255,"children":257},{"style":256},"--shiki-default:#B392F0",[258],{"type":52,"value":259},"mkdir",{"type":46,"tag":250,"props":261,"children":263},{"style":262},"--shiki-default:#9ECBFF",[264],{"type":52,"value":265}," ecommerce-analytics",{"type":46,"tag":250,"props":267,"children":269},{"style":268},"--shiki-default:#E1E4E8",[270],{"type":52,"value":271}," && ",{"type":46,"tag":250,"props":273,"children":275},{"style":274},"--shiki-default:#79B8FF",[276],{"type":52,"value":277},"cd",{"type":46,"tag":250,"props":279,"children":280},{"style":262},[281],{"type":52,"value":282}," ecommerce-analytics\n",{"type":46,"tag":250,"props":284,"children":286},{"class":252,"line":285},2,[287,292],{"type":46,"tag":250,"props":288,"children":289},{"style":256},[290],{"type":52,"value":291},"git",{"type":46,"tag":250,"props":293,"children":294},{"style":262},[295],{"type":52,"value":296}," init\n",{"type":46,"tag":250,"props":298,"children":300},{"class":252,"line":299},3,[301,306,311,316],{"type":46,"tag":250,"props":302,"children":303},{"style":256},[304],{"type":52,"value":305},"bruin",{"type":46,"tag":250,"props":307,"children":308},{"style":262},[309],{"type":52,"value":310}," init",{"type":46,"tag":250,"props":312,"children":313},{"style":262},[314],{"type":52,"value":315}," empty",{"type":46,"tag":250,"props":317,"children":318},{"style":262},[319],{"type":52,"value":320}," ecommerce\n",{"type":46,"tag":55,"props":322,"children":323},{},[324],{"type":52,"value":325},"This creates the following structure:",{"type":46,"tag":240,"props":327,"children":331},{"className":328,"code":330,"language":52},[329],"language-text","ecommerce-analytics\u002F\n├── .bruin.yml            # project config - connections, environments\n└── ecommerce\u002F            # pipeline folder\n    ├── pipeline.yml      # pipeline config - name, schedule, defaults\n    └── assets\u002F           # where your data assets will live\n",[332],{"type":46,"tag":99,"props":333,"children":334},{"__ignoreMap":7},[335],{"type":52,"value":330},{"type":46,"tag":220,"props":337,"children":339},{"id":338},"_2-add-bruinyml-to-gitignore",[340],{"type":52,"value":341},"2) Add .bruin.yml to .gitignore",{"type":46,"tag":55,"props":343,"children":344},{},[345,351],{"type":46,"tag":99,"props":346,"children":348},{"className":347},[],[349],{"type":52,"value":350},".bruin.yml",{"type":52,"value":352}," stores your connection credentials (database passwords, API keys). You don't want these in git.",{"type":46,"tag":240,"props":354,"children":356},{"className":242,"code":355,"language":244,"meta":7,"style":7},"echo \".bruin.yml\" >> .gitignore\n",[357],{"type":46,"tag":99,"props":358,"children":359},{"__ignoreMap":7},[360],{"type":46,"tag":250,"props":361,"children":362},{"class":252,"line":23},[363,368,373,379],{"type":46,"tag":250,"props":364,"children":365},{"style":274},[366],{"type":52,"value":367},"echo",{"type":46,"tag":250,"props":369,"children":370},{"style":262},[371],{"type":52,"value":372}," \".bruin.yml\"",{"type":46,"tag":250,"props":374,"children":376},{"style":375},"--shiki-default:#F97583",[377],{"type":52,"value":378}," >>",{"type":46,"tag":250,"props":380,"children":381},{"style":262},[382],{"type":52,"value":383}," .gitignore\n",{"type":46,"tag":55,"props":385,"children":386},{},[387,392,394,400,402,409],{"type":46,"tag":99,"props":388,"children":390},{"className":389},[],[391],{"type":52,"value":236},{"type":52,"value":393}," may already add this for you - check your ",{"type":46,"tag":99,"props":395,"children":397},{"className":396},[],[398],{"type":52,"value":399},".gitignore",{"type":52,"value":401}," to confirm. When you deploy to production, connections are configured securely in ",{"type":46,"tag":88,"props":403,"children":406},{"href":404,"rel":405},"https:\u002F\u002Fcloud.getbruin.com",[92],[407],{"type":52,"value":408},"Bruin Cloud",{"type":52,"value":410}," instead of the local file - we'll set that up in Step 5.",{"type":46,"tag":220,"props":412,"children":414},{"id":413},"_3-connect-your-data-warehouse",[415],{"type":52,"value":416},"3) Connect your data warehouse",{"type":46,"tag":55,"props":418,"children":419},{},[420],{"type":52,"value":421},"Pick the tab that matches the warehouse you selected on the overview page.",{"type":46,"tag":423,"props":424,"children":427},"variant-tabs",{":variants":425,"group":426},"[{\"id\":\"clickhouse\",\"label\":\"ClickHouse\"},{\"id\":\"bigquery\",\"label\":\"BigQuery\"},{\"id\":\"snowflake\",\"label\":\"Snowflake\"}]","warehouse",[428,598,925],{"type":46,"tag":429,"props":430,"children":431},"template",{"v-slot:clickhouse":7},[432,437,475,499,504,547,552,585],{"type":46,"tag":220,"props":433,"children":435},{"id":434},"clickhouse",[436],{"type":52,"value":17},{"type":46,"tag":55,"props":438,"children":439},{},[440,442,449,451,456,457,462,463,468,469,474],{"type":52,"value":441},"If you don't have a ClickHouse instance yet, go to ",{"type":46,"tag":88,"props":443,"children":446},{"href":444,"rel":445},"https:\u002F\u002Fclickhouse.com\u002Fcloud",[92],[447],{"type":52,"value":448},"clickhouse.com\u002Fcloud",{"type":52,"value":450}," and sign up for the free tier. Create a new service and copy the ",{"type":46,"tag":80,"props":452,"children":453},{},[454],{"type":52,"value":455},"host",{"type":52,"value":151},{"type":46,"tag":80,"props":458,"children":459},{},[460],{"type":52,"value":461},"port",{"type":52,"value":151},{"type":46,"tag":80,"props":464,"children":465},{},[466],{"type":52,"value":467},"username",{"type":52,"value":173},{"type":46,"tag":80,"props":470,"children":471},{},[472],{"type":52,"value":473},"password",{"type":52,"value":106},{"type":46,"tag":240,"props":476,"children":478},{"className":242,"code":477,"language":244,"meta":7,"style":7},"bruin connections add\n",[479],{"type":46,"tag":99,"props":480,"children":481},{"__ignoreMap":7},[482],{"type":46,"tag":250,"props":483,"children":484},{"class":252,"line":23},[485,489,494],{"type":46,"tag":250,"props":486,"children":487},{"style":256},[488],{"type":52,"value":305},{"type":46,"tag":250,"props":490,"children":491},{"style":262},[492],{"type":52,"value":493}," connections",{"type":46,"tag":250,"props":495,"children":496},{"style":262},[497],{"type":52,"value":498}," add\n",{"type":46,"tag":55,"props":500,"children":501},{},[502],{"type":52,"value":503},"When prompted:",{"type":46,"tag":72,"props":505,"children":506},{},[507,522,537],{"type":46,"tag":76,"props":508,"children":509},{},[510,515,517],{"type":46,"tag":80,"props":511,"children":512},{},[513],{"type":52,"value":514},"Type:",{"type":52,"value":516}," ",{"type":46,"tag":99,"props":518,"children":520},{"className":519},[],[521],{"type":52,"value":434},{"type":46,"tag":76,"props":523,"children":524},{},[525,530,531],{"type":46,"tag":80,"props":526,"children":527},{},[528],{"type":52,"value":529},"Name:",{"type":52,"value":516},{"type":46,"tag":99,"props":532,"children":534},{"className":533},[],[535],{"type":52,"value":536},"clickhouse-default",{"type":46,"tag":76,"props":538,"children":539},{},[540,545],{"type":46,"tag":80,"props":541,"children":542},{},[543],{"type":52,"value":544},"Host, port, username, password:",{"type":52,"value":546}," paste the values from your ClickHouse Cloud service",{"type":46,"tag":55,"props":548,"children":549},{},[550],{"type":52,"value":551},"Test the connection:",{"type":46,"tag":240,"props":553,"children":555},{"className":242,"code":554,"language":244,"meta":7,"style":7},"bruin connections test --name clickhouse-default\n",[556],{"type":46,"tag":99,"props":557,"children":558},{"__ignoreMap":7},[559],{"type":46,"tag":250,"props":560,"children":561},{"class":252,"line":23},[562,566,570,575,580],{"type":46,"tag":250,"props":563,"children":564},{"style":256},[565],{"type":52,"value":305},{"type":46,"tag":250,"props":567,"children":568},{"style":262},[569],{"type":52,"value":493},{"type":46,"tag":250,"props":571,"children":572},{"style":262},[573],{"type":52,"value":574}," test",{"type":46,"tag":250,"props":576,"children":577},{"style":274},[578],{"type":52,"value":579}," --name",{"type":46,"tag":250,"props":581,"children":582},{"style":262},[583],{"type":52,"value":584}," clickhouse-default\n",{"type":46,"tag":55,"props":586,"children":587},{},[588,590,597],{"type":52,"value":589},"For full connection options, see the ",{"type":46,"tag":88,"props":591,"children":594},{"href":592,"rel":593},"https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fplatforms\u002Fclickhouse.html",[92],[595],{"type":52,"value":596},"ClickHouse platform docs",{"type":52,"value":106},{"type":46,"tag":429,"props":599,"children":600},{"v-slot:bigquery":7},[601,606,614,644,649,670,674,738,746,758,878,882,913],{"type":46,"tag":220,"props":602,"children":604},{"id":603},"bigquery",[605],{"type":52,"value":18},{"type":46,"tag":55,"props":607,"children":608},{},[609],{"type":46,"tag":80,"props":610,"children":611},{},[612],{"type":52,"value":613},"Option A: Application Default Credentials (personal account)",{"type":46,"tag":240,"props":615,"children":617},{"className":242,"code":616,"language":244,"meta":7,"style":7},"gcloud auth application-default login\n",[618],{"type":46,"tag":99,"props":619,"children":620},{"__ignoreMap":7},[621],{"type":46,"tag":250,"props":622,"children":623},{"class":252,"line":23},[624,629,634,639],{"type":46,"tag":250,"props":625,"children":626},{"style":256},[627],{"type":52,"value":628},"gcloud",{"type":46,"tag":250,"props":630,"children":631},{"style":262},[632],{"type":52,"value":633}," auth",{"type":46,"tag":250,"props":635,"children":636},{"style":262},[637],{"type":52,"value":638}," application-default",{"type":46,"tag":250,"props":640,"children":641},{"style":262},[642],{"type":52,"value":643}," login\n",{"type":46,"tag":55,"props":645,"children":646},{},[647],{"type":52,"value":648},"This opens a browser for Google sign-in. Once done, run:",{"type":46,"tag":240,"props":650,"children":651},{"className":242,"code":477,"language":244,"meta":7,"style":7},[652],{"type":46,"tag":99,"props":653,"children":654},{"__ignoreMap":7},[655],{"type":46,"tag":250,"props":656,"children":657},{"class":252,"line":23},[658,662,666],{"type":46,"tag":250,"props":659,"children":660},{"style":256},[661],{"type":52,"value":305},{"type":46,"tag":250,"props":663,"children":664},{"style":262},[665],{"type":52,"value":493},{"type":46,"tag":250,"props":667,"children":668},{"style":262},[669],{"type":52,"value":498},{"type":46,"tag":55,"props":671,"children":672},{},[673],{"type":52,"value":503},{"type":46,"tag":72,"props":675,"children":676},{},[677,691,705,715],{"type":46,"tag":76,"props":678,"children":679},{},[680,684,685],{"type":46,"tag":80,"props":681,"children":682},{},[683],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":686,"children":688},{"className":687},[],[689],{"type":52,"value":690},"google_cloud_platform",{"type":46,"tag":76,"props":692,"children":693},{},[694,698,699],{"type":46,"tag":80,"props":695,"children":696},{},[697],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":700,"children":702},{"className":701},[],[703],{"type":52,"value":704},"bigquery-default",{"type":46,"tag":76,"props":706,"children":707},{},[708,713],{"type":46,"tag":80,"props":709,"children":710},{},[711],{"type":52,"value":712},"Project ID:",{"type":52,"value":714}," your GCP project ID",{"type":46,"tag":76,"props":716,"children":717},{},[718,723,724,730,732],{"type":46,"tag":80,"props":719,"children":720},{},[721],{"type":52,"value":722},"Credential method:",{"type":52,"value":516},{"type":46,"tag":99,"props":725,"children":727},{"className":726},[],[728],{"type":52,"value":729},"use_application_default_credentials",{"type":52,"value":731}," set to ",{"type":46,"tag":99,"props":733,"children":735},{"className":734},[],[736],{"type":52,"value":737},"true",{"type":46,"tag":55,"props":739,"children":740},{},[741],{"type":46,"tag":80,"props":742,"children":743},{},[744],{"type":52,"value":745},"Option B: Service Account Key File",{"type":46,"tag":55,"props":747,"children":748},{},[749,751,756],{"type":52,"value":750},"Edit ",{"type":46,"tag":99,"props":752,"children":754},{"className":753},[],[755],{"type":52,"value":350},{"type":52,"value":757}," directly:",{"type":46,"tag":240,"props":759,"children":763},{"className":760,"code":761,"language":762,"meta":7,"style":7},"language-yaml shiki shiki-themes github-dark","environments:\n  default:\n    connections:\n      google_cloud_platform:\n        - name: \"bigquery-default\"\n          project_id: \"your-gcp-project-id\"\n          service_account_file: \"\u002Fpath\u002Fto\u002Fyour-service-account.json\"\n","yaml",[764],{"type":46,"tag":99,"props":765,"children":766},{"__ignoreMap":7},[767,781,793,805,818,842,860],{"type":46,"tag":250,"props":768,"children":769},{"class":252,"line":23},[770,776],{"type":46,"tag":250,"props":771,"children":773},{"style":772},"--shiki-default:#85E89D",[774],{"type":52,"value":775},"environments",{"type":46,"tag":250,"props":777,"children":778},{"style":268},[779],{"type":52,"value":780},":\n",{"type":46,"tag":250,"props":782,"children":783},{"class":252,"line":285},[784,789],{"type":46,"tag":250,"props":785,"children":786},{"style":772},[787],{"type":52,"value":788},"  default",{"type":46,"tag":250,"props":790,"children":791},{"style":268},[792],{"type":52,"value":780},{"type":46,"tag":250,"props":794,"children":795},{"class":252,"line":299},[796,801],{"type":46,"tag":250,"props":797,"children":798},{"style":772},[799],{"type":52,"value":800},"    connections",{"type":46,"tag":250,"props":802,"children":803},{"style":268},[804],{"type":52,"value":780},{"type":46,"tag":250,"props":806,"children":808},{"class":252,"line":807},4,[809,814],{"type":46,"tag":250,"props":810,"children":811},{"style":772},[812],{"type":52,"value":813},"      google_cloud_platform",{"type":46,"tag":250,"props":815,"children":816},{"style":268},[817],{"type":52,"value":780},{"type":46,"tag":250,"props":819,"children":821},{"class":252,"line":820},5,[822,827,832,837],{"type":46,"tag":250,"props":823,"children":824},{"style":268},[825],{"type":52,"value":826},"        - ",{"type":46,"tag":250,"props":828,"children":829},{"style":772},[830],{"type":52,"value":831},"name",{"type":46,"tag":250,"props":833,"children":834},{"style":268},[835],{"type":52,"value":836},": ",{"type":46,"tag":250,"props":838,"children":839},{"style":262},[840],{"type":52,"value":841},"\"bigquery-default\"\n",{"type":46,"tag":250,"props":843,"children":845},{"class":252,"line":844},6,[846,851,855],{"type":46,"tag":250,"props":847,"children":848},{"style":772},[849],{"type":52,"value":850},"          project_id",{"type":46,"tag":250,"props":852,"children":853},{"style":268},[854],{"type":52,"value":836},{"type":46,"tag":250,"props":856,"children":857},{"style":262},[858],{"type":52,"value":859},"\"your-gcp-project-id\"\n",{"type":46,"tag":250,"props":861,"children":863},{"class":252,"line":862},7,[864,869,873],{"type":46,"tag":250,"props":865,"children":866},{"style":772},[867],{"type":52,"value":868},"          service_account_file",{"type":46,"tag":250,"props":870,"children":871},{"style":268},[872],{"type":52,"value":836},{"type":46,"tag":250,"props":874,"children":875},{"style":262},[876],{"type":52,"value":877},"\"\u002Fpath\u002Fto\u002Fyour-service-account.json\"\n",{"type":46,"tag":55,"props":879,"children":880},{},[881],{"type":52,"value":551},{"type":46,"tag":240,"props":883,"children":885},{"className":242,"code":884,"language":244,"meta":7,"style":7},"bruin connections test --name bigquery-default\n",[886],{"type":46,"tag":99,"props":887,"children":888},{"__ignoreMap":7},[889],{"type":46,"tag":250,"props":890,"children":891},{"class":252,"line":23},[892,896,900,904,908],{"type":46,"tag":250,"props":893,"children":894},{"style":256},[895],{"type":52,"value":305},{"type":46,"tag":250,"props":897,"children":898},{"style":262},[899],{"type":52,"value":493},{"type":46,"tag":250,"props":901,"children":902},{"style":262},[903],{"type":52,"value":574},{"type":46,"tag":250,"props":905,"children":906},{"style":274},[907],{"type":52,"value":579},{"type":46,"tag":250,"props":909,"children":910},{"style":262},[911],{"type":52,"value":912}," bigquery-default\n",{"type":46,"tag":55,"props":914,"children":915},{},[916,917,924],{"type":52,"value":589},{"type":46,"tag":88,"props":918,"children":921},{"href":919,"rel":920},"https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fplatforms\u002Fbigquery.html",[92],[922],{"type":52,"value":923},"BigQuery platform docs",{"type":52,"value":106},{"type":46,"tag":429,"props":926,"children":927},{"v-slot:snowflake":7},[928,933,954,958,1043,1047,1078],{"type":46,"tag":220,"props":929,"children":931},{"id":930},"snowflake",[932],{"type":52,"value":19},{"type":46,"tag":240,"props":934,"children":935},{"className":242,"code":477,"language":244,"meta":7,"style":7},[936],{"type":46,"tag":99,"props":937,"children":938},{"__ignoreMap":7},[939],{"type":46,"tag":250,"props":940,"children":941},{"class":252,"line":23},[942,946,950],{"type":46,"tag":250,"props":943,"children":944},{"style":256},[945],{"type":52,"value":305},{"type":46,"tag":250,"props":947,"children":948},{"style":262},[949],{"type":52,"value":493},{"type":46,"tag":250,"props":951,"children":952},{"style":262},[953],{"type":52,"value":498},{"type":46,"tag":55,"props":955,"children":956},{},[957],{"type":52,"value":503},{"type":46,"tag":72,"props":959,"children":960},{},[961,974,988,1006,1016,1026],{"type":46,"tag":76,"props":962,"children":963},{},[964,968,969],{"type":46,"tag":80,"props":965,"children":966},{},[967],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":970,"children":972},{"className":971},[],[973],{"type":52,"value":930},{"type":46,"tag":76,"props":975,"children":976},{},[977,981,982],{"type":46,"tag":80,"props":978,"children":979},{},[980],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":983,"children":985},{"className":984},[],[986],{"type":52,"value":987},"snowflake-default",{"type":46,"tag":76,"props":989,"children":990},{},[991,996,998,1004],{"type":46,"tag":80,"props":992,"children":993},{},[994],{"type":52,"value":995},"Account:",{"type":52,"value":997}," your Snowflake account identifier (e.g. ",{"type":46,"tag":99,"props":999,"children":1001},{"className":1000},[],[1002],{"type":52,"value":1003},"abc12345.us-east-1",{"type":52,"value":1005},")",{"type":46,"tag":76,"props":1007,"children":1008},{},[1009,1014],{"type":46,"tag":80,"props":1010,"children":1011},{},[1012],{"type":52,"value":1013},"Username and password:",{"type":52,"value":1015}," your Snowflake credentials",{"type":46,"tag":76,"props":1017,"children":1018},{},[1019,1024],{"type":46,"tag":80,"props":1020,"children":1021},{},[1022],{"type":52,"value":1023},"Database and warehouse:",{"type":52,"value":1025}," your target database and compute warehouse",{"type":46,"tag":76,"props":1027,"children":1028},{},[1029,1034,1035,1041],{"type":46,"tag":80,"props":1030,"children":1031},{},[1032],{"type":52,"value":1033},"Schema",{"type":52,"value":516},{"type":46,"tag":1036,"props":1037,"children":1038},"em",{},[1039],{"type":52,"value":1040},"(optional):",{"type":52,"value":1042}," default schema to use",{"type":46,"tag":55,"props":1044,"children":1045},{},[1046],{"type":52,"value":551},{"type":46,"tag":240,"props":1048,"children":1050},{"className":242,"code":1049,"language":244,"meta":7,"style":7},"bruin connections test --name snowflake-default\n",[1051],{"type":46,"tag":99,"props":1052,"children":1053},{"__ignoreMap":7},[1054],{"type":46,"tag":250,"props":1055,"children":1056},{"class":252,"line":23},[1057,1061,1065,1069,1073],{"type":46,"tag":250,"props":1058,"children":1059},{"style":256},[1060],{"type":52,"value":305},{"type":46,"tag":250,"props":1062,"children":1063},{"style":262},[1064],{"type":52,"value":493},{"type":46,"tag":250,"props":1066,"children":1067},{"style":262},[1068],{"type":52,"value":574},{"type":46,"tag":250,"props":1070,"children":1071},{"style":274},[1072],{"type":52,"value":579},{"type":46,"tag":250,"props":1074,"children":1075},{"style":262},[1076],{"type":52,"value":1077}," snowflake-default\n",{"type":46,"tag":55,"props":1079,"children":1080},{},[1081,1082,1089],{"type":52,"value":589},{"type":46,"tag":88,"props":1083,"children":1086},{"href":1084,"rel":1085},"https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fplatforms\u002Fsnowflake.html",[92],[1087],{"type":52,"value":1088},"Snowflake platform docs",{"type":52,"value":106},{"type":46,"tag":220,"props":1091,"children":1093},{"id":1092},"_4-configure-the-pipeline",[1094],{"type":52,"value":1095},"4) Configure the pipeline",{"type":46,"tag":55,"props":1097,"children":1098},{},[1099,1100,1106],{"type":52,"value":750},{"type":46,"tag":99,"props":1101,"children":1103},{"className":1102},[],[1104],{"type":52,"value":1105},"ecommerce\u002Fpipeline.yml",{"type":52,"value":1107}," to set the default connection and schedule:",{"type":46,"tag":423,"props":1109,"children":1110},{":variants":425,"group":426},[1111,1200,1283],{"type":46,"tag":429,"props":1112,"children":1113},{"v-slot:clickhouse":7},[1114],{"type":46,"tag":240,"props":1115,"children":1117},{"className":760,"code":1116,"language":762,"meta":7,"style":7},"name: ecommerce\nschedule: daily\nstart_date: \"2024-01-01\"\ndefault_connections:\n  clickhouse: clickhouse-default\n",[1118],{"type":46,"tag":99,"props":1119,"children":1120},{"__ignoreMap":7},[1121,1137,1154,1171,1183],{"type":46,"tag":250,"props":1122,"children":1123},{"class":252,"line":23},[1124,1128,1132],{"type":46,"tag":250,"props":1125,"children":1126},{"style":772},[1127],{"type":52,"value":831},{"type":46,"tag":250,"props":1129,"children":1130},{"style":268},[1131],{"type":52,"value":836},{"type":46,"tag":250,"props":1133,"children":1134},{"style":262},[1135],{"type":52,"value":1136},"ecommerce\n",{"type":46,"tag":250,"props":1138,"children":1139},{"class":252,"line":285},[1140,1145,1149],{"type":46,"tag":250,"props":1141,"children":1142},{"style":772},[1143],{"type":52,"value":1144},"schedule",{"type":46,"tag":250,"props":1146,"children":1147},{"style":268},[1148],{"type":52,"value":836},{"type":46,"tag":250,"props":1150,"children":1151},{"style":262},[1152],{"type":52,"value":1153},"daily\n",{"type":46,"tag":250,"props":1155,"children":1156},{"class":252,"line":299},[1157,1162,1166],{"type":46,"tag":250,"props":1158,"children":1159},{"style":772},[1160],{"type":52,"value":1161},"start_date",{"type":46,"tag":250,"props":1163,"children":1164},{"style":268},[1165],{"type":52,"value":836},{"type":46,"tag":250,"props":1167,"children":1168},{"style":262},[1169],{"type":52,"value":1170},"\"2024-01-01\"\n",{"type":46,"tag":250,"props":1172,"children":1173},{"class":252,"line":807},[1174,1179],{"type":46,"tag":250,"props":1175,"children":1176},{"style":772},[1177],{"type":52,"value":1178},"default_connections",{"type":46,"tag":250,"props":1180,"children":1181},{"style":268},[1182],{"type":52,"value":780},{"type":46,"tag":250,"props":1184,"children":1185},{"class":252,"line":820},[1186,1191,1195],{"type":46,"tag":250,"props":1187,"children":1188},{"style":772},[1189],{"type":52,"value":1190},"  clickhouse",{"type":46,"tag":250,"props":1192,"children":1193},{"style":268},[1194],{"type":52,"value":836},{"type":46,"tag":250,"props":1196,"children":1197},{"style":262},[1198],{"type":52,"value":1199},"clickhouse-default\n",{"type":46,"tag":429,"props":1201,"children":1202},{"v-slot:bigquery":7},[1203],{"type":46,"tag":240,"props":1204,"children":1206},{"className":760,"code":1205,"language":762,"meta":7,"style":7},"name: ecommerce\nschedule: daily\nstart_date: \"2024-01-01\"\ndefault_connections:\n  google_cloud_platform: bigquery-default\n",[1207],{"type":46,"tag":99,"props":1208,"children":1209},{"__ignoreMap":7},[1210,1225,1240,1255,1266],{"type":46,"tag":250,"props":1211,"children":1212},{"class":252,"line":23},[1213,1217,1221],{"type":46,"tag":250,"props":1214,"children":1215},{"style":772},[1216],{"type":52,"value":831},{"type":46,"tag":250,"props":1218,"children":1219},{"style":268},[1220],{"type":52,"value":836},{"type":46,"tag":250,"props":1222,"children":1223},{"style":262},[1224],{"type":52,"value":1136},{"type":46,"tag":250,"props":1226,"children":1227},{"class":252,"line":285},[1228,1232,1236],{"type":46,"tag":250,"props":1229,"children":1230},{"style":772},[1231],{"type":52,"value":1144},{"type":46,"tag":250,"props":1233,"children":1234},{"style":268},[1235],{"type":52,"value":836},{"type":46,"tag":250,"props":1237,"children":1238},{"style":262},[1239],{"type":52,"value":1153},{"type":46,"tag":250,"props":1241,"children":1242},{"class":252,"line":299},[1243,1247,1251],{"type":46,"tag":250,"props":1244,"children":1245},{"style":772},[1246],{"type":52,"value":1161},{"type":46,"tag":250,"props":1248,"children":1249},{"style":268},[1250],{"type":52,"value":836},{"type":46,"tag":250,"props":1252,"children":1253},{"style":262},[1254],{"type":52,"value":1170},{"type":46,"tag":250,"props":1256,"children":1257},{"class":252,"line":807},[1258,1262],{"type":46,"tag":250,"props":1259,"children":1260},{"style":772},[1261],{"type":52,"value":1178},{"type":46,"tag":250,"props":1263,"children":1264},{"style":268},[1265],{"type":52,"value":780},{"type":46,"tag":250,"props":1267,"children":1268},{"class":252,"line":820},[1269,1274,1278],{"type":46,"tag":250,"props":1270,"children":1271},{"style":772},[1272],{"type":52,"value":1273},"  google_cloud_platform",{"type":46,"tag":250,"props":1275,"children":1276},{"style":268},[1277],{"type":52,"value":836},{"type":46,"tag":250,"props":1279,"children":1280},{"style":262},[1281],{"type":52,"value":1282},"bigquery-default\n",{"type":46,"tag":429,"props":1284,"children":1285},{"v-slot:snowflake":7},[1286],{"type":46,"tag":240,"props":1287,"children":1289},{"className":760,"code":1288,"language":762,"meta":7,"style":7},"name: ecommerce\nschedule: daily\nstart_date: \"2024-01-01\"\ndefault_connections:\n  snowflake: snowflake-default\n",[1290],{"type":46,"tag":99,"props":1291,"children":1292},{"__ignoreMap":7},[1293,1308,1323,1338,1349],{"type":46,"tag":250,"props":1294,"children":1295},{"class":252,"line":23},[1296,1300,1304],{"type":46,"tag":250,"props":1297,"children":1298},{"style":772},[1299],{"type":52,"value":831},{"type":46,"tag":250,"props":1301,"children":1302},{"style":268},[1303],{"type":52,"value":836},{"type":46,"tag":250,"props":1305,"children":1306},{"style":262},[1307],{"type":52,"value":1136},{"type":46,"tag":250,"props":1309,"children":1310},{"class":252,"line":285},[1311,1315,1319],{"type":46,"tag":250,"props":1312,"children":1313},{"style":772},[1314],{"type":52,"value":1144},{"type":46,"tag":250,"props":1316,"children":1317},{"style":268},[1318],{"type":52,"value":836},{"type":46,"tag":250,"props":1320,"children":1321},{"style":262},[1322],{"type":52,"value":1153},{"type":46,"tag":250,"props":1324,"children":1325},{"class":252,"line":299},[1326,1330,1334],{"type":46,"tag":250,"props":1327,"children":1328},{"style":772},[1329],{"type":52,"value":1161},{"type":46,"tag":250,"props":1331,"children":1332},{"style":268},[1333],{"type":52,"value":836},{"type":46,"tag":250,"props":1335,"children":1336},{"style":262},[1337],{"type":52,"value":1170},{"type":46,"tag":250,"props":1339,"children":1340},{"class":252,"line":807},[1341,1345],{"type":46,"tag":250,"props":1342,"children":1343},{"style":772},[1344],{"type":52,"value":1178},{"type":46,"tag":250,"props":1346,"children":1347},{"style":268},[1348],{"type":52,"value":780},{"type":46,"tag":250,"props":1350,"children":1351},{"class":252,"line":820},[1352,1357,1361],{"type":46,"tag":250,"props":1353,"children":1354},{"style":772},[1355],{"type":52,"value":1356},"  snowflake",{"type":46,"tag":250,"props":1358,"children":1359},{"style":268},[1360],{"type":52,"value":836},{"type":46,"tag":250,"props":1362,"children":1363},{"style":262},[1364],{"type":52,"value":1365},"snowflake-default\n",{"type":46,"tag":220,"props":1367,"children":1369},{"id":1368},"_5-set-up-claude-code-with-bruin-mcp",[1370],{"type":52,"value":1371},"5) Set up Claude Code with Bruin MCP",{"type":46,"tag":55,"props":1373,"children":1374},{},[1375,1377,1382],{"type":52,"value":1376},"The Bruin MCP connects Claude Code directly to your pipeline and warehouse. Once it's set up, Claude Code can read your asset files, run ",{"type":46,"tag":99,"props":1378,"children":1380},{"className":1379},[],[1381],{"type":52,"value":305},{"type":52,"value":1383}," commands, query your warehouse, and look up Bruin documentation - all without you having to copy-paste anything.",{"type":46,"tag":240,"props":1385,"children":1387},{"className":242,"code":1386,"language":244,"meta":7,"style":7},"claude mcp add bruin -- bruin mcp\n",[1388],{"type":46,"tag":99,"props":1389,"children":1390},{"__ignoreMap":7},[1391],{"type":46,"tag":250,"props":1392,"children":1393},{"class":252,"line":23},[1394,1399,1404,1409,1414,1419,1423],{"type":46,"tag":250,"props":1395,"children":1396},{"style":256},[1397],{"type":52,"value":1398},"claude",{"type":46,"tag":250,"props":1400,"children":1401},{"style":262},[1402],{"type":52,"value":1403}," mcp",{"type":46,"tag":250,"props":1405,"children":1406},{"style":262},[1407],{"type":52,"value":1408}," add",{"type":46,"tag":250,"props":1410,"children":1411},{"style":262},[1412],{"type":52,"value":1413}," bruin",{"type":46,"tag":250,"props":1415,"children":1416},{"style":274},[1417],{"type":52,"value":1418}," --",{"type":46,"tag":250,"props":1420,"children":1421},{"style":262},[1422],{"type":52,"value":1413},{"type":46,"tag":250,"props":1424,"children":1425},{"style":262},[1426],{"type":52,"value":1427}," mcp\n",{"type":46,"tag":55,"props":1429,"children":1430},{},[1431],{"type":52,"value":1432},"Restart your Claude Code session for the MCP to take effect. To verify it's working, open Claude Code in your project directory and ask:",{"type":46,"tag":1434,"props":1435,"children":1436},"blockquote",{},[1437],{"type":46,"tag":55,"props":1438,"children":1439},{},[1440],{"type":52,"value":1441},"What connections are available in this Bruin project?",{"type":46,"tag":55,"props":1443,"children":1444},{},[1445],{"type":52,"value":1446},"Claude Code should find and list the warehouse connection you just set up.",{"type":46,"tag":198,"props":1448,"children":1449},{},[1450],{"type":46,"tag":55,"props":1451,"children":1452},{},[1453,1458,1460,1466,1468,1474],{"type":46,"tag":80,"props":1454,"children":1455},{},[1456],{"type":52,"value":1457},"Using Cursor or Codex instead?",{"type":52,"value":1459}," For Cursor, add ",{"type":46,"tag":99,"props":1461,"children":1463},{"className":1462},[],[1464],{"type":52,"value":1465},"{\"mcpServers\": {\"bruin\": {\"command\": \"bruin\", \"args\": [\"mcp\"]}}}",{"type":52,"value":1467}," to your MCP settings. For Codex, run ",{"type":46,"tag":99,"props":1469,"children":1471},{"className":1470},[],[1472],{"type":52,"value":1473},"codex mcp add bruin -- bruin mcp",{"type":52,"value":1475},". The rest of this tutorial shows Claude Code prompts, but they work in any MCP-compatible tool.",{"type":46,"tag":220,"props":1477,"children":1479},{"id":1478},"_6-validate-with-claude-code",[1480],{"type":52,"value":1481},"6) Validate with Claude Code",{"type":46,"tag":55,"props":1483,"children":1484},{},[1485],{"type":52,"value":1486},"You can run the validation yourself:",{"type":46,"tag":240,"props":1488,"children":1490},{"className":242,"code":1489,"language":244,"meta":7,"style":7},"bruin validate .\n",[1491],{"type":46,"tag":99,"props":1492,"children":1493},{"__ignoreMap":7},[1494],{"type":46,"tag":250,"props":1495,"children":1496},{"class":252,"line":23},[1497,1501,1506],{"type":46,"tag":250,"props":1498,"children":1499},{"style":256},[1500],{"type":52,"value":305},{"type":46,"tag":250,"props":1502,"children":1503},{"style":262},[1504],{"type":52,"value":1505}," validate",{"type":46,"tag":250,"props":1507,"children":1508},{"style":262},[1509],{"type":52,"value":1510}," .\n",{"type":46,"tag":55,"props":1512,"children":1513},{},[1514],{"type":52,"value":1515},"Or just ask Claude Code to do it:",{"type":46,"tag":1434,"props":1517,"children":1518},{},[1519],{"type":46,"tag":55,"props":1520,"children":1521},{},[1522],{"type":52,"value":1523},"Run bruin validate on this project and tell me if there are any issues.",{"type":46,"tag":55,"props":1525,"children":1526},{},[1527],{"type":52,"value":1528},"A clean validation means your project structure, pipeline config, and connections are all correct. From here on, you can use Claude Code to run any Bruin command, create files, and write SQL - we'll show you how at each step.",{"type":46,"tag":47,"props":1530,"children":1532},{"id":1531},"what-just-happened",[1533],{"type":52,"value":1534},"What just happened",{"type":46,"tag":55,"props":1536,"children":1537},{},[1538],{"type":52,"value":1539},"You have a Bruin project connected to your data warehouse with Claude Code and the Bruin MCP set up. Claude Code can now inspect your pipeline, query your data, fetch Bruin docs, and help you build assets. Next up, you'll use it to create ingestor assets that pull data from your Shopify store and surrounding tools into your warehouse.",{"type":46,"tag":1541,"props":1542,"children":1543},"style",{},[1544],{"type":52,"value":1545},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":7,"searchDepth":285,"depth":285,"links":1547},[1548,1549,1550,1551,1559],{"id":49,"depth":285,"text":53},{"id":62,"depth":285,"text":65},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":1552},[1553,1554,1555,1556,1557,1558],{"id":222,"depth":299,"text":225},{"id":338,"depth":299,"text":341},{"id":413,"depth":299,"text":416},{"id":1092,"depth":299,"text":1095},{"id":1368,"depth":299,"text":1371},{"id":1478,"depth":299,"text":1481},{"id":1531,"depth":285,"text":1534},"markdown","content:tutorials:ecommerce-pipeline:project-setup.md","content","tutorials\u002Fecommerce-pipeline\u002Fproject-setup.md","tutorials\u002Fecommerce-pipeline\u002Fproject-setup","md",{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"readingTime":11,"category":12,"tags":1567,"difficulty":21,"module":5,"subSteps":22,"step":23,"variants":1568,"journeys":1569,"learnMore":1570,"author":1574,"body":1575,"_type":1560,"_id":1561,"_source":1562,"_file":1563,"_stem":1564,"_extension":1565},[14,15,16,17,18,19,20],[17,18,19],[26,27],[1571,1572,1573],{"label":30,"url":31},{"label":33,"url":34},{"label":36,"url":37},{"name":39,"role":40,"image":41},{"type":43,"children":1576,"toc":2827},[1577,1581,1585,1589,1593,1636,1670,1674,1678,1682,1694,1698,1702,1712,1771,1775,1783,1787,1796,1821,1842,1846,1850,2425,2429,2439,2682,2686,2696,2733,2737,2744,2748,2771,2775,2779,2800,2804,2811,2815,2819,2823],{"type":46,"tag":47,"props":1578,"children":1579},{"id":49},[1580],{"type":52,"value":53},{"type":46,"tag":55,"props":1582,"children":1583},{},[1584],{"type":52,"value":59},{"type":46,"tag":47,"props":1586,"children":1587},{"id":62},[1588],{"type":52,"value":65},{"type":46,"tag":55,"props":1590,"children":1591},{},[1592],{"type":52,"value":70},{"type":46,"tag":72,"props":1594,"children":1595},{},[1596,1616],{"type":46,"tag":76,"props":1597,"children":1598},{},[1599,1603,1604,1609,1610,1615],{"type":46,"tag":80,"props":1600,"children":1601},{},[1602],{"type":52,"value":84},{"type":52,"value":86},{"type":46,"tag":88,"props":1605,"children":1607},{"href":90,"rel":1606},[92],[1608],{"type":52,"value":95},{"type":52,"value":97},{"type":46,"tag":99,"props":1611,"children":1613},{"className":1612},[],[1614],{"type":52,"value":104},{"type":52,"value":106},{"type":46,"tag":76,"props":1617,"children":1618},{},[1619,1623,1624,1629,1630,1635],{"type":46,"tag":80,"props":1620,"children":1621},{},[1622],{"type":52,"value":14},{"type":52,"value":115},{"type":46,"tag":88,"props":1625,"children":1627},{"href":118,"rel":1626},[92],[1628],{"type":52,"value":122},{"type":52,"value":97},{"type":46,"tag":99,"props":1631,"children":1633},{"className":1632},[],[1634],{"type":52,"value":129},{"type":52,"value":106},{"type":46,"tag":55,"props":1637,"children":1638},{},[1639,1640,1644,1645,1649,1650,1654,1655,1659,1660,1664,1665,1669],{"type":52,"value":135},{"type":46,"tag":88,"props":1641,"children":1642},{"href":138},[1643],{"type":52,"value":141},{"type":52,"value":143},{"type":46,"tag":88,"props":1646,"children":1647},{"href":146},[1648],{"type":52,"value":149},{"type":52,"value":151},{"type":46,"tag":88,"props":1651,"children":1652},{"href":154},[1653],{"type":52,"value":157},{"type":52,"value":151},{"type":46,"tag":88,"props":1656,"children":1657},{"href":161},[1658],{"type":52,"value":164},{"type":52,"value":151},{"type":46,"tag":88,"props":1661,"children":1662},{"href":168},[1663],{"type":52,"value":171},{"type":52,"value":173},{"type":46,"tag":88,"props":1666,"children":1667},{"href":176},[1668],{"type":52,"value":179},{"type":52,"value":106},{"type":46,"tag":47,"props":1671,"children":1672},{"id":183},[1673],{"type":52,"value":186},{"type":46,"tag":55,"props":1675,"children":1676},{},[1677],{"type":52,"value":191},{"type":46,"tag":55,"props":1679,"children":1680},{},[1681],{"type":52,"value":196},{"type":46,"tag":198,"props":1683,"children":1684},{},[1685],{"type":46,"tag":55,"props":1686,"children":1687},{},[1688,1689,1693],{"type":52,"value":205},{"type":46,"tag":88,"props":1690,"children":1691},{"href":208},[1692],{"type":52,"value":211},{"type":52,"value":106},{"type":46,"tag":47,"props":1695,"children":1696},{"id":215},[1697],{"type":52,"value":218},{"type":46,"tag":220,"props":1699,"children":1700},{"id":222},[1701],{"type":52,"value":225},{"type":46,"tag":55,"props":1703,"children":1704},{},[1705,1706,1711],{"type":52,"value":230},{"type":46,"tag":99,"props":1707,"children":1709},{"className":1708},[],[1710],{"type":52,"value":236},{"type":52,"value":238},{"type":46,"tag":240,"props":1713,"children":1714},{"className":242,"code":243,"language":244,"meta":7,"style":7},[1715],{"type":46,"tag":99,"props":1716,"children":1717},{"__ignoreMap":7},[1718,1741,1752],{"type":46,"tag":250,"props":1719,"children":1720},{"class":252,"line":23},[1721,1725,1729,1733,1737],{"type":46,"tag":250,"props":1722,"children":1723},{"style":256},[1724],{"type":52,"value":259},{"type":46,"tag":250,"props":1726,"children":1727},{"style":262},[1728],{"type":52,"value":265},{"type":46,"tag":250,"props":1730,"children":1731},{"style":268},[1732],{"type":52,"value":271},{"type":46,"tag":250,"props":1734,"children":1735},{"style":274},[1736],{"type":52,"value":277},{"type":46,"tag":250,"props":1738,"children":1739},{"style":262},[1740],{"type":52,"value":282},{"type":46,"tag":250,"props":1742,"children":1743},{"class":252,"line":285},[1744,1748],{"type":46,"tag":250,"props":1745,"children":1746},{"style":256},[1747],{"type":52,"value":291},{"type":46,"tag":250,"props":1749,"children":1750},{"style":262},[1751],{"type":52,"value":296},{"type":46,"tag":250,"props":1753,"children":1754},{"class":252,"line":299},[1755,1759,1763,1767],{"type":46,"tag":250,"props":1756,"children":1757},{"style":256},[1758],{"type":52,"value":305},{"type":46,"tag":250,"props":1760,"children":1761},{"style":262},[1762],{"type":52,"value":310},{"type":46,"tag":250,"props":1764,"children":1765},{"style":262},[1766],{"type":52,"value":315},{"type":46,"tag":250,"props":1768,"children":1769},{"style":262},[1770],{"type":52,"value":320},{"type":46,"tag":55,"props":1772,"children":1773},{},[1774],{"type":52,"value":325},{"type":46,"tag":240,"props":1776,"children":1778},{"className":1777,"code":330,"language":52},[329],[1779],{"type":46,"tag":99,"props":1780,"children":1781},{"__ignoreMap":7},[1782],{"type":52,"value":330},{"type":46,"tag":220,"props":1784,"children":1785},{"id":338},[1786],{"type":52,"value":341},{"type":46,"tag":55,"props":1788,"children":1789},{},[1790,1795],{"type":46,"tag":99,"props":1791,"children":1793},{"className":1792},[],[1794],{"type":52,"value":350},{"type":52,"value":352},{"type":46,"tag":240,"props":1797,"children":1798},{"className":242,"code":355,"language":244,"meta":7,"style":7},[1799],{"type":46,"tag":99,"props":1800,"children":1801},{"__ignoreMap":7},[1802],{"type":46,"tag":250,"props":1803,"children":1804},{"class":252,"line":23},[1805,1809,1813,1817],{"type":46,"tag":250,"props":1806,"children":1807},{"style":274},[1808],{"type":52,"value":367},{"type":46,"tag":250,"props":1810,"children":1811},{"style":262},[1812],{"type":52,"value":372},{"type":46,"tag":250,"props":1814,"children":1815},{"style":375},[1816],{"type":52,"value":378},{"type":46,"tag":250,"props":1818,"children":1819},{"style":262},[1820],{"type":52,"value":383},{"type":46,"tag":55,"props":1822,"children":1823},{},[1824,1829,1830,1835,1836,1841],{"type":46,"tag":99,"props":1825,"children":1827},{"className":1826},[],[1828],{"type":52,"value":236},{"type":52,"value":393},{"type":46,"tag":99,"props":1831,"children":1833},{"className":1832},[],[1834],{"type":52,"value":399},{"type":52,"value":401},{"type":46,"tag":88,"props":1837,"children":1839},{"href":404,"rel":1838},[92],[1840],{"type":52,"value":408},{"type":52,"value":410},{"type":46,"tag":220,"props":1843,"children":1844},{"id":413},[1845],{"type":52,"value":416},{"type":46,"tag":55,"props":1847,"children":1848},{},[1849],{"type":52,"value":421},{"type":46,"tag":423,"props":1851,"children":1852},{":variants":425,"group":426},[1853,1995,2278],{"type":46,"tag":429,"props":1854,"children":1855},{"v-slot:clickhouse":7},[1856,1860,1890,1911,1915,1952,1956,1985],{"type":46,"tag":220,"props":1857,"children":1858},{"id":434},[1859],{"type":52,"value":17},{"type":46,"tag":55,"props":1861,"children":1862},{},[1863,1864,1869,1870,1874,1875,1879,1880,1884,1885,1889],{"type":52,"value":441},{"type":46,"tag":88,"props":1865,"children":1867},{"href":444,"rel":1866},[92],[1868],{"type":52,"value":448},{"type":52,"value":450},{"type":46,"tag":80,"props":1871,"children":1872},{},[1873],{"type":52,"value":455},{"type":52,"value":151},{"type":46,"tag":80,"props":1876,"children":1877},{},[1878],{"type":52,"value":461},{"type":52,"value":151},{"type":46,"tag":80,"props":1881,"children":1882},{},[1883],{"type":52,"value":467},{"type":52,"value":173},{"type":46,"tag":80,"props":1886,"children":1887},{},[1888],{"type":52,"value":473},{"type":52,"value":106},{"type":46,"tag":240,"props":1891,"children":1892},{"className":242,"code":477,"language":244,"meta":7,"style":7},[1893],{"type":46,"tag":99,"props":1894,"children":1895},{"__ignoreMap":7},[1896],{"type":46,"tag":250,"props":1897,"children":1898},{"class":252,"line":23},[1899,1903,1907],{"type":46,"tag":250,"props":1900,"children":1901},{"style":256},[1902],{"type":52,"value":305},{"type":46,"tag":250,"props":1904,"children":1905},{"style":262},[1906],{"type":52,"value":493},{"type":46,"tag":250,"props":1908,"children":1909},{"style":262},[1910],{"type":52,"value":498},{"type":46,"tag":55,"props":1912,"children":1913},{},[1914],{"type":52,"value":503},{"type":46,"tag":72,"props":1916,"children":1917},{},[1918,1931,1944],{"type":46,"tag":76,"props":1919,"children":1920},{},[1921,1925,1926],{"type":46,"tag":80,"props":1922,"children":1923},{},[1924],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":1927,"children":1929},{"className":1928},[],[1930],{"type":52,"value":434},{"type":46,"tag":76,"props":1932,"children":1933},{},[1934,1938,1939],{"type":46,"tag":80,"props":1935,"children":1936},{},[1937],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":1940,"children":1942},{"className":1941},[],[1943],{"type":52,"value":536},{"type":46,"tag":76,"props":1945,"children":1946},{},[1947,1951],{"type":46,"tag":80,"props":1948,"children":1949},{},[1950],{"type":52,"value":544},{"type":52,"value":546},{"type":46,"tag":55,"props":1953,"children":1954},{},[1955],{"type":52,"value":551},{"type":46,"tag":240,"props":1957,"children":1958},{"className":242,"code":554,"language":244,"meta":7,"style":7},[1959],{"type":46,"tag":99,"props":1960,"children":1961},{"__ignoreMap":7},[1962],{"type":46,"tag":250,"props":1963,"children":1964},{"class":252,"line":23},[1965,1969,1973,1977,1981],{"type":46,"tag":250,"props":1966,"children":1967},{"style":256},[1968],{"type":52,"value":305},{"type":46,"tag":250,"props":1970,"children":1971},{"style":262},[1972],{"type":52,"value":493},{"type":46,"tag":250,"props":1974,"children":1975},{"style":262},[1976],{"type":52,"value":574},{"type":46,"tag":250,"props":1978,"children":1979},{"style":274},[1980],{"type":52,"value":579},{"type":46,"tag":250,"props":1982,"children":1983},{"style":262},[1984],{"type":52,"value":584},{"type":46,"tag":55,"props":1986,"children":1987},{},[1988,1989,1994],{"type":52,"value":589},{"type":46,"tag":88,"props":1990,"children":1992},{"href":592,"rel":1991},[92],[1993],{"type":52,"value":596},{"type":52,"value":106},{"type":46,"tag":429,"props":1996,"children":1997},{"v-slot:bigquery":7},[1998,2002,2009,2034,2038,2059,2063,2119,2126,2136,2235,2239,2268],{"type":46,"tag":220,"props":1999,"children":2000},{"id":603},[2001],{"type":52,"value":18},{"type":46,"tag":55,"props":2003,"children":2004},{},[2005],{"type":46,"tag":80,"props":2006,"children":2007},{},[2008],{"type":52,"value":613},{"type":46,"tag":240,"props":2010,"children":2011},{"className":242,"code":616,"language":244,"meta":7,"style":7},[2012],{"type":46,"tag":99,"props":2013,"children":2014},{"__ignoreMap":7},[2015],{"type":46,"tag":250,"props":2016,"children":2017},{"class":252,"line":23},[2018,2022,2026,2030],{"type":46,"tag":250,"props":2019,"children":2020},{"style":256},[2021],{"type":52,"value":628},{"type":46,"tag":250,"props":2023,"children":2024},{"style":262},[2025],{"type":52,"value":633},{"type":46,"tag":250,"props":2027,"children":2028},{"style":262},[2029],{"type":52,"value":638},{"type":46,"tag":250,"props":2031,"children":2032},{"style":262},[2033],{"type":52,"value":643},{"type":46,"tag":55,"props":2035,"children":2036},{},[2037],{"type":52,"value":648},{"type":46,"tag":240,"props":2039,"children":2040},{"className":242,"code":477,"language":244,"meta":7,"style":7},[2041],{"type":46,"tag":99,"props":2042,"children":2043},{"__ignoreMap":7},[2044],{"type":46,"tag":250,"props":2045,"children":2046},{"class":252,"line":23},[2047,2051,2055],{"type":46,"tag":250,"props":2048,"children":2049},{"style":256},[2050],{"type":52,"value":305},{"type":46,"tag":250,"props":2052,"children":2053},{"style":262},[2054],{"type":52,"value":493},{"type":46,"tag":250,"props":2056,"children":2057},{"style":262},[2058],{"type":52,"value":498},{"type":46,"tag":55,"props":2060,"children":2061},{},[2062],{"type":52,"value":503},{"type":46,"tag":72,"props":2064,"children":2065},{},[2066,2079,2092,2100],{"type":46,"tag":76,"props":2067,"children":2068},{},[2069,2073,2074],{"type":46,"tag":80,"props":2070,"children":2071},{},[2072],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":2075,"children":2077},{"className":2076},[],[2078],{"type":52,"value":690},{"type":46,"tag":76,"props":2080,"children":2081},{},[2082,2086,2087],{"type":46,"tag":80,"props":2083,"children":2084},{},[2085],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":2088,"children":2090},{"className":2089},[],[2091],{"type":52,"value":704},{"type":46,"tag":76,"props":2093,"children":2094},{},[2095,2099],{"type":46,"tag":80,"props":2096,"children":2097},{},[2098],{"type":52,"value":712},{"type":52,"value":714},{"type":46,"tag":76,"props":2101,"children":2102},{},[2103,2107,2108,2113,2114],{"type":46,"tag":80,"props":2104,"children":2105},{},[2106],{"type":52,"value":722},{"type":52,"value":516},{"type":46,"tag":99,"props":2109,"children":2111},{"className":2110},[],[2112],{"type":52,"value":729},{"type":52,"value":731},{"type":46,"tag":99,"props":2115,"children":2117},{"className":2116},[],[2118],{"type":52,"value":737},{"type":46,"tag":55,"props":2120,"children":2121},{},[2122],{"type":46,"tag":80,"props":2123,"children":2124},{},[2125],{"type":52,"value":745},{"type":46,"tag":55,"props":2127,"children":2128},{},[2129,2130,2135],{"type":52,"value":750},{"type":46,"tag":99,"props":2131,"children":2133},{"className":2132},[],[2134],{"type":52,"value":350},{"type":52,"value":757},{"type":46,"tag":240,"props":2137,"children":2138},{"className":760,"code":761,"language":762,"meta":7,"style":7},[2139],{"type":46,"tag":99,"props":2140,"children":2141},{"__ignoreMap":7},[2142,2153,2164,2175,2186,2205,2220],{"type":46,"tag":250,"props":2143,"children":2144},{"class":252,"line":23},[2145,2149],{"type":46,"tag":250,"props":2146,"children":2147},{"style":772},[2148],{"type":52,"value":775},{"type":46,"tag":250,"props":2150,"children":2151},{"style":268},[2152],{"type":52,"value":780},{"type":46,"tag":250,"props":2154,"children":2155},{"class":252,"line":285},[2156,2160],{"type":46,"tag":250,"props":2157,"children":2158},{"style":772},[2159],{"type":52,"value":788},{"type":46,"tag":250,"props":2161,"children":2162},{"style":268},[2163],{"type":52,"value":780},{"type":46,"tag":250,"props":2165,"children":2166},{"class":252,"line":299},[2167,2171],{"type":46,"tag":250,"props":2168,"children":2169},{"style":772},[2170],{"type":52,"value":800},{"type":46,"tag":250,"props":2172,"children":2173},{"style":268},[2174],{"type":52,"value":780},{"type":46,"tag":250,"props":2176,"children":2177},{"class":252,"line":807},[2178,2182],{"type":46,"tag":250,"props":2179,"children":2180},{"style":772},[2181],{"type":52,"value":813},{"type":46,"tag":250,"props":2183,"children":2184},{"style":268},[2185],{"type":52,"value":780},{"type":46,"tag":250,"props":2187,"children":2188},{"class":252,"line":820},[2189,2193,2197,2201],{"type":46,"tag":250,"props":2190,"children":2191},{"style":268},[2192],{"type":52,"value":826},{"type":46,"tag":250,"props":2194,"children":2195},{"style":772},[2196],{"type":52,"value":831},{"type":46,"tag":250,"props":2198,"children":2199},{"style":268},[2200],{"type":52,"value":836},{"type":46,"tag":250,"props":2202,"children":2203},{"style":262},[2204],{"type":52,"value":841},{"type":46,"tag":250,"props":2206,"children":2207},{"class":252,"line":844},[2208,2212,2216],{"type":46,"tag":250,"props":2209,"children":2210},{"style":772},[2211],{"type":52,"value":850},{"type":46,"tag":250,"props":2213,"children":2214},{"style":268},[2215],{"type":52,"value":836},{"type":46,"tag":250,"props":2217,"children":2218},{"style":262},[2219],{"type":52,"value":859},{"type":46,"tag":250,"props":2221,"children":2222},{"class":252,"line":862},[2223,2227,2231],{"type":46,"tag":250,"props":2224,"children":2225},{"style":772},[2226],{"type":52,"value":868},{"type":46,"tag":250,"props":2228,"children":2229},{"style":268},[2230],{"type":52,"value":836},{"type":46,"tag":250,"props":2232,"children":2233},{"style":262},[2234],{"type":52,"value":877},{"type":46,"tag":55,"props":2236,"children":2237},{},[2238],{"type":52,"value":551},{"type":46,"tag":240,"props":2240,"children":2241},{"className":242,"code":884,"language":244,"meta":7,"style":7},[2242],{"type":46,"tag":99,"props":2243,"children":2244},{"__ignoreMap":7},[2245],{"type":46,"tag":250,"props":2246,"children":2247},{"class":252,"line":23},[2248,2252,2256,2260,2264],{"type":46,"tag":250,"props":2249,"children":2250},{"style":256},[2251],{"type":52,"value":305},{"type":46,"tag":250,"props":2253,"children":2254},{"style":262},[2255],{"type":52,"value":493},{"type":46,"tag":250,"props":2257,"children":2258},{"style":262},[2259],{"type":52,"value":574},{"type":46,"tag":250,"props":2261,"children":2262},{"style":274},[2263],{"type":52,"value":579},{"type":46,"tag":250,"props":2265,"children":2266},{"style":262},[2267],{"type":52,"value":912},{"type":46,"tag":55,"props":2269,"children":2270},{},[2271,2272,2277],{"type":52,"value":589},{"type":46,"tag":88,"props":2273,"children":2275},{"href":919,"rel":2274},[92],[2276],{"type":52,"value":923},{"type":52,"value":106},{"type":46,"tag":429,"props":2279,"children":2280},{"v-slot:snowflake":7},[2281,2285,2306,2310,2382,2386,2415],{"type":46,"tag":220,"props":2282,"children":2283},{"id":930},[2284],{"type":52,"value":19},{"type":46,"tag":240,"props":2286,"children":2287},{"className":242,"code":477,"language":244,"meta":7,"style":7},[2288],{"type":46,"tag":99,"props":2289,"children":2290},{"__ignoreMap":7},[2291],{"type":46,"tag":250,"props":2292,"children":2293},{"class":252,"line":23},[2294,2298,2302],{"type":46,"tag":250,"props":2295,"children":2296},{"style":256},[2297],{"type":52,"value":305},{"type":46,"tag":250,"props":2299,"children":2300},{"style":262},[2301],{"type":52,"value":493},{"type":46,"tag":250,"props":2303,"children":2304},{"style":262},[2305],{"type":52,"value":498},{"type":46,"tag":55,"props":2307,"children":2308},{},[2309],{"type":52,"value":503},{"type":46,"tag":72,"props":2311,"children":2312},{},[2313,2326,2339,2353,2361,2369],{"type":46,"tag":76,"props":2314,"children":2315},{},[2316,2320,2321],{"type":46,"tag":80,"props":2317,"children":2318},{},[2319],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":2322,"children":2324},{"className":2323},[],[2325],{"type":52,"value":930},{"type":46,"tag":76,"props":2327,"children":2328},{},[2329,2333,2334],{"type":46,"tag":80,"props":2330,"children":2331},{},[2332],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":2335,"children":2337},{"className":2336},[],[2338],{"type":52,"value":987},{"type":46,"tag":76,"props":2340,"children":2341},{},[2342,2346,2347,2352],{"type":46,"tag":80,"props":2343,"children":2344},{},[2345],{"type":52,"value":995},{"type":52,"value":997},{"type":46,"tag":99,"props":2348,"children":2350},{"className":2349},[],[2351],{"type":52,"value":1003},{"type":52,"value":1005},{"type":46,"tag":76,"props":2354,"children":2355},{},[2356,2360],{"type":46,"tag":80,"props":2357,"children":2358},{},[2359],{"type":52,"value":1013},{"type":52,"value":1015},{"type":46,"tag":76,"props":2362,"children":2363},{},[2364,2368],{"type":46,"tag":80,"props":2365,"children":2366},{},[2367],{"type":52,"value":1023},{"type":52,"value":1025},{"type":46,"tag":76,"props":2370,"children":2371},{},[2372,2376,2377,2381],{"type":46,"tag":80,"props":2373,"children":2374},{},[2375],{"type":52,"value":1033},{"type":52,"value":516},{"type":46,"tag":1036,"props":2378,"children":2379},{},[2380],{"type":52,"value":1040},{"type":52,"value":1042},{"type":46,"tag":55,"props":2383,"children":2384},{},[2385],{"type":52,"value":551},{"type":46,"tag":240,"props":2387,"children":2388},{"className":242,"code":1049,"language":244,"meta":7,"style":7},[2389],{"type":46,"tag":99,"props":2390,"children":2391},{"__ignoreMap":7},[2392],{"type":46,"tag":250,"props":2393,"children":2394},{"class":252,"line":23},[2395,2399,2403,2407,2411],{"type":46,"tag":250,"props":2396,"children":2397},{"style":256},[2398],{"type":52,"value":305},{"type":46,"tag":250,"props":2400,"children":2401},{"style":262},[2402],{"type":52,"value":493},{"type":46,"tag":250,"props":2404,"children":2405},{"style":262},[2406],{"type":52,"value":574},{"type":46,"tag":250,"props":2408,"children":2409},{"style":274},[2410],{"type":52,"value":579},{"type":46,"tag":250,"props":2412,"children":2413},{"style":262},[2414],{"type":52,"value":1077},{"type":46,"tag":55,"props":2416,"children":2417},{},[2418,2419,2424],{"type":52,"value":589},{"type":46,"tag":88,"props":2420,"children":2422},{"href":1084,"rel":2421},[92],[2423],{"type":52,"value":1088},{"type":52,"value":106},{"type":46,"tag":220,"props":2426,"children":2427},{"id":1092},[2428],{"type":52,"value":1095},{"type":46,"tag":55,"props":2430,"children":2431},{},[2432,2433,2438],{"type":52,"value":750},{"type":46,"tag":99,"props":2434,"children":2436},{"className":2435},[],[2437],{"type":52,"value":1105},{"type":52,"value":1107},{"type":46,"tag":423,"props":2440,"children":2441},{":variants":425,"group":426},[2442,2522,2602],{"type":46,"tag":429,"props":2443,"children":2444},{"v-slot:clickhouse":7},[2445],{"type":46,"tag":240,"props":2446,"children":2447},{"className":760,"code":1116,"language":762,"meta":7,"style":7},[2448],{"type":46,"tag":99,"props":2449,"children":2450},{"__ignoreMap":7},[2451,2466,2481,2496,2507],{"type":46,"tag":250,"props":2452,"children":2453},{"class":252,"line":23},[2454,2458,2462],{"type":46,"tag":250,"props":2455,"children":2456},{"style":772},[2457],{"type":52,"value":831},{"type":46,"tag":250,"props":2459,"children":2460},{"style":268},[2461],{"type":52,"value":836},{"type":46,"tag":250,"props":2463,"children":2464},{"style":262},[2465],{"type":52,"value":1136},{"type":46,"tag":250,"props":2467,"children":2468},{"class":252,"line":285},[2469,2473,2477],{"type":46,"tag":250,"props":2470,"children":2471},{"style":772},[2472],{"type":52,"value":1144},{"type":46,"tag":250,"props":2474,"children":2475},{"style":268},[2476],{"type":52,"value":836},{"type":46,"tag":250,"props":2478,"children":2479},{"style":262},[2480],{"type":52,"value":1153},{"type":46,"tag":250,"props":2482,"children":2483},{"class":252,"line":299},[2484,2488,2492],{"type":46,"tag":250,"props":2485,"children":2486},{"style":772},[2487],{"type":52,"value":1161},{"type":46,"tag":250,"props":2489,"children":2490},{"style":268},[2491],{"type":52,"value":836},{"type":46,"tag":250,"props":2493,"children":2494},{"style":262},[2495],{"type":52,"value":1170},{"type":46,"tag":250,"props":2497,"children":2498},{"class":252,"line":807},[2499,2503],{"type":46,"tag":250,"props":2500,"children":2501},{"style":772},[2502],{"type":52,"value":1178},{"type":46,"tag":250,"props":2504,"children":2505},{"style":268},[2506],{"type":52,"value":780},{"type":46,"tag":250,"props":2508,"children":2509},{"class":252,"line":820},[2510,2514,2518],{"type":46,"tag":250,"props":2511,"children":2512},{"style":772},[2513],{"type":52,"value":1190},{"type":46,"tag":250,"props":2515,"children":2516},{"style":268},[2517],{"type":52,"value":836},{"type":46,"tag":250,"props":2519,"children":2520},{"style":262},[2521],{"type":52,"value":1199},{"type":46,"tag":429,"props":2523,"children":2524},{"v-slot:bigquery":7},[2525],{"type":46,"tag":240,"props":2526,"children":2527},{"className":760,"code":1205,"language":762,"meta":7,"style":7},[2528],{"type":46,"tag":99,"props":2529,"children":2530},{"__ignoreMap":7},[2531,2546,2561,2576,2587],{"type":46,"tag":250,"props":2532,"children":2533},{"class":252,"line":23},[2534,2538,2542],{"type":46,"tag":250,"props":2535,"children":2536},{"style":772},[2537],{"type":52,"value":831},{"type":46,"tag":250,"props":2539,"children":2540},{"style":268},[2541],{"type":52,"value":836},{"type":46,"tag":250,"props":2543,"children":2544},{"style":262},[2545],{"type":52,"value":1136},{"type":46,"tag":250,"props":2547,"children":2548},{"class":252,"line":285},[2549,2553,2557],{"type":46,"tag":250,"props":2550,"children":2551},{"style":772},[2552],{"type":52,"value":1144},{"type":46,"tag":250,"props":2554,"children":2555},{"style":268},[2556],{"type":52,"value":836},{"type":46,"tag":250,"props":2558,"children":2559},{"style":262},[2560],{"type":52,"value":1153},{"type":46,"tag":250,"props":2562,"children":2563},{"class":252,"line":299},[2564,2568,2572],{"type":46,"tag":250,"props":2565,"children":2566},{"style":772},[2567],{"type":52,"value":1161},{"type":46,"tag":250,"props":2569,"children":2570},{"style":268},[2571],{"type":52,"value":836},{"type":46,"tag":250,"props":2573,"children":2574},{"style":262},[2575],{"type":52,"value":1170},{"type":46,"tag":250,"props":2577,"children":2578},{"class":252,"line":807},[2579,2583],{"type":46,"tag":250,"props":2580,"children":2581},{"style":772},[2582],{"type":52,"value":1178},{"type":46,"tag":250,"props":2584,"children":2585},{"style":268},[2586],{"type":52,"value":780},{"type":46,"tag":250,"props":2588,"children":2589},{"class":252,"line":820},[2590,2594,2598],{"type":46,"tag":250,"props":2591,"children":2592},{"style":772},[2593],{"type":52,"value":1273},{"type":46,"tag":250,"props":2595,"children":2596},{"style":268},[2597],{"type":52,"value":836},{"type":46,"tag":250,"props":2599,"children":2600},{"style":262},[2601],{"type":52,"value":1282},{"type":46,"tag":429,"props":2603,"children":2604},{"v-slot:snowflake":7},[2605],{"type":46,"tag":240,"props":2606,"children":2607},{"className":760,"code":1288,"language":762,"meta":7,"style":7},[2608],{"type":46,"tag":99,"props":2609,"children":2610},{"__ignoreMap":7},[2611,2626,2641,2656,2667],{"type":46,"tag":250,"props":2612,"children":2613},{"class":252,"line":23},[2614,2618,2622],{"type":46,"tag":250,"props":2615,"children":2616},{"style":772},[2617],{"type":52,"value":831},{"type":46,"tag":250,"props":2619,"children":2620},{"style":268},[2621],{"type":52,"value":836},{"type":46,"tag":250,"props":2623,"children":2624},{"style":262},[2625],{"type":52,"value":1136},{"type":46,"tag":250,"props":2627,"children":2628},{"class":252,"line":285},[2629,2633,2637],{"type":46,"tag":250,"props":2630,"children":2631},{"style":772},[2632],{"type":52,"value":1144},{"type":46,"tag":250,"props":2634,"children":2635},{"style":268},[2636],{"type":52,"value":836},{"type":46,"tag":250,"props":2638,"children":2639},{"style":262},[2640],{"type":52,"value":1153},{"type":46,"tag":250,"props":2642,"children":2643},{"class":252,"line":299},[2644,2648,2652],{"type":46,"tag":250,"props":2645,"children":2646},{"style":772},[2647],{"type":52,"value":1161},{"type":46,"tag":250,"props":2649,"children":2650},{"style":268},[2651],{"type":52,"value":836},{"type":46,"tag":250,"props":2653,"children":2654},{"style":262},[2655],{"type":52,"value":1170},{"type":46,"tag":250,"props":2657,"children":2658},{"class":252,"line":807},[2659,2663],{"type":46,"tag":250,"props":2660,"children":2661},{"style":772},[2662],{"type":52,"value":1178},{"type":46,"tag":250,"props":2664,"children":2665},{"style":268},[2666],{"type":52,"value":780},{"type":46,"tag":250,"props":2668,"children":2669},{"class":252,"line":820},[2670,2674,2678],{"type":46,"tag":250,"props":2671,"children":2672},{"style":772},[2673],{"type":52,"value":1356},{"type":46,"tag":250,"props":2675,"children":2676},{"style":268},[2677],{"type":52,"value":836},{"type":46,"tag":250,"props":2679,"children":2680},{"style":262},[2681],{"type":52,"value":1365},{"type":46,"tag":220,"props":2683,"children":2684},{"id":1368},[2685],{"type":52,"value":1371},{"type":46,"tag":55,"props":2687,"children":2688},{},[2689,2690,2695],{"type":52,"value":1376},{"type":46,"tag":99,"props":2691,"children":2693},{"className":2692},[],[2694],{"type":52,"value":305},{"type":52,"value":1383},{"type":46,"tag":240,"props":2697,"children":2698},{"className":242,"code":1386,"language":244,"meta":7,"style":7},[2699],{"type":46,"tag":99,"props":2700,"children":2701},{"__ignoreMap":7},[2702],{"type":46,"tag":250,"props":2703,"children":2704},{"class":252,"line":23},[2705,2709,2713,2717,2721,2725,2729],{"type":46,"tag":250,"props":2706,"children":2707},{"style":256},[2708],{"type":52,"value":1398},{"type":46,"tag":250,"props":2710,"children":2711},{"style":262},[2712],{"type":52,"value":1403},{"type":46,"tag":250,"props":2714,"children":2715},{"style":262},[2716],{"type":52,"value":1408},{"type":46,"tag":250,"props":2718,"children":2719},{"style":262},[2720],{"type":52,"value":1413},{"type":46,"tag":250,"props":2722,"children":2723},{"style":274},[2724],{"type":52,"value":1418},{"type":46,"tag":250,"props":2726,"children":2727},{"style":262},[2728],{"type":52,"value":1413},{"type":46,"tag":250,"props":2730,"children":2731},{"style":262},[2732],{"type":52,"value":1427},{"type":46,"tag":55,"props":2734,"children":2735},{},[2736],{"type":52,"value":1432},{"type":46,"tag":1434,"props":2738,"children":2739},{},[2740],{"type":46,"tag":55,"props":2741,"children":2742},{},[2743],{"type":52,"value":1441},{"type":46,"tag":55,"props":2745,"children":2746},{},[2747],{"type":52,"value":1446},{"type":46,"tag":198,"props":2749,"children":2750},{},[2751],{"type":46,"tag":55,"props":2752,"children":2753},{},[2754,2758,2759,2764,2765,2770],{"type":46,"tag":80,"props":2755,"children":2756},{},[2757],{"type":52,"value":1457},{"type":52,"value":1459},{"type":46,"tag":99,"props":2760,"children":2762},{"className":2761},[],[2763],{"type":52,"value":1465},{"type":52,"value":1467},{"type":46,"tag":99,"props":2766,"children":2768},{"className":2767},[],[2769],{"type":52,"value":1473},{"type":52,"value":1475},{"type":46,"tag":220,"props":2772,"children":2773},{"id":1478},[2774],{"type":52,"value":1481},{"type":46,"tag":55,"props":2776,"children":2777},{},[2778],{"type":52,"value":1486},{"type":46,"tag":240,"props":2780,"children":2781},{"className":242,"code":1489,"language":244,"meta":7,"style":7},[2782],{"type":46,"tag":99,"props":2783,"children":2784},{"__ignoreMap":7},[2785],{"type":46,"tag":250,"props":2786,"children":2787},{"class":252,"line":23},[2788,2792,2796],{"type":46,"tag":250,"props":2789,"children":2790},{"style":256},[2791],{"type":52,"value":305},{"type":46,"tag":250,"props":2793,"children":2794},{"style":262},[2795],{"type":52,"value":1505},{"type":46,"tag":250,"props":2797,"children":2798},{"style":262},[2799],{"type":52,"value":1510},{"type":46,"tag":55,"props":2801,"children":2802},{},[2803],{"type":52,"value":1515},{"type":46,"tag":1434,"props":2805,"children":2806},{},[2807],{"type":46,"tag":55,"props":2808,"children":2809},{},[2810],{"type":52,"value":1523},{"type":46,"tag":55,"props":2812,"children":2813},{},[2814],{"type":52,"value":1528},{"type":46,"tag":47,"props":2816,"children":2817},{"id":1531},[2818],{"type":52,"value":1534},{"type":46,"tag":55,"props":2820,"children":2821},{},[2822],{"type":52,"value":1539},{"type":46,"tag":1541,"props":2824,"children":2825},{},[2826],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":2828},[2829,2830,2831,2832,2840],{"id":49,"depth":285,"text":53},{"id":62,"depth":285,"text":65},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":2833},[2834,2835,2836,2837,2838,2839],{"id":222,"depth":299,"text":225},{"id":338,"depth":299,"text":341},{"id":413,"depth":299,"text":416},{"id":1092,"depth":299,"text":1095},{"id":1368,"depth":299,"text":1371},{"id":1478,"depth":299,"text":1481},{"id":1531,"depth":285,"text":1534},[2842,4117,8782,16778,30084,32037],{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"readingTime":11,"category":12,"tags":2843,"difficulty":21,"module":5,"subSteps":22,"step":23,"variants":2844,"journeys":2845,"learnMore":2846,"author":2850,"body":2851,"_type":1560,"_id":1561,"_source":1562,"_file":1563,"_stem":1564,"_extension":1565},[14,15,16,17,18,19,20],[17,18,19],[26,27],[2847,2848,2849],{"label":30,"url":31},{"label":33,"url":34},{"label":36,"url":37},{"name":39,"role":40,"image":41},{"type":43,"children":2852,"toc":4103},[2853,2857,2861,2865,2869,2912,2946,2950,2954,2958,2970,2974,2978,2988,3047,3051,3059,3063,3072,3097,3118,3122,3126,3701,3705,3715,3958,3962,3972,4009,4013,4020,4024,4047,4051,4055,4076,4080,4087,4091,4095,4099],{"type":46,"tag":47,"props":2854,"children":2855},{"id":49},[2856],{"type":52,"value":53},{"type":46,"tag":55,"props":2858,"children":2859},{},[2860],{"type":52,"value":59},{"type":46,"tag":47,"props":2862,"children":2863},{"id":62},[2864],{"type":52,"value":65},{"type":46,"tag":55,"props":2866,"children":2867},{},[2868],{"type":52,"value":70},{"type":46,"tag":72,"props":2870,"children":2871},{},[2872,2892],{"type":46,"tag":76,"props":2873,"children":2874},{},[2875,2879,2880,2885,2886,2891],{"type":46,"tag":80,"props":2876,"children":2877},{},[2878],{"type":52,"value":84},{"type":52,"value":86},{"type":46,"tag":88,"props":2881,"children":2883},{"href":90,"rel":2882},[92],[2884],{"type":52,"value":95},{"type":52,"value":97},{"type":46,"tag":99,"props":2887,"children":2889},{"className":2888},[],[2890],{"type":52,"value":104},{"type":52,"value":106},{"type":46,"tag":76,"props":2893,"children":2894},{},[2895,2899,2900,2905,2906,2911],{"type":46,"tag":80,"props":2896,"children":2897},{},[2898],{"type":52,"value":14},{"type":52,"value":115},{"type":46,"tag":88,"props":2901,"children":2903},{"href":118,"rel":2902},[92],[2904],{"type":52,"value":122},{"type":52,"value":97},{"type":46,"tag":99,"props":2907,"children":2909},{"className":2908},[],[2910],{"type":52,"value":129},{"type":52,"value":106},{"type":46,"tag":55,"props":2913,"children":2914},{},[2915,2916,2920,2921,2925,2926,2930,2931,2935,2936,2940,2941,2945],{"type":52,"value":135},{"type":46,"tag":88,"props":2917,"children":2918},{"href":138},[2919],{"type":52,"value":141},{"type":52,"value":143},{"type":46,"tag":88,"props":2922,"children":2923},{"href":146},[2924],{"type":52,"value":149},{"type":52,"value":151},{"type":46,"tag":88,"props":2927,"children":2928},{"href":154},[2929],{"type":52,"value":157},{"type":52,"value":151},{"type":46,"tag":88,"props":2932,"children":2933},{"href":161},[2934],{"type":52,"value":164},{"type":52,"value":151},{"type":46,"tag":88,"props":2937,"children":2938},{"href":168},[2939],{"type":52,"value":171},{"type":52,"value":173},{"type":46,"tag":88,"props":2942,"children":2943},{"href":176},[2944],{"type":52,"value":179},{"type":52,"value":106},{"type":46,"tag":47,"props":2947,"children":2948},{"id":183},[2949],{"type":52,"value":186},{"type":46,"tag":55,"props":2951,"children":2952},{},[2953],{"type":52,"value":191},{"type":46,"tag":55,"props":2955,"children":2956},{},[2957],{"type":52,"value":196},{"type":46,"tag":198,"props":2959,"children":2960},{},[2961],{"type":46,"tag":55,"props":2962,"children":2963},{},[2964,2965,2969],{"type":52,"value":205},{"type":46,"tag":88,"props":2966,"children":2967},{"href":208},[2968],{"type":52,"value":211},{"type":52,"value":106},{"type":46,"tag":47,"props":2971,"children":2972},{"id":215},[2973],{"type":52,"value":218},{"type":46,"tag":220,"props":2975,"children":2976},{"id":222},[2977],{"type":52,"value":225},{"type":46,"tag":55,"props":2979,"children":2980},{},[2981,2982,2987],{"type":52,"value":230},{"type":46,"tag":99,"props":2983,"children":2985},{"className":2984},[],[2986],{"type":52,"value":236},{"type":52,"value":238},{"type":46,"tag":240,"props":2989,"children":2990},{"className":242,"code":243,"language":244,"meta":7,"style":7},[2991],{"type":46,"tag":99,"props":2992,"children":2993},{"__ignoreMap":7},[2994,3017,3028],{"type":46,"tag":250,"props":2995,"children":2996},{"class":252,"line":23},[2997,3001,3005,3009,3013],{"type":46,"tag":250,"props":2998,"children":2999},{"style":256},[3000],{"type":52,"value":259},{"type":46,"tag":250,"props":3002,"children":3003},{"style":262},[3004],{"type":52,"value":265},{"type":46,"tag":250,"props":3006,"children":3007},{"style":268},[3008],{"type":52,"value":271},{"type":46,"tag":250,"props":3010,"children":3011},{"style":274},[3012],{"type":52,"value":277},{"type":46,"tag":250,"props":3014,"children":3015},{"style":262},[3016],{"type":52,"value":282},{"type":46,"tag":250,"props":3018,"children":3019},{"class":252,"line":285},[3020,3024],{"type":46,"tag":250,"props":3021,"children":3022},{"style":256},[3023],{"type":52,"value":291},{"type":46,"tag":250,"props":3025,"children":3026},{"style":262},[3027],{"type":52,"value":296},{"type":46,"tag":250,"props":3029,"children":3030},{"class":252,"line":299},[3031,3035,3039,3043],{"type":46,"tag":250,"props":3032,"children":3033},{"style":256},[3034],{"type":52,"value":305},{"type":46,"tag":250,"props":3036,"children":3037},{"style":262},[3038],{"type":52,"value":310},{"type":46,"tag":250,"props":3040,"children":3041},{"style":262},[3042],{"type":52,"value":315},{"type":46,"tag":250,"props":3044,"children":3045},{"style":262},[3046],{"type":52,"value":320},{"type":46,"tag":55,"props":3048,"children":3049},{},[3050],{"type":52,"value":325},{"type":46,"tag":240,"props":3052,"children":3054},{"className":3053,"code":330,"language":52},[329],[3055],{"type":46,"tag":99,"props":3056,"children":3057},{"__ignoreMap":7},[3058],{"type":52,"value":330},{"type":46,"tag":220,"props":3060,"children":3061},{"id":338},[3062],{"type":52,"value":341},{"type":46,"tag":55,"props":3064,"children":3065},{},[3066,3071],{"type":46,"tag":99,"props":3067,"children":3069},{"className":3068},[],[3070],{"type":52,"value":350},{"type":52,"value":352},{"type":46,"tag":240,"props":3073,"children":3074},{"className":242,"code":355,"language":244,"meta":7,"style":7},[3075],{"type":46,"tag":99,"props":3076,"children":3077},{"__ignoreMap":7},[3078],{"type":46,"tag":250,"props":3079,"children":3080},{"class":252,"line":23},[3081,3085,3089,3093],{"type":46,"tag":250,"props":3082,"children":3083},{"style":274},[3084],{"type":52,"value":367},{"type":46,"tag":250,"props":3086,"children":3087},{"style":262},[3088],{"type":52,"value":372},{"type":46,"tag":250,"props":3090,"children":3091},{"style":375},[3092],{"type":52,"value":378},{"type":46,"tag":250,"props":3094,"children":3095},{"style":262},[3096],{"type":52,"value":383},{"type":46,"tag":55,"props":3098,"children":3099},{},[3100,3105,3106,3111,3112,3117],{"type":46,"tag":99,"props":3101,"children":3103},{"className":3102},[],[3104],{"type":52,"value":236},{"type":52,"value":393},{"type":46,"tag":99,"props":3107,"children":3109},{"className":3108},[],[3110],{"type":52,"value":399},{"type":52,"value":401},{"type":46,"tag":88,"props":3113,"children":3115},{"href":404,"rel":3114},[92],[3116],{"type":52,"value":408},{"type":52,"value":410},{"type":46,"tag":220,"props":3119,"children":3120},{"id":413},[3121],{"type":52,"value":416},{"type":46,"tag":55,"props":3123,"children":3124},{},[3125],{"type":52,"value":421},{"type":46,"tag":423,"props":3127,"children":3128},{":variants":425,"group":426},[3129,3271,3554],{"type":46,"tag":429,"props":3130,"children":3131},{"v-slot:clickhouse":7},[3132,3136,3166,3187,3191,3228,3232,3261],{"type":46,"tag":220,"props":3133,"children":3134},{"id":434},[3135],{"type":52,"value":17},{"type":46,"tag":55,"props":3137,"children":3138},{},[3139,3140,3145,3146,3150,3151,3155,3156,3160,3161,3165],{"type":52,"value":441},{"type":46,"tag":88,"props":3141,"children":3143},{"href":444,"rel":3142},[92],[3144],{"type":52,"value":448},{"type":52,"value":450},{"type":46,"tag":80,"props":3147,"children":3148},{},[3149],{"type":52,"value":455},{"type":52,"value":151},{"type":46,"tag":80,"props":3152,"children":3153},{},[3154],{"type":52,"value":461},{"type":52,"value":151},{"type":46,"tag":80,"props":3157,"children":3158},{},[3159],{"type":52,"value":467},{"type":52,"value":173},{"type":46,"tag":80,"props":3162,"children":3163},{},[3164],{"type":52,"value":473},{"type":52,"value":106},{"type":46,"tag":240,"props":3167,"children":3168},{"className":242,"code":477,"language":244,"meta":7,"style":7},[3169],{"type":46,"tag":99,"props":3170,"children":3171},{"__ignoreMap":7},[3172],{"type":46,"tag":250,"props":3173,"children":3174},{"class":252,"line":23},[3175,3179,3183],{"type":46,"tag":250,"props":3176,"children":3177},{"style":256},[3178],{"type":52,"value":305},{"type":46,"tag":250,"props":3180,"children":3181},{"style":262},[3182],{"type":52,"value":493},{"type":46,"tag":250,"props":3184,"children":3185},{"style":262},[3186],{"type":52,"value":498},{"type":46,"tag":55,"props":3188,"children":3189},{},[3190],{"type":52,"value":503},{"type":46,"tag":72,"props":3192,"children":3193},{},[3194,3207,3220],{"type":46,"tag":76,"props":3195,"children":3196},{},[3197,3201,3202],{"type":46,"tag":80,"props":3198,"children":3199},{},[3200],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":3203,"children":3205},{"className":3204},[],[3206],{"type":52,"value":434},{"type":46,"tag":76,"props":3208,"children":3209},{},[3210,3214,3215],{"type":46,"tag":80,"props":3211,"children":3212},{},[3213],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":3216,"children":3218},{"className":3217},[],[3219],{"type":52,"value":536},{"type":46,"tag":76,"props":3221,"children":3222},{},[3223,3227],{"type":46,"tag":80,"props":3224,"children":3225},{},[3226],{"type":52,"value":544},{"type":52,"value":546},{"type":46,"tag":55,"props":3229,"children":3230},{},[3231],{"type":52,"value":551},{"type":46,"tag":240,"props":3233,"children":3234},{"className":242,"code":554,"language":244,"meta":7,"style":7},[3235],{"type":46,"tag":99,"props":3236,"children":3237},{"__ignoreMap":7},[3238],{"type":46,"tag":250,"props":3239,"children":3240},{"class":252,"line":23},[3241,3245,3249,3253,3257],{"type":46,"tag":250,"props":3242,"children":3243},{"style":256},[3244],{"type":52,"value":305},{"type":46,"tag":250,"props":3246,"children":3247},{"style":262},[3248],{"type":52,"value":493},{"type":46,"tag":250,"props":3250,"children":3251},{"style":262},[3252],{"type":52,"value":574},{"type":46,"tag":250,"props":3254,"children":3255},{"style":274},[3256],{"type":52,"value":579},{"type":46,"tag":250,"props":3258,"children":3259},{"style":262},[3260],{"type":52,"value":584},{"type":46,"tag":55,"props":3262,"children":3263},{},[3264,3265,3270],{"type":52,"value":589},{"type":46,"tag":88,"props":3266,"children":3268},{"href":592,"rel":3267},[92],[3269],{"type":52,"value":596},{"type":52,"value":106},{"type":46,"tag":429,"props":3272,"children":3273},{"v-slot:bigquery":7},[3274,3278,3285,3310,3314,3335,3339,3395,3402,3412,3511,3515,3544],{"type":46,"tag":220,"props":3275,"children":3276},{"id":603},[3277],{"type":52,"value":18},{"type":46,"tag":55,"props":3279,"children":3280},{},[3281],{"type":46,"tag":80,"props":3282,"children":3283},{},[3284],{"type":52,"value":613},{"type":46,"tag":240,"props":3286,"children":3287},{"className":242,"code":616,"language":244,"meta":7,"style":7},[3288],{"type":46,"tag":99,"props":3289,"children":3290},{"__ignoreMap":7},[3291],{"type":46,"tag":250,"props":3292,"children":3293},{"class":252,"line":23},[3294,3298,3302,3306],{"type":46,"tag":250,"props":3295,"children":3296},{"style":256},[3297],{"type":52,"value":628},{"type":46,"tag":250,"props":3299,"children":3300},{"style":262},[3301],{"type":52,"value":633},{"type":46,"tag":250,"props":3303,"children":3304},{"style":262},[3305],{"type":52,"value":638},{"type":46,"tag":250,"props":3307,"children":3308},{"style":262},[3309],{"type":52,"value":643},{"type":46,"tag":55,"props":3311,"children":3312},{},[3313],{"type":52,"value":648},{"type":46,"tag":240,"props":3315,"children":3316},{"className":242,"code":477,"language":244,"meta":7,"style":7},[3317],{"type":46,"tag":99,"props":3318,"children":3319},{"__ignoreMap":7},[3320],{"type":46,"tag":250,"props":3321,"children":3322},{"class":252,"line":23},[3323,3327,3331],{"type":46,"tag":250,"props":3324,"children":3325},{"style":256},[3326],{"type":52,"value":305},{"type":46,"tag":250,"props":3328,"children":3329},{"style":262},[3330],{"type":52,"value":493},{"type":46,"tag":250,"props":3332,"children":3333},{"style":262},[3334],{"type":52,"value":498},{"type":46,"tag":55,"props":3336,"children":3337},{},[3338],{"type":52,"value":503},{"type":46,"tag":72,"props":3340,"children":3341},{},[3342,3355,3368,3376],{"type":46,"tag":76,"props":3343,"children":3344},{},[3345,3349,3350],{"type":46,"tag":80,"props":3346,"children":3347},{},[3348],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":3351,"children":3353},{"className":3352},[],[3354],{"type":52,"value":690},{"type":46,"tag":76,"props":3356,"children":3357},{},[3358,3362,3363],{"type":46,"tag":80,"props":3359,"children":3360},{},[3361],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":3364,"children":3366},{"className":3365},[],[3367],{"type":52,"value":704},{"type":46,"tag":76,"props":3369,"children":3370},{},[3371,3375],{"type":46,"tag":80,"props":3372,"children":3373},{},[3374],{"type":52,"value":712},{"type":52,"value":714},{"type":46,"tag":76,"props":3377,"children":3378},{},[3379,3383,3384,3389,3390],{"type":46,"tag":80,"props":3380,"children":3381},{},[3382],{"type":52,"value":722},{"type":52,"value":516},{"type":46,"tag":99,"props":3385,"children":3387},{"className":3386},[],[3388],{"type":52,"value":729},{"type":52,"value":731},{"type":46,"tag":99,"props":3391,"children":3393},{"className":3392},[],[3394],{"type":52,"value":737},{"type":46,"tag":55,"props":3396,"children":3397},{},[3398],{"type":46,"tag":80,"props":3399,"children":3400},{},[3401],{"type":52,"value":745},{"type":46,"tag":55,"props":3403,"children":3404},{},[3405,3406,3411],{"type":52,"value":750},{"type":46,"tag":99,"props":3407,"children":3409},{"className":3408},[],[3410],{"type":52,"value":350},{"type":52,"value":757},{"type":46,"tag":240,"props":3413,"children":3414},{"className":760,"code":761,"language":762,"meta":7,"style":7},[3415],{"type":46,"tag":99,"props":3416,"children":3417},{"__ignoreMap":7},[3418,3429,3440,3451,3462,3481,3496],{"type":46,"tag":250,"props":3419,"children":3420},{"class":252,"line":23},[3421,3425],{"type":46,"tag":250,"props":3422,"children":3423},{"style":772},[3424],{"type":52,"value":775},{"type":46,"tag":250,"props":3426,"children":3427},{"style":268},[3428],{"type":52,"value":780},{"type":46,"tag":250,"props":3430,"children":3431},{"class":252,"line":285},[3432,3436],{"type":46,"tag":250,"props":3433,"children":3434},{"style":772},[3435],{"type":52,"value":788},{"type":46,"tag":250,"props":3437,"children":3438},{"style":268},[3439],{"type":52,"value":780},{"type":46,"tag":250,"props":3441,"children":3442},{"class":252,"line":299},[3443,3447],{"type":46,"tag":250,"props":3444,"children":3445},{"style":772},[3446],{"type":52,"value":800},{"type":46,"tag":250,"props":3448,"children":3449},{"style":268},[3450],{"type":52,"value":780},{"type":46,"tag":250,"props":3452,"children":3453},{"class":252,"line":807},[3454,3458],{"type":46,"tag":250,"props":3455,"children":3456},{"style":772},[3457],{"type":52,"value":813},{"type":46,"tag":250,"props":3459,"children":3460},{"style":268},[3461],{"type":52,"value":780},{"type":46,"tag":250,"props":3463,"children":3464},{"class":252,"line":820},[3465,3469,3473,3477],{"type":46,"tag":250,"props":3466,"children":3467},{"style":268},[3468],{"type":52,"value":826},{"type":46,"tag":250,"props":3470,"children":3471},{"style":772},[3472],{"type":52,"value":831},{"type":46,"tag":250,"props":3474,"children":3475},{"style":268},[3476],{"type":52,"value":836},{"type":46,"tag":250,"props":3478,"children":3479},{"style":262},[3480],{"type":52,"value":841},{"type":46,"tag":250,"props":3482,"children":3483},{"class":252,"line":844},[3484,3488,3492],{"type":46,"tag":250,"props":3485,"children":3486},{"style":772},[3487],{"type":52,"value":850},{"type":46,"tag":250,"props":3489,"children":3490},{"style":268},[3491],{"type":52,"value":836},{"type":46,"tag":250,"props":3493,"children":3494},{"style":262},[3495],{"type":52,"value":859},{"type":46,"tag":250,"props":3497,"children":3498},{"class":252,"line":862},[3499,3503,3507],{"type":46,"tag":250,"props":3500,"children":3501},{"style":772},[3502],{"type":52,"value":868},{"type":46,"tag":250,"props":3504,"children":3505},{"style":268},[3506],{"type":52,"value":836},{"type":46,"tag":250,"props":3508,"children":3509},{"style":262},[3510],{"type":52,"value":877},{"type":46,"tag":55,"props":3512,"children":3513},{},[3514],{"type":52,"value":551},{"type":46,"tag":240,"props":3516,"children":3517},{"className":242,"code":884,"language":244,"meta":7,"style":7},[3518],{"type":46,"tag":99,"props":3519,"children":3520},{"__ignoreMap":7},[3521],{"type":46,"tag":250,"props":3522,"children":3523},{"class":252,"line":23},[3524,3528,3532,3536,3540],{"type":46,"tag":250,"props":3525,"children":3526},{"style":256},[3527],{"type":52,"value":305},{"type":46,"tag":250,"props":3529,"children":3530},{"style":262},[3531],{"type":52,"value":493},{"type":46,"tag":250,"props":3533,"children":3534},{"style":262},[3535],{"type":52,"value":574},{"type":46,"tag":250,"props":3537,"children":3538},{"style":274},[3539],{"type":52,"value":579},{"type":46,"tag":250,"props":3541,"children":3542},{"style":262},[3543],{"type":52,"value":912},{"type":46,"tag":55,"props":3545,"children":3546},{},[3547,3548,3553],{"type":52,"value":589},{"type":46,"tag":88,"props":3549,"children":3551},{"href":919,"rel":3550},[92],[3552],{"type":52,"value":923},{"type":52,"value":106},{"type":46,"tag":429,"props":3555,"children":3556},{"v-slot:snowflake":7},[3557,3561,3582,3586,3658,3662,3691],{"type":46,"tag":220,"props":3558,"children":3559},{"id":930},[3560],{"type":52,"value":19},{"type":46,"tag":240,"props":3562,"children":3563},{"className":242,"code":477,"language":244,"meta":7,"style":7},[3564],{"type":46,"tag":99,"props":3565,"children":3566},{"__ignoreMap":7},[3567],{"type":46,"tag":250,"props":3568,"children":3569},{"class":252,"line":23},[3570,3574,3578],{"type":46,"tag":250,"props":3571,"children":3572},{"style":256},[3573],{"type":52,"value":305},{"type":46,"tag":250,"props":3575,"children":3576},{"style":262},[3577],{"type":52,"value":493},{"type":46,"tag":250,"props":3579,"children":3580},{"style":262},[3581],{"type":52,"value":498},{"type":46,"tag":55,"props":3583,"children":3584},{},[3585],{"type":52,"value":503},{"type":46,"tag":72,"props":3587,"children":3588},{},[3589,3602,3615,3629,3637,3645],{"type":46,"tag":76,"props":3590,"children":3591},{},[3592,3596,3597],{"type":46,"tag":80,"props":3593,"children":3594},{},[3595],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":3598,"children":3600},{"className":3599},[],[3601],{"type":52,"value":930},{"type":46,"tag":76,"props":3603,"children":3604},{},[3605,3609,3610],{"type":46,"tag":80,"props":3606,"children":3607},{},[3608],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":3611,"children":3613},{"className":3612},[],[3614],{"type":52,"value":987},{"type":46,"tag":76,"props":3616,"children":3617},{},[3618,3622,3623,3628],{"type":46,"tag":80,"props":3619,"children":3620},{},[3621],{"type":52,"value":995},{"type":52,"value":997},{"type":46,"tag":99,"props":3624,"children":3626},{"className":3625},[],[3627],{"type":52,"value":1003},{"type":52,"value":1005},{"type":46,"tag":76,"props":3630,"children":3631},{},[3632,3636],{"type":46,"tag":80,"props":3633,"children":3634},{},[3635],{"type":52,"value":1013},{"type":52,"value":1015},{"type":46,"tag":76,"props":3638,"children":3639},{},[3640,3644],{"type":46,"tag":80,"props":3641,"children":3642},{},[3643],{"type":52,"value":1023},{"type":52,"value":1025},{"type":46,"tag":76,"props":3646,"children":3647},{},[3648,3652,3653,3657],{"type":46,"tag":80,"props":3649,"children":3650},{},[3651],{"type":52,"value":1033},{"type":52,"value":516},{"type":46,"tag":1036,"props":3654,"children":3655},{},[3656],{"type":52,"value":1040},{"type":52,"value":1042},{"type":46,"tag":55,"props":3659,"children":3660},{},[3661],{"type":52,"value":551},{"type":46,"tag":240,"props":3663,"children":3664},{"className":242,"code":1049,"language":244,"meta":7,"style":7},[3665],{"type":46,"tag":99,"props":3666,"children":3667},{"__ignoreMap":7},[3668],{"type":46,"tag":250,"props":3669,"children":3670},{"class":252,"line":23},[3671,3675,3679,3683,3687],{"type":46,"tag":250,"props":3672,"children":3673},{"style":256},[3674],{"type":52,"value":305},{"type":46,"tag":250,"props":3676,"children":3677},{"style":262},[3678],{"type":52,"value":493},{"type":46,"tag":250,"props":3680,"children":3681},{"style":262},[3682],{"type":52,"value":574},{"type":46,"tag":250,"props":3684,"children":3685},{"style":274},[3686],{"type":52,"value":579},{"type":46,"tag":250,"props":3688,"children":3689},{"style":262},[3690],{"type":52,"value":1077},{"type":46,"tag":55,"props":3692,"children":3693},{},[3694,3695,3700],{"type":52,"value":589},{"type":46,"tag":88,"props":3696,"children":3698},{"href":1084,"rel":3697},[92],[3699],{"type":52,"value":1088},{"type":52,"value":106},{"type":46,"tag":220,"props":3702,"children":3703},{"id":1092},[3704],{"type":52,"value":1095},{"type":46,"tag":55,"props":3706,"children":3707},{},[3708,3709,3714],{"type":52,"value":750},{"type":46,"tag":99,"props":3710,"children":3712},{"className":3711},[],[3713],{"type":52,"value":1105},{"type":52,"value":1107},{"type":46,"tag":423,"props":3716,"children":3717},{":variants":425,"group":426},[3718,3798,3878],{"type":46,"tag":429,"props":3719,"children":3720},{"v-slot:clickhouse":7},[3721],{"type":46,"tag":240,"props":3722,"children":3723},{"className":760,"code":1116,"language":762,"meta":7,"style":7},[3724],{"type":46,"tag":99,"props":3725,"children":3726},{"__ignoreMap":7},[3727,3742,3757,3772,3783],{"type":46,"tag":250,"props":3728,"children":3729},{"class":252,"line":23},[3730,3734,3738],{"type":46,"tag":250,"props":3731,"children":3732},{"style":772},[3733],{"type":52,"value":831},{"type":46,"tag":250,"props":3735,"children":3736},{"style":268},[3737],{"type":52,"value":836},{"type":46,"tag":250,"props":3739,"children":3740},{"style":262},[3741],{"type":52,"value":1136},{"type":46,"tag":250,"props":3743,"children":3744},{"class":252,"line":285},[3745,3749,3753],{"type":46,"tag":250,"props":3746,"children":3747},{"style":772},[3748],{"type":52,"value":1144},{"type":46,"tag":250,"props":3750,"children":3751},{"style":268},[3752],{"type":52,"value":836},{"type":46,"tag":250,"props":3754,"children":3755},{"style":262},[3756],{"type":52,"value":1153},{"type":46,"tag":250,"props":3758,"children":3759},{"class":252,"line":299},[3760,3764,3768],{"type":46,"tag":250,"props":3761,"children":3762},{"style":772},[3763],{"type":52,"value":1161},{"type":46,"tag":250,"props":3765,"children":3766},{"style":268},[3767],{"type":52,"value":836},{"type":46,"tag":250,"props":3769,"children":3770},{"style":262},[3771],{"type":52,"value":1170},{"type":46,"tag":250,"props":3773,"children":3774},{"class":252,"line":807},[3775,3779],{"type":46,"tag":250,"props":3776,"children":3777},{"style":772},[3778],{"type":52,"value":1178},{"type":46,"tag":250,"props":3780,"children":3781},{"style":268},[3782],{"type":52,"value":780},{"type":46,"tag":250,"props":3784,"children":3785},{"class":252,"line":820},[3786,3790,3794],{"type":46,"tag":250,"props":3787,"children":3788},{"style":772},[3789],{"type":52,"value":1190},{"type":46,"tag":250,"props":3791,"children":3792},{"style":268},[3793],{"type":52,"value":836},{"type":46,"tag":250,"props":3795,"children":3796},{"style":262},[3797],{"type":52,"value":1199},{"type":46,"tag":429,"props":3799,"children":3800},{"v-slot:bigquery":7},[3801],{"type":46,"tag":240,"props":3802,"children":3803},{"className":760,"code":1205,"language":762,"meta":7,"style":7},[3804],{"type":46,"tag":99,"props":3805,"children":3806},{"__ignoreMap":7},[3807,3822,3837,3852,3863],{"type":46,"tag":250,"props":3808,"children":3809},{"class":252,"line":23},[3810,3814,3818],{"type":46,"tag":250,"props":3811,"children":3812},{"style":772},[3813],{"type":52,"value":831},{"type":46,"tag":250,"props":3815,"children":3816},{"style":268},[3817],{"type":52,"value":836},{"type":46,"tag":250,"props":3819,"children":3820},{"style":262},[3821],{"type":52,"value":1136},{"type":46,"tag":250,"props":3823,"children":3824},{"class":252,"line":285},[3825,3829,3833],{"type":46,"tag":250,"props":3826,"children":3827},{"style":772},[3828],{"type":52,"value":1144},{"type":46,"tag":250,"props":3830,"children":3831},{"style":268},[3832],{"type":52,"value":836},{"type":46,"tag":250,"props":3834,"children":3835},{"style":262},[3836],{"type":52,"value":1153},{"type":46,"tag":250,"props":3838,"children":3839},{"class":252,"line":299},[3840,3844,3848],{"type":46,"tag":250,"props":3841,"children":3842},{"style":772},[3843],{"type":52,"value":1161},{"type":46,"tag":250,"props":3845,"children":3846},{"style":268},[3847],{"type":52,"value":836},{"type":46,"tag":250,"props":3849,"children":3850},{"style":262},[3851],{"type":52,"value":1170},{"type":46,"tag":250,"props":3853,"children":3854},{"class":252,"line":807},[3855,3859],{"type":46,"tag":250,"props":3856,"children":3857},{"style":772},[3858],{"type":52,"value":1178},{"type":46,"tag":250,"props":3860,"children":3861},{"style":268},[3862],{"type":52,"value":780},{"type":46,"tag":250,"props":3864,"children":3865},{"class":252,"line":820},[3866,3870,3874],{"type":46,"tag":250,"props":3867,"children":3868},{"style":772},[3869],{"type":52,"value":1273},{"type":46,"tag":250,"props":3871,"children":3872},{"style":268},[3873],{"type":52,"value":836},{"type":46,"tag":250,"props":3875,"children":3876},{"style":262},[3877],{"type":52,"value":1282},{"type":46,"tag":429,"props":3879,"children":3880},{"v-slot:snowflake":7},[3881],{"type":46,"tag":240,"props":3882,"children":3883},{"className":760,"code":1288,"language":762,"meta":7,"style":7},[3884],{"type":46,"tag":99,"props":3885,"children":3886},{"__ignoreMap":7},[3887,3902,3917,3932,3943],{"type":46,"tag":250,"props":3888,"children":3889},{"class":252,"line":23},[3890,3894,3898],{"type":46,"tag":250,"props":3891,"children":3892},{"style":772},[3893],{"type":52,"value":831},{"type":46,"tag":250,"props":3895,"children":3896},{"style":268},[3897],{"type":52,"value":836},{"type":46,"tag":250,"props":3899,"children":3900},{"style":262},[3901],{"type":52,"value":1136},{"type":46,"tag":250,"props":3903,"children":3904},{"class":252,"line":285},[3905,3909,3913],{"type":46,"tag":250,"props":3906,"children":3907},{"style":772},[3908],{"type":52,"value":1144},{"type":46,"tag":250,"props":3910,"children":3911},{"style":268},[3912],{"type":52,"value":836},{"type":46,"tag":250,"props":3914,"children":3915},{"style":262},[3916],{"type":52,"value":1153},{"type":46,"tag":250,"props":3918,"children":3919},{"class":252,"line":299},[3920,3924,3928],{"type":46,"tag":250,"props":3921,"children":3922},{"style":772},[3923],{"type":52,"value":1161},{"type":46,"tag":250,"props":3925,"children":3926},{"style":268},[3927],{"type":52,"value":836},{"type":46,"tag":250,"props":3929,"children":3930},{"style":262},[3931],{"type":52,"value":1170},{"type":46,"tag":250,"props":3933,"children":3934},{"class":252,"line":807},[3935,3939],{"type":46,"tag":250,"props":3936,"children":3937},{"style":772},[3938],{"type":52,"value":1178},{"type":46,"tag":250,"props":3940,"children":3941},{"style":268},[3942],{"type":52,"value":780},{"type":46,"tag":250,"props":3944,"children":3945},{"class":252,"line":820},[3946,3950,3954],{"type":46,"tag":250,"props":3947,"children":3948},{"style":772},[3949],{"type":52,"value":1356},{"type":46,"tag":250,"props":3951,"children":3952},{"style":268},[3953],{"type":52,"value":836},{"type":46,"tag":250,"props":3955,"children":3956},{"style":262},[3957],{"type":52,"value":1365},{"type":46,"tag":220,"props":3959,"children":3960},{"id":1368},[3961],{"type":52,"value":1371},{"type":46,"tag":55,"props":3963,"children":3964},{},[3965,3966,3971],{"type":52,"value":1376},{"type":46,"tag":99,"props":3967,"children":3969},{"className":3968},[],[3970],{"type":52,"value":305},{"type":52,"value":1383},{"type":46,"tag":240,"props":3973,"children":3974},{"className":242,"code":1386,"language":244,"meta":7,"style":7},[3975],{"type":46,"tag":99,"props":3976,"children":3977},{"__ignoreMap":7},[3978],{"type":46,"tag":250,"props":3979,"children":3980},{"class":252,"line":23},[3981,3985,3989,3993,3997,4001,4005],{"type":46,"tag":250,"props":3982,"children":3983},{"style":256},[3984],{"type":52,"value":1398},{"type":46,"tag":250,"props":3986,"children":3987},{"style":262},[3988],{"type":52,"value":1403},{"type":46,"tag":250,"props":3990,"children":3991},{"style":262},[3992],{"type":52,"value":1408},{"type":46,"tag":250,"props":3994,"children":3995},{"style":262},[3996],{"type":52,"value":1413},{"type":46,"tag":250,"props":3998,"children":3999},{"style":274},[4000],{"type":52,"value":1418},{"type":46,"tag":250,"props":4002,"children":4003},{"style":262},[4004],{"type":52,"value":1413},{"type":46,"tag":250,"props":4006,"children":4007},{"style":262},[4008],{"type":52,"value":1427},{"type":46,"tag":55,"props":4010,"children":4011},{},[4012],{"type":52,"value":1432},{"type":46,"tag":1434,"props":4014,"children":4015},{},[4016],{"type":46,"tag":55,"props":4017,"children":4018},{},[4019],{"type":52,"value":1441},{"type":46,"tag":55,"props":4021,"children":4022},{},[4023],{"type":52,"value":1446},{"type":46,"tag":198,"props":4025,"children":4026},{},[4027],{"type":46,"tag":55,"props":4028,"children":4029},{},[4030,4034,4035,4040,4041,4046],{"type":46,"tag":80,"props":4031,"children":4032},{},[4033],{"type":52,"value":1457},{"type":52,"value":1459},{"type":46,"tag":99,"props":4036,"children":4038},{"className":4037},[],[4039],{"type":52,"value":1465},{"type":52,"value":1467},{"type":46,"tag":99,"props":4042,"children":4044},{"className":4043},[],[4045],{"type":52,"value":1473},{"type":52,"value":1475},{"type":46,"tag":220,"props":4048,"children":4049},{"id":1478},[4050],{"type":52,"value":1481},{"type":46,"tag":55,"props":4052,"children":4053},{},[4054],{"type":52,"value":1486},{"type":46,"tag":240,"props":4056,"children":4057},{"className":242,"code":1489,"language":244,"meta":7,"style":7},[4058],{"type":46,"tag":99,"props":4059,"children":4060},{"__ignoreMap":7},[4061],{"type":46,"tag":250,"props":4062,"children":4063},{"class":252,"line":23},[4064,4068,4072],{"type":46,"tag":250,"props":4065,"children":4066},{"style":256},[4067],{"type":52,"value":305},{"type":46,"tag":250,"props":4069,"children":4070},{"style":262},[4071],{"type":52,"value":1505},{"type":46,"tag":250,"props":4073,"children":4074},{"style":262},[4075],{"type":52,"value":1510},{"type":46,"tag":55,"props":4077,"children":4078},{},[4079],{"type":52,"value":1515},{"type":46,"tag":1434,"props":4081,"children":4082},{},[4083],{"type":46,"tag":55,"props":4084,"children":4085},{},[4086],{"type":52,"value":1523},{"type":46,"tag":55,"props":4088,"children":4089},{},[4090],{"type":52,"value":1528},{"type":46,"tag":47,"props":4092,"children":4093},{"id":1531},[4094],{"type":52,"value":1534},{"type":46,"tag":55,"props":4096,"children":4097},{},[4098],{"type":52,"value":1539},{"type":46,"tag":1541,"props":4100,"children":4101},{},[4102],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":4104},[4105,4106,4107,4108,4116],{"id":49,"depth":285,"text":53},{"id":62,"depth":285,"text":65},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":4109},[4110,4111,4112,4113,4114,4115],{"id":222,"depth":299,"text":225},{"id":338,"depth":299,"text":341},{"id":413,"depth":299,"text":416},{"id":1092,"depth":299,"text":1095},{"id":1368,"depth":299,"text":1371},{"id":1478,"depth":299,"text":1481},{"id":1531,"depth":285,"text":1534},{"_path":4118,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":4119,"description":4120,"date":10,"readingTime":4121,"category":12,"tags":4122,"difficulty":21,"module":5,"subSteps":22,"step":285,"variants":4133,"journeys":4135,"learnMore":4136,"author":4145,"body":4146,"_type":1560,"_id":8779,"_source":1562,"_file":8780,"_stem":8781,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fingest-data","Ingest Your Ecommerce Data","Connect your Shopify store and surrounding tools to Bruin, and create ingestor assets that pull data into your warehouse automatically.",15,[14,15,4123,16,4124,4125,4126,4127,4128,4129,4130,4131,4132,20],"Bruin Ingestr","Shopify","Stripe","Klaviyo","HubSpot","Facebook Ads","Google Ads","TikTok Ads","Google Analytics","Mixpanel",[4126,4127,4128,4129,4130,4134,4132],"GA4",[26,27],[4137,4140,4142],{"label":4138,"url":4139},"Ingestr asset reference","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fassets\u002Fingestr.html",{"label":4141,"url":34},"Bruin connections",{"label":4143,"url":4144},"Incremental loading strategies","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fassets\u002Fingestr.html#incremental-strategies",{"name":39,"role":40,"image":41},{"type":43,"children":4147,"toc":8762},[4148,4152,4157,4161,4166,4180,4186,4191,4199,4204,4208,4214,4219,4372,4376,4382,4403,4407,4471,4478,4491,5101,5125,5128,5134,5874,5877,5883,6728,6731,6737,7751,7754,7760,8459,8462,8468,8473,8494,8499,8507,8512,8517,8560,8593,8613,8661,8666,8706,8712,8717,8725,8730,8738,8742,8753,8758],{"type":46,"tag":47,"props":4149,"children":4150},{"id":49},[4151],{"type":52,"value":53},{"type":46,"tag":55,"props":4153,"children":4154},{},[4155],{"type":52,"value":4156},"Create ingestor assets for your Shopify store and the tools around it. Each asset pulls data from a SaaS tool into your warehouse on schedule.",{"type":46,"tag":47,"props":4158,"children":4159},{"id":183},[4160],{"type":52,"value":186},{"type":46,"tag":55,"props":4162,"children":4163},{},[4164],{"type":52,"value":4165},"A Shopify store has data spread across many tools: orders and products in Shopify, payments in Stripe or Shopify Payments, email engagement in your marketing platform, ad performance in your ad platform, and website traffic in your analytics tool. Getting all of this into one warehouse is the foundation for every report you'll build later.",{"type":46,"tag":55,"props":4167,"children":4168},{},[4169,4171,4178],{"type":52,"value":4170},"Bruin's ingestor assets use ",{"type":46,"tag":88,"props":4172,"children":4175},{"href":4173,"rel":4174},"https:\u002F\u002Fbruin-data.github.io\u002Fingestr\u002F",[92],[4176],{"type":52,"value":4177},"ingestr",{"type":52,"value":4179}," under the hood - an open-source tool with 100+ built-in connectors. You define what to pull in a simple YAML file, and Bruin handles scheduling, incremental loading, and dependency management.",{"type":46,"tag":220,"props":4181,"children":4183},{"id":4182},"let-claude-code-create-the-asset-files",[4184],{"type":52,"value":4185},"Let Claude Code create the asset files",{"type":46,"tag":55,"props":4187,"children":4188},{},[4189],{"type":52,"value":4190},"You can create each ingestor asset file manually (shown below), or ask Claude Code to do it for you:",{"type":46,"tag":1434,"props":4192,"children":4193},{},[4194],{"type":46,"tag":55,"props":4195,"children":4196},{},[4197],{"type":52,"value":4198},"Look at the Bruin ingestr docs and create ingestor assets for Shopify orders, customers, products, and inventory_levels. Use merge strategy with updated_at for the first three, and replace for inventory. Use my warehouse connection as destination. Put them in ecommerce\u002Fassets\u002F.",{"type":46,"tag":55,"props":4200,"children":4201},{},[4202],{"type":52,"value":4203},"Below we show the files so you can see what they look like, but feel free to have Claude Code generate them.",{"type":46,"tag":47,"props":4205,"children":4206},{"id":215},[4207],{"type":52,"value":218},{"type":46,"tag":220,"props":4209,"children":4211},{"id":4210},"optional-install-source-mcps",[4212],{"type":52,"value":4213},"Optional: install source MCPs",{"type":46,"tag":55,"props":4215,"children":4216},{},[4217],{"type":52,"value":4218},"These platforms offer their own MCP servers that let Claude Code explore available tables and schemas before you write ingestor assets. Not required, but useful.",{"type":46,"tag":423,"props":4220,"children":4222},{":variants":4221},"[{\"id\":\"shopify-mcp\",\"label\":\"Shopify\"},{\"id\":\"stripe-mcp\",\"label\":\"Stripe\"},{\"id\":\"klaviyo-mcp\",\"label\":\"Klaviyo\"},{\"id\":\"facebook-mcp\",\"label\":\"Facebook Ads\"},{\"id\":\"ga4-mcp\",\"label\":\"GA4\"}]",[4223,4256,4298,4320,4352],{"type":46,"tag":429,"props":4224,"children":4225},{"v-slot:shopify-mcp":7},[4226,4236],{"type":46,"tag":55,"props":4227,"children":4228},{},[4229],{"type":46,"tag":88,"props":4230,"children":4233},{"href":4231,"rel":4232},"https:\u002F\u002Fshopify.dev\u002Fdocs\u002Fapps\u002Fbuild\u002Fdevmcp",[92],[4234],{"type":52,"value":4235},"Official Dev MCP",{"type":46,"tag":240,"props":4237,"children":4239},{"className":242,"code":4238,"language":244,"meta":7,"style":7},"npx @shopify\u002Fdev-mcp@latest\n",[4240],{"type":46,"tag":99,"props":4241,"children":4242},{"__ignoreMap":7},[4243],{"type":46,"tag":250,"props":4244,"children":4245},{"class":252,"line":23},[4246,4251],{"type":46,"tag":250,"props":4247,"children":4248},{"style":256},[4249],{"type":52,"value":4250},"npx",{"type":46,"tag":250,"props":4252,"children":4253},{"style":262},[4254],{"type":52,"value":4255}," @shopify\u002Fdev-mcp@latest\n",{"type":46,"tag":429,"props":4257,"children":4258},{"v-slot:stripe-mcp":7},[4259,4269],{"type":46,"tag":55,"props":4260,"children":4261},{},[4262],{"type":46,"tag":88,"props":4263,"children":4266},{"href":4264,"rel":4265},"https:\u002F\u002Fdocs.stripe.com\u002Fmcp",[92],[4267],{"type":52,"value":4268},"Official MCP",{"type":46,"tag":240,"props":4270,"children":4272},{"className":242,"code":4271,"language":244,"meta":7,"style":7},"npx -y @stripe\u002Fmcp --api-key=sk_...\n",[4273],{"type":46,"tag":99,"props":4274,"children":4275},{"__ignoreMap":7},[4276],{"type":46,"tag":250,"props":4277,"children":4278},{"class":252,"line":23},[4279,4283,4288,4293],{"type":46,"tag":250,"props":4280,"children":4281},{"style":256},[4282],{"type":52,"value":4250},{"type":46,"tag":250,"props":4284,"children":4285},{"style":274},[4286],{"type":52,"value":4287}," -y",{"type":46,"tag":250,"props":4289,"children":4290},{"style":262},[4291],{"type":52,"value":4292}," @stripe\u002Fmcp",{"type":46,"tag":250,"props":4294,"children":4295},{"style":274},[4296],{"type":52,"value":4297}," --api-key=sk_...\n",{"type":46,"tag":429,"props":4299,"children":4300},{"v-slot:klaviyo-mcp":7},[4301],{"type":46,"tag":55,"props":4302,"children":4303},{},[4304,4310,4312,4318],{"type":46,"tag":88,"props":4305,"children":4308},{"href":4306,"rel":4307},"https:\u002F\u002Fdevelopers.klaviyo.com\u002Fen\u002Fdocs\u002Fklaviyo_mcp_server",[92],[4309],{"type":52,"value":4268},{"type":52,"value":4311}," - see ",{"type":46,"tag":88,"props":4313,"children":4315},{"href":4306,"rel":4314},[92],[4316],{"type":52,"value":4317},"Klaviyo MCP docs",{"type":52,"value":4319}," for setup.",{"type":46,"tag":429,"props":4321,"children":4322},{"v-slot:facebook-mcp":7},[4323,4333],{"type":46,"tag":55,"props":4324,"children":4325},{},[4326],{"type":46,"tag":88,"props":4327,"children":4330},{"href":4328,"rel":4329},"https:\u002F\u002Fgithub.com\u002Fpipeboard-co\u002Fmeta-ads-mcp",[92],[4331],{"type":52,"value":4332},"Community MCP",{"type":46,"tag":240,"props":4334,"children":4336},{"className":242,"code":4335,"language":244,"meta":7,"style":7},"npx meta-ads-mcp@latest\n",[4337],{"type":46,"tag":99,"props":4338,"children":4339},{"__ignoreMap":7},[4340],{"type":46,"tag":250,"props":4341,"children":4342},{"class":252,"line":23},[4343,4347],{"type":46,"tag":250,"props":4344,"children":4345},{"style":256},[4346],{"type":52,"value":4250},{"type":46,"tag":250,"props":4348,"children":4349},{"style":262},[4350],{"type":52,"value":4351}," meta-ads-mcp@latest\n",{"type":46,"tag":429,"props":4353,"children":4354},{"v-slot:ga4-mcp":7},[4355],{"type":46,"tag":55,"props":4356,"children":4357},{},[4358,4364,4365,4371],{"type":46,"tag":88,"props":4359,"children":4362},{"href":4360,"rel":4361},"https:\u002F\u002Fdevelopers.google.com\u002Fanalytics\u002Fdevguides\u002FMCP",[92],[4363],{"type":52,"value":4268},{"type":52,"value":4311},{"type":46,"tag":88,"props":4366,"children":4368},{"href":4360,"rel":4367},[92],[4369],{"type":52,"value":4370},"Google Analytics MCP docs",{"type":52,"value":4319},{"type":46,"tag":4373,"props":4374,"children":4375},"hr",{},[],{"type":46,"tag":220,"props":4377,"children":4379},{"id":4378},"add-the-shopify-connection",[4380],{"type":52,"value":4381},"Add the Shopify connection",{"type":46,"tag":240,"props":4383,"children":4384},{"className":242,"code":477,"language":244,"meta":7,"style":7},[4385],{"type":46,"tag":99,"props":4386,"children":4387},{"__ignoreMap":7},[4388],{"type":46,"tag":250,"props":4389,"children":4390},{"class":252,"line":23},[4391,4395,4399],{"type":46,"tag":250,"props":4392,"children":4393},{"style":256},[4394],{"type":52,"value":305},{"type":46,"tag":250,"props":4396,"children":4397},{"style":262},[4398],{"type":52,"value":493},{"type":46,"tag":250,"props":4400,"children":4401},{"style":262},[4402],{"type":52,"value":498},{"type":46,"tag":55,"props":4404,"children":4405},{},[4406],{"type":52,"value":503},{"type":46,"tag":72,"props":4408,"children":4409},{},[4410,4424,4437,4454],{"type":46,"tag":76,"props":4411,"children":4412},{},[4413,4417,4418],{"type":46,"tag":80,"props":4414,"children":4415},{},[4416],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":4419,"children":4421},{"className":4420},[],[4422],{"type":52,"value":4423},"shopify",{"type":46,"tag":76,"props":4425,"children":4426},{},[4427,4431,4432],{"type":46,"tag":80,"props":4428,"children":4429},{},[4430],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":4433,"children":4435},{"className":4434},[],[4436],{"type":52,"value":4423},{"type":46,"tag":76,"props":4438,"children":4439},{},[4440,4445,4447],{"type":46,"tag":80,"props":4441,"children":4442},{},[4443],{"type":52,"value":4444},"API key, API secret, access token:",{"type":52,"value":4446}," from your ",{"type":46,"tag":88,"props":4448,"children":4451},{"href":4449,"rel":4450},"https:\u002F\u002Fshopify.dev\u002Fdocs\u002Fapps\u002Fgetting-started",[92],[4452],{"type":52,"value":4453},"Shopify app credentials",{"type":46,"tag":76,"props":4455,"children":4456},{},[4457,4462,4464,4470],{"type":46,"tag":80,"props":4458,"children":4459},{},[4460],{"type":52,"value":4461},"Shop:",{"type":52,"value":4463}," your store name (without ",{"type":46,"tag":99,"props":4465,"children":4467},{"className":4466},[],[4468],{"type":52,"value":4469},".myshopify.com",{"type":52,"value":1005},{"type":46,"tag":4472,"props":4473,"children":4475},"h4",{"id":4474},"create-ingestor-assets",[4476],{"type":52,"value":4477},"Create ingestor assets",{"type":46,"tag":55,"props":4479,"children":4480},{},[4481,4483,4489],{"type":52,"value":4482},"Create a file for each table you want to ingest. These go in your ",{"type":46,"tag":99,"props":4484,"children":4486},{"className":4485},[],[4487],{"type":52,"value":4488},"ecommerce\u002Fassets\u002F",{"type":52,"value":4490}," folder.",{"type":46,"tag":423,"props":4492,"children":4494},{":variants":4493},"[{\"id\":\"shopify-orders\",\"label\":\"Orders\"},{\"id\":\"shopify-customers\",\"label\":\"Customers\"},{\"id\":\"shopify-products\",\"label\":\"Products\"},{\"id\":\"shopify-inventory\",\"label\":\"Inventory\"}]",[4495,4665,4820,4975],{"type":46,"tag":429,"props":4496,"children":4497},{"v-slot:shopify-orders":7},[4498,4510],{"type":46,"tag":55,"props":4499,"children":4500},{},[4501],{"type":46,"tag":80,"props":4502,"children":4503},{},[4504],{"type":46,"tag":99,"props":4505,"children":4507},{"className":4506},[],[4508],{"type":52,"value":4509},"ecommerce\u002Fassets\u002Fshopify_orders.asset.yml",{"type":46,"tag":240,"props":4511,"children":4513},{"className":760,"code":4512,"language":762,"meta":7,"style":7},"name: raw.shopify_orders\ntype: ingestr\nparameters:\n  source_connection: shopify\n  source_table: orders\n  loader_file_format: jsonl\n  incremental_strategy: merge\n  incremental_key: updated_at\n  primary_key: id\n",[4514],{"type":46,"tag":99,"props":4515,"children":4516},{"__ignoreMap":7},[4517,4533,4550,4562,4579,4596,4613,4630,4647],{"type":46,"tag":250,"props":4518,"children":4519},{"class":252,"line":23},[4520,4524,4528],{"type":46,"tag":250,"props":4521,"children":4522},{"style":772},[4523],{"type":52,"value":831},{"type":46,"tag":250,"props":4525,"children":4526},{"style":268},[4527],{"type":52,"value":836},{"type":46,"tag":250,"props":4529,"children":4530},{"style":262},[4531],{"type":52,"value":4532},"raw.shopify_orders\n",{"type":46,"tag":250,"props":4534,"children":4535},{"class":252,"line":285},[4536,4541,4545],{"type":46,"tag":250,"props":4537,"children":4538},{"style":772},[4539],{"type":52,"value":4540},"type",{"type":46,"tag":250,"props":4542,"children":4543},{"style":268},[4544],{"type":52,"value":836},{"type":46,"tag":250,"props":4546,"children":4547},{"style":262},[4548],{"type":52,"value":4549},"ingestr\n",{"type":46,"tag":250,"props":4551,"children":4552},{"class":252,"line":299},[4553,4558],{"type":46,"tag":250,"props":4554,"children":4555},{"style":772},[4556],{"type":52,"value":4557},"parameters",{"type":46,"tag":250,"props":4559,"children":4560},{"style":268},[4561],{"type":52,"value":780},{"type":46,"tag":250,"props":4563,"children":4564},{"class":252,"line":807},[4565,4570,4574],{"type":46,"tag":250,"props":4566,"children":4567},{"style":772},[4568],{"type":52,"value":4569},"  source_connection",{"type":46,"tag":250,"props":4571,"children":4572},{"style":268},[4573],{"type":52,"value":836},{"type":46,"tag":250,"props":4575,"children":4576},{"style":262},[4577],{"type":52,"value":4578},"shopify\n",{"type":46,"tag":250,"props":4580,"children":4581},{"class":252,"line":820},[4582,4587,4591],{"type":46,"tag":250,"props":4583,"children":4584},{"style":772},[4585],{"type":52,"value":4586},"  source_table",{"type":46,"tag":250,"props":4588,"children":4589},{"style":268},[4590],{"type":52,"value":836},{"type":46,"tag":250,"props":4592,"children":4593},{"style":262},[4594],{"type":52,"value":4595},"orders\n",{"type":46,"tag":250,"props":4597,"children":4598},{"class":252,"line":844},[4599,4604,4608],{"type":46,"tag":250,"props":4600,"children":4601},{"style":772},[4602],{"type":52,"value":4603},"  loader_file_format",{"type":46,"tag":250,"props":4605,"children":4606},{"style":268},[4607],{"type":52,"value":836},{"type":46,"tag":250,"props":4609,"children":4610},{"style":262},[4611],{"type":52,"value":4612},"jsonl\n",{"type":46,"tag":250,"props":4614,"children":4615},{"class":252,"line":862},[4616,4621,4625],{"type":46,"tag":250,"props":4617,"children":4618},{"style":772},[4619],{"type":52,"value":4620},"  incremental_strategy",{"type":46,"tag":250,"props":4622,"children":4623},{"style":268},[4624],{"type":52,"value":836},{"type":46,"tag":250,"props":4626,"children":4627},{"style":262},[4628],{"type":52,"value":4629},"merge\n",{"type":46,"tag":250,"props":4631,"children":4632},{"class":252,"line":11},[4633,4638,4642],{"type":46,"tag":250,"props":4634,"children":4635},{"style":772},[4636],{"type":52,"value":4637},"  incremental_key",{"type":46,"tag":250,"props":4639,"children":4640},{"style":268},[4641],{"type":52,"value":836},{"type":46,"tag":250,"props":4643,"children":4644},{"style":262},[4645],{"type":52,"value":4646},"updated_at\n",{"type":46,"tag":250,"props":4648,"children":4650},{"class":252,"line":4649},9,[4651,4656,4660],{"type":46,"tag":250,"props":4652,"children":4653},{"style":772},[4654],{"type":52,"value":4655},"  primary_key",{"type":46,"tag":250,"props":4657,"children":4658},{"style":268},[4659],{"type":52,"value":836},{"type":46,"tag":250,"props":4661,"children":4662},{"style":262},[4663],{"type":52,"value":4664},"id\n",{"type":46,"tag":429,"props":4666,"children":4667},{"v-slot:shopify-customers":7},[4668,4680],{"type":46,"tag":55,"props":4669,"children":4670},{},[4671],{"type":46,"tag":80,"props":4672,"children":4673},{},[4674],{"type":46,"tag":99,"props":4675,"children":4677},{"className":4676},[],[4678],{"type":52,"value":4679},"ecommerce\u002Fassets\u002Fshopify_customers.asset.yml",{"type":46,"tag":240,"props":4681,"children":4683},{"className":760,"code":4682,"language":762,"meta":7,"style":7},"name: raw.shopify_customers\ntype: ingestr\nparameters:\n  source_connection: shopify\n  source_table: customers\n  loader_file_format: jsonl\n  incremental_strategy: merge\n  incremental_key: updated_at\n  primary_key: id\n",[4684],{"type":46,"tag":99,"props":4685,"children":4686},{"__ignoreMap":7},[4687,4703,4718,4729,4744,4760,4775,4790,4805],{"type":46,"tag":250,"props":4688,"children":4689},{"class":252,"line":23},[4690,4694,4698],{"type":46,"tag":250,"props":4691,"children":4692},{"style":772},[4693],{"type":52,"value":831},{"type":46,"tag":250,"props":4695,"children":4696},{"style":268},[4697],{"type":52,"value":836},{"type":46,"tag":250,"props":4699,"children":4700},{"style":262},[4701],{"type":52,"value":4702},"raw.shopify_customers\n",{"type":46,"tag":250,"props":4704,"children":4705},{"class":252,"line":285},[4706,4710,4714],{"type":46,"tag":250,"props":4707,"children":4708},{"style":772},[4709],{"type":52,"value":4540},{"type":46,"tag":250,"props":4711,"children":4712},{"style":268},[4713],{"type":52,"value":836},{"type":46,"tag":250,"props":4715,"children":4716},{"style":262},[4717],{"type":52,"value":4549},{"type":46,"tag":250,"props":4719,"children":4720},{"class":252,"line":299},[4721,4725],{"type":46,"tag":250,"props":4722,"children":4723},{"style":772},[4724],{"type":52,"value":4557},{"type":46,"tag":250,"props":4726,"children":4727},{"style":268},[4728],{"type":52,"value":780},{"type":46,"tag":250,"props":4730,"children":4731},{"class":252,"line":807},[4732,4736,4740],{"type":46,"tag":250,"props":4733,"children":4734},{"style":772},[4735],{"type":52,"value":4569},{"type":46,"tag":250,"props":4737,"children":4738},{"style":268},[4739],{"type":52,"value":836},{"type":46,"tag":250,"props":4741,"children":4742},{"style":262},[4743],{"type":52,"value":4578},{"type":46,"tag":250,"props":4745,"children":4746},{"class":252,"line":820},[4747,4751,4755],{"type":46,"tag":250,"props":4748,"children":4749},{"style":772},[4750],{"type":52,"value":4586},{"type":46,"tag":250,"props":4752,"children":4753},{"style":268},[4754],{"type":52,"value":836},{"type":46,"tag":250,"props":4756,"children":4757},{"style":262},[4758],{"type":52,"value":4759},"customers\n",{"type":46,"tag":250,"props":4761,"children":4762},{"class":252,"line":844},[4763,4767,4771],{"type":46,"tag":250,"props":4764,"children":4765},{"style":772},[4766],{"type":52,"value":4603},{"type":46,"tag":250,"props":4768,"children":4769},{"style":268},[4770],{"type":52,"value":836},{"type":46,"tag":250,"props":4772,"children":4773},{"style":262},[4774],{"type":52,"value":4612},{"type":46,"tag":250,"props":4776,"children":4777},{"class":252,"line":862},[4778,4782,4786],{"type":46,"tag":250,"props":4779,"children":4780},{"style":772},[4781],{"type":52,"value":4620},{"type":46,"tag":250,"props":4783,"children":4784},{"style":268},[4785],{"type":52,"value":836},{"type":46,"tag":250,"props":4787,"children":4788},{"style":262},[4789],{"type":52,"value":4629},{"type":46,"tag":250,"props":4791,"children":4792},{"class":252,"line":11},[4793,4797,4801],{"type":46,"tag":250,"props":4794,"children":4795},{"style":772},[4796],{"type":52,"value":4637},{"type":46,"tag":250,"props":4798,"children":4799},{"style":268},[4800],{"type":52,"value":836},{"type":46,"tag":250,"props":4802,"children":4803},{"style":262},[4804],{"type":52,"value":4646},{"type":46,"tag":250,"props":4806,"children":4807},{"class":252,"line":4649},[4808,4812,4816],{"type":46,"tag":250,"props":4809,"children":4810},{"style":772},[4811],{"type":52,"value":4655},{"type":46,"tag":250,"props":4813,"children":4814},{"style":268},[4815],{"type":52,"value":836},{"type":46,"tag":250,"props":4817,"children":4818},{"style":262},[4819],{"type":52,"value":4664},{"type":46,"tag":429,"props":4821,"children":4822},{"v-slot:shopify-products":7},[4823,4835],{"type":46,"tag":55,"props":4824,"children":4825},{},[4826],{"type":46,"tag":80,"props":4827,"children":4828},{},[4829],{"type":46,"tag":99,"props":4830,"children":4832},{"className":4831},[],[4833],{"type":52,"value":4834},"ecommerce\u002Fassets\u002Fshopify_products.asset.yml",{"type":46,"tag":240,"props":4836,"children":4838},{"className":760,"code":4837,"language":762,"meta":7,"style":7},"name: raw.shopify_products\ntype: ingestr\nparameters:\n  source_connection: shopify\n  source_table: products\n  loader_file_format: jsonl\n  incremental_strategy: merge\n  incremental_key: updated_at\n  primary_key: id\n",[4839],{"type":46,"tag":99,"props":4840,"children":4841},{"__ignoreMap":7},[4842,4858,4873,4884,4899,4915,4930,4945,4960],{"type":46,"tag":250,"props":4843,"children":4844},{"class":252,"line":23},[4845,4849,4853],{"type":46,"tag":250,"props":4846,"children":4847},{"style":772},[4848],{"type":52,"value":831},{"type":46,"tag":250,"props":4850,"children":4851},{"style":268},[4852],{"type":52,"value":836},{"type":46,"tag":250,"props":4854,"children":4855},{"style":262},[4856],{"type":52,"value":4857},"raw.shopify_products\n",{"type":46,"tag":250,"props":4859,"children":4860},{"class":252,"line":285},[4861,4865,4869],{"type":46,"tag":250,"props":4862,"children":4863},{"style":772},[4864],{"type":52,"value":4540},{"type":46,"tag":250,"props":4866,"children":4867},{"style":268},[4868],{"type":52,"value":836},{"type":46,"tag":250,"props":4870,"children":4871},{"style":262},[4872],{"type":52,"value":4549},{"type":46,"tag":250,"props":4874,"children":4875},{"class":252,"line":299},[4876,4880],{"type":46,"tag":250,"props":4877,"children":4878},{"style":772},[4879],{"type":52,"value":4557},{"type":46,"tag":250,"props":4881,"children":4882},{"style":268},[4883],{"type":52,"value":780},{"type":46,"tag":250,"props":4885,"children":4886},{"class":252,"line":807},[4887,4891,4895],{"type":46,"tag":250,"props":4888,"children":4889},{"style":772},[4890],{"type":52,"value":4569},{"type":46,"tag":250,"props":4892,"children":4893},{"style":268},[4894],{"type":52,"value":836},{"type":46,"tag":250,"props":4896,"children":4897},{"style":262},[4898],{"type":52,"value":4578},{"type":46,"tag":250,"props":4900,"children":4901},{"class":252,"line":820},[4902,4906,4910],{"type":46,"tag":250,"props":4903,"children":4904},{"style":772},[4905],{"type":52,"value":4586},{"type":46,"tag":250,"props":4907,"children":4908},{"style":268},[4909],{"type":52,"value":836},{"type":46,"tag":250,"props":4911,"children":4912},{"style":262},[4913],{"type":52,"value":4914},"products\n",{"type":46,"tag":250,"props":4916,"children":4917},{"class":252,"line":844},[4918,4922,4926],{"type":46,"tag":250,"props":4919,"children":4920},{"style":772},[4921],{"type":52,"value":4603},{"type":46,"tag":250,"props":4923,"children":4924},{"style":268},[4925],{"type":52,"value":836},{"type":46,"tag":250,"props":4927,"children":4928},{"style":262},[4929],{"type":52,"value":4612},{"type":46,"tag":250,"props":4931,"children":4932},{"class":252,"line":862},[4933,4937,4941],{"type":46,"tag":250,"props":4934,"children":4935},{"style":772},[4936],{"type":52,"value":4620},{"type":46,"tag":250,"props":4938,"children":4939},{"style":268},[4940],{"type":52,"value":836},{"type":46,"tag":250,"props":4942,"children":4943},{"style":262},[4944],{"type":52,"value":4629},{"type":46,"tag":250,"props":4946,"children":4947},{"class":252,"line":11},[4948,4952,4956],{"type":46,"tag":250,"props":4949,"children":4950},{"style":772},[4951],{"type":52,"value":4637},{"type":46,"tag":250,"props":4953,"children":4954},{"style":268},[4955],{"type":52,"value":836},{"type":46,"tag":250,"props":4957,"children":4958},{"style":262},[4959],{"type":52,"value":4646},{"type":46,"tag":250,"props":4961,"children":4962},{"class":252,"line":4649},[4963,4967,4971],{"type":46,"tag":250,"props":4964,"children":4965},{"style":772},[4966],{"type":52,"value":4655},{"type":46,"tag":250,"props":4968,"children":4969},{"style":268},[4970],{"type":52,"value":836},{"type":46,"tag":250,"props":4972,"children":4973},{"style":262},[4974],{"type":52,"value":4664},{"type":46,"tag":429,"props":4976,"children":4977},{"v-slot:shopify-inventory":7},[4978,4990],{"type":46,"tag":55,"props":4979,"children":4980},{},[4981],{"type":46,"tag":80,"props":4982,"children":4983},{},[4984],{"type":46,"tag":99,"props":4985,"children":4987},{"className":4986},[],[4988],{"type":52,"value":4989},"ecommerce\u002Fassets\u002Fshopify_inventory.asset.yml",{"type":46,"tag":240,"props":4991,"children":4993},{"className":760,"code":4992,"language":762,"meta":7,"style":7},"name: raw.shopify_inventory\ntype: ingestr\nparameters:\n  source_connection: shopify\n  source_table: inventory_levels\n  loader_file_format: jsonl\n  incremental_strategy: replace\n",[4994],{"type":46,"tag":99,"props":4995,"children":4996},{"__ignoreMap":7},[4997,5013,5028,5039,5054,5070,5085],{"type":46,"tag":250,"props":4998,"children":4999},{"class":252,"line":23},[5000,5004,5008],{"type":46,"tag":250,"props":5001,"children":5002},{"style":772},[5003],{"type":52,"value":831},{"type":46,"tag":250,"props":5005,"children":5006},{"style":268},[5007],{"type":52,"value":836},{"type":46,"tag":250,"props":5009,"children":5010},{"style":262},[5011],{"type":52,"value":5012},"raw.shopify_inventory\n",{"type":46,"tag":250,"props":5014,"children":5015},{"class":252,"line":285},[5016,5020,5024],{"type":46,"tag":250,"props":5017,"children":5018},{"style":772},[5019],{"type":52,"value":4540},{"type":46,"tag":250,"props":5021,"children":5022},{"style":268},[5023],{"type":52,"value":836},{"type":46,"tag":250,"props":5025,"children":5026},{"style":262},[5027],{"type":52,"value":4549},{"type":46,"tag":250,"props":5029,"children":5030},{"class":252,"line":299},[5031,5035],{"type":46,"tag":250,"props":5032,"children":5033},{"style":772},[5034],{"type":52,"value":4557},{"type":46,"tag":250,"props":5036,"children":5037},{"style":268},[5038],{"type":52,"value":780},{"type":46,"tag":250,"props":5040,"children":5041},{"class":252,"line":807},[5042,5046,5050],{"type":46,"tag":250,"props":5043,"children":5044},{"style":772},[5045],{"type":52,"value":4569},{"type":46,"tag":250,"props":5047,"children":5048},{"style":268},[5049],{"type":52,"value":836},{"type":46,"tag":250,"props":5051,"children":5052},{"style":262},[5053],{"type":52,"value":4578},{"type":46,"tag":250,"props":5055,"children":5056},{"class":252,"line":820},[5057,5061,5065],{"type":46,"tag":250,"props":5058,"children":5059},{"style":772},[5060],{"type":52,"value":4586},{"type":46,"tag":250,"props":5062,"children":5063},{"style":268},[5064],{"type":52,"value":836},{"type":46,"tag":250,"props":5066,"children":5067},{"style":262},[5068],{"type":52,"value":5069},"inventory_levels\n",{"type":46,"tag":250,"props":5071,"children":5072},{"class":252,"line":844},[5073,5077,5081],{"type":46,"tag":250,"props":5074,"children":5075},{"style":772},[5076],{"type":52,"value":4603},{"type":46,"tag":250,"props":5078,"children":5079},{"style":268},[5080],{"type":52,"value":836},{"type":46,"tag":250,"props":5082,"children":5083},{"style":262},[5084],{"type":52,"value":4612},{"type":46,"tag":250,"props":5086,"children":5087},{"class":252,"line":862},[5088,5092,5096],{"type":46,"tag":250,"props":5089,"children":5090},{"style":772},[5091],{"type":52,"value":4620},{"type":46,"tag":250,"props":5093,"children":5094},{"style":268},[5095],{"type":52,"value":836},{"type":46,"tag":250,"props":5097,"children":5098},{"style":262},[5099],{"type":52,"value":5100},"replace\n",{"type":46,"tag":198,"props":5102,"children":5104},{"type":5103},"tip",[5105],{"type":46,"tag":55,"props":5106,"children":5107},{},[5108,5110,5116,5118,5124],{"type":52,"value":5109},"If you installed the Shopify MCP, ask Claude Code to list all available Shopify tables and preview the schema for each one. This helps you decide if you want to ingest additional tables like ",{"type":46,"tag":99,"props":5111,"children":5113},{"className":5112},[],[5114],{"type":52,"value":5115},"transactions",{"type":52,"value":5117}," or ",{"type":46,"tag":99,"props":5119,"children":5121},{"className":5120},[],[5122],{"type":52,"value":5123},"fulfillments",{"type":52,"value":106},{"type":46,"tag":4373,"props":5126,"children":5127},{},[],{"type":46,"tag":220,"props":5129,"children":5131},{"id":5130},"payments",[5132],{"type":52,"value":5133},"Payments",{"type":46,"tag":423,"props":5135,"children":5137},{":variants":5136,"group":5130},"[{\"id\":\"shopify-payments\",\"label\":\"Shopify Payments\"},{\"id\":\"stripe\",\"label\":\"Stripe\"}]",[5138,5179],{"type":46,"tag":429,"props":5139,"children":5140},{"v-slot:shopify-payments":7},[5141,5147,5167],{"type":46,"tag":4472,"props":5142,"children":5144},{"id":5143},"shopify-payments",[5145],{"type":52,"value":5146},"Shopify Payments",{"type":46,"tag":55,"props":5148,"children":5149},{},[5150,5152,5158,5159,5165],{"type":52,"value":5151},"If you use Shopify Payments, your payment data is already included in Shopify's order data - the ",{"type":46,"tag":99,"props":5153,"children":5155},{"className":5154},[],[5156],{"type":52,"value":5157},"financial_status",{"type":52,"value":151},{"type":46,"tag":99,"props":5160,"children":5162},{"className":5161},[],[5163],{"type":52,"value":5164},"total_price",{"type":52,"value":5166},", and transaction fields are all part of the orders you just ingested. No extra connection or assets needed here.",{"type":46,"tag":55,"props":5168,"children":5169},{},[5170,5172,5178],{"type":52,"value":5171},"The staging layer in Step 3 will pull payment details directly from ",{"type":46,"tag":99,"props":5173,"children":5175},{"className":5174},[],[5176],{"type":52,"value":5177},"raw.shopify_orders",{"type":52,"value":106},{"type":46,"tag":429,"props":5180,"children":5181},{"v-slot:stripe":7},[5182,5187,5192,5200,5221,5225,5271,5279,5844],{"type":46,"tag":4472,"props":5183,"children":5185},{"id":5184},"stripe",[5186],{"type":52,"value":4125},{"type":46,"tag":55,"props":5188,"children":5189},{},[5190],{"type":52,"value":5191},"If you use Stripe as a separate payment processor, you'll want to ingest charge, refund, and payout data separately. This gives you more granular financial data than what Shopify includes in its orders.",{"type":46,"tag":55,"props":5193,"children":5194},{},[5195],{"type":46,"tag":80,"props":5196,"children":5197},{},[5198],{"type":52,"value":5199},"Add the Stripe connection:",{"type":46,"tag":240,"props":5201,"children":5202},{"className":242,"code":477,"language":244,"meta":7,"style":7},[5203],{"type":46,"tag":99,"props":5204,"children":5205},{"__ignoreMap":7},[5206],{"type":46,"tag":250,"props":5207,"children":5208},{"class":252,"line":23},[5209,5213,5217],{"type":46,"tag":250,"props":5210,"children":5211},{"style":256},[5212],{"type":52,"value":305},{"type":46,"tag":250,"props":5214,"children":5215},{"style":262},[5216],{"type":52,"value":493},{"type":46,"tag":250,"props":5218,"children":5219},{"style":262},[5220],{"type":52,"value":498},{"type":46,"tag":55,"props":5222,"children":5223},{},[5224],{"type":52,"value":503},{"type":46,"tag":72,"props":5226,"children":5227},{},[5228,5241,5254],{"type":46,"tag":76,"props":5229,"children":5230},{},[5231,5235,5236],{"type":46,"tag":80,"props":5232,"children":5233},{},[5234],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":5237,"children":5239},{"className":5238},[],[5240],{"type":52,"value":5184},{"type":46,"tag":76,"props":5242,"children":5243},{},[5244,5248,5249],{"type":46,"tag":80,"props":5245,"children":5246},{},[5247],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":5250,"children":5252},{"className":5251},[],[5253],{"type":52,"value":5184},{"type":46,"tag":76,"props":5255,"children":5256},{},[5257,5262,5264,5270],{"type":46,"tag":80,"props":5258,"children":5259},{},[5260],{"type":52,"value":5261},"API key:",{"type":52,"value":5263}," your Stripe secret key (starts with ",{"type":46,"tag":99,"props":5265,"children":5267},{"className":5266},[],[5268],{"type":52,"value":5269},"sk_",{"type":52,"value":1005},{"type":46,"tag":55,"props":5272,"children":5273},{},[5274],{"type":46,"tag":80,"props":5275,"children":5276},{},[5277],{"type":52,"value":5278},"Create ingestor assets:",{"type":46,"tag":423,"props":5280,"children":5282},{":variants":5281},"[{\"id\":\"stripe-charges\",\"label\":\"Charges\"},{\"id\":\"stripe-refunds\",\"label\":\"Refunds\"},{\"id\":\"stripe-customers\",\"label\":\"Customers\"},{\"id\":\"stripe-payouts\",\"label\":\"Payouts\"}]",[5283,5425,5565,5704],{"type":46,"tag":429,"props":5284,"children":5285},{"v-slot:stripe-charges":7},[5286,5298],{"type":46,"tag":55,"props":5287,"children":5288},{},[5289],{"type":46,"tag":80,"props":5290,"children":5291},{},[5292],{"type":46,"tag":99,"props":5293,"children":5295},{"className":5294},[],[5296],{"type":52,"value":5297},"ecommerce\u002Fassets\u002Fstripe_charges.asset.yml",{"type":46,"tag":240,"props":5299,"children":5301},{"className":760,"code":5300,"language":762,"meta":7,"style":7},"name: raw.stripe_charges\ntype: ingestr\nparameters:\n  source_connection: stripe\n  source_table: charges\n  incremental_strategy: merge\n  incremental_key: created\n  primary_key: id\n",[5302],{"type":46,"tag":99,"props":5303,"children":5304},{"__ignoreMap":7},[5305,5321,5336,5347,5363,5379,5394,5410],{"type":46,"tag":250,"props":5306,"children":5307},{"class":252,"line":23},[5308,5312,5316],{"type":46,"tag":250,"props":5309,"children":5310},{"style":772},[5311],{"type":52,"value":831},{"type":46,"tag":250,"props":5313,"children":5314},{"style":268},[5315],{"type":52,"value":836},{"type":46,"tag":250,"props":5317,"children":5318},{"style":262},[5319],{"type":52,"value":5320},"raw.stripe_charges\n",{"type":46,"tag":250,"props":5322,"children":5323},{"class":252,"line":285},[5324,5328,5332],{"type":46,"tag":250,"props":5325,"children":5326},{"style":772},[5327],{"type":52,"value":4540},{"type":46,"tag":250,"props":5329,"children":5330},{"style":268},[5331],{"type":52,"value":836},{"type":46,"tag":250,"props":5333,"children":5334},{"style":262},[5335],{"type":52,"value":4549},{"type":46,"tag":250,"props":5337,"children":5338},{"class":252,"line":299},[5339,5343],{"type":46,"tag":250,"props":5340,"children":5341},{"style":772},[5342],{"type":52,"value":4557},{"type":46,"tag":250,"props":5344,"children":5345},{"style":268},[5346],{"type":52,"value":780},{"type":46,"tag":250,"props":5348,"children":5349},{"class":252,"line":807},[5350,5354,5358],{"type":46,"tag":250,"props":5351,"children":5352},{"style":772},[5353],{"type":52,"value":4569},{"type":46,"tag":250,"props":5355,"children":5356},{"style":268},[5357],{"type":52,"value":836},{"type":46,"tag":250,"props":5359,"children":5360},{"style":262},[5361],{"type":52,"value":5362},"stripe\n",{"type":46,"tag":250,"props":5364,"children":5365},{"class":252,"line":820},[5366,5370,5374],{"type":46,"tag":250,"props":5367,"children":5368},{"style":772},[5369],{"type":52,"value":4586},{"type":46,"tag":250,"props":5371,"children":5372},{"style":268},[5373],{"type":52,"value":836},{"type":46,"tag":250,"props":5375,"children":5376},{"style":262},[5377],{"type":52,"value":5378},"charges\n",{"type":46,"tag":250,"props":5380,"children":5381},{"class":252,"line":844},[5382,5386,5390],{"type":46,"tag":250,"props":5383,"children":5384},{"style":772},[5385],{"type":52,"value":4620},{"type":46,"tag":250,"props":5387,"children":5388},{"style":268},[5389],{"type":52,"value":836},{"type":46,"tag":250,"props":5391,"children":5392},{"style":262},[5393],{"type":52,"value":4629},{"type":46,"tag":250,"props":5395,"children":5396},{"class":252,"line":862},[5397,5401,5405],{"type":46,"tag":250,"props":5398,"children":5399},{"style":772},[5400],{"type":52,"value":4637},{"type":46,"tag":250,"props":5402,"children":5403},{"style":268},[5404],{"type":52,"value":836},{"type":46,"tag":250,"props":5406,"children":5407},{"style":262},[5408],{"type":52,"value":5409},"created\n",{"type":46,"tag":250,"props":5411,"children":5412},{"class":252,"line":11},[5413,5417,5421],{"type":46,"tag":250,"props":5414,"children":5415},{"style":772},[5416],{"type":52,"value":4655},{"type":46,"tag":250,"props":5418,"children":5419},{"style":268},[5420],{"type":52,"value":836},{"type":46,"tag":250,"props":5422,"children":5423},{"style":262},[5424],{"type":52,"value":4664},{"type":46,"tag":429,"props":5426,"children":5427},{"v-slot:stripe-refunds":7},[5428,5440],{"type":46,"tag":55,"props":5429,"children":5430},{},[5431],{"type":46,"tag":80,"props":5432,"children":5433},{},[5434],{"type":46,"tag":99,"props":5435,"children":5437},{"className":5436},[],[5438],{"type":52,"value":5439},"ecommerce\u002Fassets\u002Fstripe_refunds.asset.yml",{"type":46,"tag":240,"props":5441,"children":5443},{"className":760,"code":5442,"language":762,"meta":7,"style":7},"name: raw.stripe_refunds\ntype: ingestr\nparameters:\n  source_connection: stripe\n  source_table: refunds\n  incremental_strategy: merge\n  incremental_key: created\n  primary_key: id\n",[5444],{"type":46,"tag":99,"props":5445,"children":5446},{"__ignoreMap":7},[5447,5463,5478,5489,5504,5520,5535,5550],{"type":46,"tag":250,"props":5448,"children":5449},{"class":252,"line":23},[5450,5454,5458],{"type":46,"tag":250,"props":5451,"children":5452},{"style":772},[5453],{"type":52,"value":831},{"type":46,"tag":250,"props":5455,"children":5456},{"style":268},[5457],{"type":52,"value":836},{"type":46,"tag":250,"props":5459,"children":5460},{"style":262},[5461],{"type":52,"value":5462},"raw.stripe_refunds\n",{"type":46,"tag":250,"props":5464,"children":5465},{"class":252,"line":285},[5466,5470,5474],{"type":46,"tag":250,"props":5467,"children":5468},{"style":772},[5469],{"type":52,"value":4540},{"type":46,"tag":250,"props":5471,"children":5472},{"style":268},[5473],{"type":52,"value":836},{"type":46,"tag":250,"props":5475,"children":5476},{"style":262},[5477],{"type":52,"value":4549},{"type":46,"tag":250,"props":5479,"children":5480},{"class":252,"line":299},[5481,5485],{"type":46,"tag":250,"props":5482,"children":5483},{"style":772},[5484],{"type":52,"value":4557},{"type":46,"tag":250,"props":5486,"children":5487},{"style":268},[5488],{"type":52,"value":780},{"type":46,"tag":250,"props":5490,"children":5491},{"class":252,"line":807},[5492,5496,5500],{"type":46,"tag":250,"props":5493,"children":5494},{"style":772},[5495],{"type":52,"value":4569},{"type":46,"tag":250,"props":5497,"children":5498},{"style":268},[5499],{"type":52,"value":836},{"type":46,"tag":250,"props":5501,"children":5502},{"style":262},[5503],{"type":52,"value":5362},{"type":46,"tag":250,"props":5505,"children":5506},{"class":252,"line":820},[5507,5511,5515],{"type":46,"tag":250,"props":5508,"children":5509},{"style":772},[5510],{"type":52,"value":4586},{"type":46,"tag":250,"props":5512,"children":5513},{"style":268},[5514],{"type":52,"value":836},{"type":46,"tag":250,"props":5516,"children":5517},{"style":262},[5518],{"type":52,"value":5519},"refunds\n",{"type":46,"tag":250,"props":5521,"children":5522},{"class":252,"line":844},[5523,5527,5531],{"type":46,"tag":250,"props":5524,"children":5525},{"style":772},[5526],{"type":52,"value":4620},{"type":46,"tag":250,"props":5528,"children":5529},{"style":268},[5530],{"type":52,"value":836},{"type":46,"tag":250,"props":5532,"children":5533},{"style":262},[5534],{"type":52,"value":4629},{"type":46,"tag":250,"props":5536,"children":5537},{"class":252,"line":862},[5538,5542,5546],{"type":46,"tag":250,"props":5539,"children":5540},{"style":772},[5541],{"type":52,"value":4637},{"type":46,"tag":250,"props":5543,"children":5544},{"style":268},[5545],{"type":52,"value":836},{"type":46,"tag":250,"props":5547,"children":5548},{"style":262},[5549],{"type":52,"value":5409},{"type":46,"tag":250,"props":5551,"children":5552},{"class":252,"line":11},[5553,5557,5561],{"type":46,"tag":250,"props":5554,"children":5555},{"style":772},[5556],{"type":52,"value":4655},{"type":46,"tag":250,"props":5558,"children":5559},{"style":268},[5560],{"type":52,"value":836},{"type":46,"tag":250,"props":5562,"children":5563},{"style":262},[5564],{"type":52,"value":4664},{"type":46,"tag":429,"props":5566,"children":5567},{"v-slot:stripe-customers":7},[5568,5580],{"type":46,"tag":55,"props":5569,"children":5570},{},[5571],{"type":46,"tag":80,"props":5572,"children":5573},{},[5574],{"type":46,"tag":99,"props":5575,"children":5577},{"className":5576},[],[5578],{"type":52,"value":5579},"ecommerce\u002Fassets\u002Fstripe_customers.asset.yml",{"type":46,"tag":240,"props":5581,"children":5583},{"className":760,"code":5582,"language":762,"meta":7,"style":7},"name: raw.stripe_customers\ntype: ingestr\nparameters:\n  source_connection: stripe\n  source_table: customers\n  incremental_strategy: merge\n  incremental_key: created\n  primary_key: id\n",[5584],{"type":46,"tag":99,"props":5585,"children":5586},{"__ignoreMap":7},[5587,5603,5618,5629,5644,5659,5674,5689],{"type":46,"tag":250,"props":5588,"children":5589},{"class":252,"line":23},[5590,5594,5598],{"type":46,"tag":250,"props":5591,"children":5592},{"style":772},[5593],{"type":52,"value":831},{"type":46,"tag":250,"props":5595,"children":5596},{"style":268},[5597],{"type":52,"value":836},{"type":46,"tag":250,"props":5599,"children":5600},{"style":262},[5601],{"type":52,"value":5602},"raw.stripe_customers\n",{"type":46,"tag":250,"props":5604,"children":5605},{"class":252,"line":285},[5606,5610,5614],{"type":46,"tag":250,"props":5607,"children":5608},{"style":772},[5609],{"type":52,"value":4540},{"type":46,"tag":250,"props":5611,"children":5612},{"style":268},[5613],{"type":52,"value":836},{"type":46,"tag":250,"props":5615,"children":5616},{"style":262},[5617],{"type":52,"value":4549},{"type":46,"tag":250,"props":5619,"children":5620},{"class":252,"line":299},[5621,5625],{"type":46,"tag":250,"props":5622,"children":5623},{"style":772},[5624],{"type":52,"value":4557},{"type":46,"tag":250,"props":5626,"children":5627},{"style":268},[5628],{"type":52,"value":780},{"type":46,"tag":250,"props":5630,"children":5631},{"class":252,"line":807},[5632,5636,5640],{"type":46,"tag":250,"props":5633,"children":5634},{"style":772},[5635],{"type":52,"value":4569},{"type":46,"tag":250,"props":5637,"children":5638},{"style":268},[5639],{"type":52,"value":836},{"type":46,"tag":250,"props":5641,"children":5642},{"style":262},[5643],{"type":52,"value":5362},{"type":46,"tag":250,"props":5645,"children":5646},{"class":252,"line":820},[5647,5651,5655],{"type":46,"tag":250,"props":5648,"children":5649},{"style":772},[5650],{"type":52,"value":4586},{"type":46,"tag":250,"props":5652,"children":5653},{"style":268},[5654],{"type":52,"value":836},{"type":46,"tag":250,"props":5656,"children":5657},{"style":262},[5658],{"type":52,"value":4759},{"type":46,"tag":250,"props":5660,"children":5661},{"class":252,"line":844},[5662,5666,5670],{"type":46,"tag":250,"props":5663,"children":5664},{"style":772},[5665],{"type":52,"value":4620},{"type":46,"tag":250,"props":5667,"children":5668},{"style":268},[5669],{"type":52,"value":836},{"type":46,"tag":250,"props":5671,"children":5672},{"style":262},[5673],{"type":52,"value":4629},{"type":46,"tag":250,"props":5675,"children":5676},{"class":252,"line":862},[5677,5681,5685],{"type":46,"tag":250,"props":5678,"children":5679},{"style":772},[5680],{"type":52,"value":4637},{"type":46,"tag":250,"props":5682,"children":5683},{"style":268},[5684],{"type":52,"value":836},{"type":46,"tag":250,"props":5686,"children":5687},{"style":262},[5688],{"type":52,"value":5409},{"type":46,"tag":250,"props":5690,"children":5691},{"class":252,"line":11},[5692,5696,5700],{"type":46,"tag":250,"props":5693,"children":5694},{"style":772},[5695],{"type":52,"value":4655},{"type":46,"tag":250,"props":5697,"children":5698},{"style":268},[5699],{"type":52,"value":836},{"type":46,"tag":250,"props":5701,"children":5702},{"style":262},[5703],{"type":52,"value":4664},{"type":46,"tag":429,"props":5705,"children":5706},{"v-slot:stripe-payouts":7},[5707,5719],{"type":46,"tag":55,"props":5708,"children":5709},{},[5710],{"type":46,"tag":80,"props":5711,"children":5712},{},[5713],{"type":46,"tag":99,"props":5714,"children":5716},{"className":5715},[],[5717],{"type":52,"value":5718},"ecommerce\u002Fassets\u002Fstripe_payouts.asset.yml",{"type":46,"tag":240,"props":5720,"children":5722},{"className":760,"code":5721,"language":762,"meta":7,"style":7},"name: raw.stripe_payouts\ntype: ingestr\nparameters:\n  source_connection: stripe\n  source_table: payouts\n  incremental_strategy: merge\n  incremental_key: created\n  primary_key: id\n",[5723],{"type":46,"tag":99,"props":5724,"children":5725},{"__ignoreMap":7},[5726,5742,5757,5768,5783,5799,5814,5829],{"type":46,"tag":250,"props":5727,"children":5728},{"class":252,"line":23},[5729,5733,5737],{"type":46,"tag":250,"props":5730,"children":5731},{"style":772},[5732],{"type":52,"value":831},{"type":46,"tag":250,"props":5734,"children":5735},{"style":268},[5736],{"type":52,"value":836},{"type":46,"tag":250,"props":5738,"children":5739},{"style":262},[5740],{"type":52,"value":5741},"raw.stripe_payouts\n",{"type":46,"tag":250,"props":5743,"children":5744},{"class":252,"line":285},[5745,5749,5753],{"type":46,"tag":250,"props":5746,"children":5747},{"style":772},[5748],{"type":52,"value":4540},{"type":46,"tag":250,"props":5750,"children":5751},{"style":268},[5752],{"type":52,"value":836},{"type":46,"tag":250,"props":5754,"children":5755},{"style":262},[5756],{"type":52,"value":4549},{"type":46,"tag":250,"props":5758,"children":5759},{"class":252,"line":299},[5760,5764],{"type":46,"tag":250,"props":5761,"children":5762},{"style":772},[5763],{"type":52,"value":4557},{"type":46,"tag":250,"props":5765,"children":5766},{"style":268},[5767],{"type":52,"value":780},{"type":46,"tag":250,"props":5769,"children":5770},{"class":252,"line":807},[5771,5775,5779],{"type":46,"tag":250,"props":5772,"children":5773},{"style":772},[5774],{"type":52,"value":4569},{"type":46,"tag":250,"props":5776,"children":5777},{"style":268},[5778],{"type":52,"value":836},{"type":46,"tag":250,"props":5780,"children":5781},{"style":262},[5782],{"type":52,"value":5362},{"type":46,"tag":250,"props":5784,"children":5785},{"class":252,"line":820},[5786,5790,5794],{"type":46,"tag":250,"props":5787,"children":5788},{"style":772},[5789],{"type":52,"value":4586},{"type":46,"tag":250,"props":5791,"children":5792},{"style":268},[5793],{"type":52,"value":836},{"type":46,"tag":250,"props":5795,"children":5796},{"style":262},[5797],{"type":52,"value":5798},"payouts\n",{"type":46,"tag":250,"props":5800,"children":5801},{"class":252,"line":844},[5802,5806,5810],{"type":46,"tag":250,"props":5803,"children":5804},{"style":772},[5805],{"type":52,"value":4620},{"type":46,"tag":250,"props":5807,"children":5808},{"style":268},[5809],{"type":52,"value":836},{"type":46,"tag":250,"props":5811,"children":5812},{"style":262},[5813],{"type":52,"value":4629},{"type":46,"tag":250,"props":5815,"children":5816},{"class":252,"line":862},[5817,5821,5825],{"type":46,"tag":250,"props":5818,"children":5819},{"style":772},[5820],{"type":52,"value":4637},{"type":46,"tag":250,"props":5822,"children":5823},{"style":268},[5824],{"type":52,"value":836},{"type":46,"tag":250,"props":5826,"children":5827},{"style":262},[5828],{"type":52,"value":5409},{"type":46,"tag":250,"props":5830,"children":5831},{"class":252,"line":11},[5832,5836,5840],{"type":46,"tag":250,"props":5833,"children":5834},{"style":772},[5835],{"type":52,"value":4655},{"type":46,"tag":250,"props":5837,"children":5838},{"style":268},[5839],{"type":52,"value":836},{"type":46,"tag":250,"props":5841,"children":5842},{"style":262},[5843],{"type":52,"value":4664},{"type":46,"tag":198,"props":5845,"children":5846},{"type":5103},[5847],{"type":46,"tag":55,"props":5848,"children":5849},{},[5850,5852,5858,5859,5865,5867,5873],{"type":52,"value":5851},"The Stripe MCP can help you explore which tables and fields are available. Ask Claude Code \"what data can I pull from Stripe?\" to see tables like ",{"type":46,"tag":99,"props":5853,"children":5855},{"className":5854},[],[5856],{"type":52,"value":5857},"subscriptions",{"type":52,"value":151},{"type":46,"tag":99,"props":5860,"children":5862},{"className":5861},[],[5863],{"type":52,"value":5864},"disputes",{"type":52,"value":5866},", or ",{"type":46,"tag":99,"props":5868,"children":5870},{"className":5869},[],[5871],{"type":52,"value":5872},"balance_transactions",{"type":52,"value":106},{"type":46,"tag":4373,"props":5875,"children":5876},{},[],{"type":46,"tag":220,"props":5878,"children":5880},{"id":5879},"email-marketing",[5881],{"type":52,"value":5882},"Email Marketing",{"type":46,"tag":423,"props":5884,"children":5887},{":variants":5885,"group":5886},"[{\"id\":\"klaviyo\",\"label\":\"Klaviyo\"},{\"id\":\"hubspot\",\"label\":\"HubSpot\"}]","marketing",[5888,6278],{"type":46,"tag":429,"props":5889,"children":5890},{"v-slot:klaviyo":7},[5891,5896,5901,5909,5930,5934,5972,5979],{"type":46,"tag":4472,"props":5892,"children":5894},{"id":5893},"klaviyo",[5895],{"type":52,"value":4126},{"type":46,"tag":55,"props":5897,"children":5898},{},[5899],{"type":52,"value":5900},"Klaviyo covers the marketing side: how your email and SMS campaigns are performing and which customers are engaging.",{"type":46,"tag":55,"props":5902,"children":5903},{},[5904],{"type":46,"tag":80,"props":5905,"children":5906},{},[5907],{"type":52,"value":5908},"Add the Klaviyo connection:",{"type":46,"tag":240,"props":5910,"children":5911},{"className":242,"code":477,"language":244,"meta":7,"style":7},[5912],{"type":46,"tag":99,"props":5913,"children":5914},{"__ignoreMap":7},[5915],{"type":46,"tag":250,"props":5916,"children":5917},{"class":252,"line":23},[5918,5922,5926],{"type":46,"tag":250,"props":5919,"children":5920},{"style":256},[5921],{"type":52,"value":305},{"type":46,"tag":250,"props":5923,"children":5924},{"style":262},[5925],{"type":52,"value":493},{"type":46,"tag":250,"props":5927,"children":5928},{"style":262},[5929],{"type":52,"value":498},{"type":46,"tag":55,"props":5931,"children":5932},{},[5933],{"type":52,"value":503},{"type":46,"tag":72,"props":5935,"children":5936},{},[5937,5950,5963],{"type":46,"tag":76,"props":5938,"children":5939},{},[5940,5944,5945],{"type":46,"tag":80,"props":5941,"children":5942},{},[5943],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":5946,"children":5948},{"className":5947},[],[5949],{"type":52,"value":5893},{"type":46,"tag":76,"props":5951,"children":5952},{},[5953,5957,5958],{"type":46,"tag":80,"props":5954,"children":5955},{},[5956],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":5959,"children":5961},{"className":5960},[],[5962],{"type":52,"value":5893},{"type":46,"tag":76,"props":5964,"children":5965},{},[5966,5970],{"type":46,"tag":80,"props":5967,"children":5968},{},[5969],{"type":52,"value":5261},{"type":52,"value":5971}," your Klaviyo private API key",{"type":46,"tag":55,"props":5973,"children":5974},{},[5975],{"type":46,"tag":80,"props":5976,"children":5977},{},[5978],{"type":52,"value":5278},{"type":46,"tag":423,"props":5980,"children":5982},{":variants":5981},"[{\"id\":\"klaviyo-campaigns\",\"label\":\"Campaigns\"},{\"id\":\"klaviyo-flows\",\"label\":\"Flows\"},{\"id\":\"klaviyo-metrics\",\"label\":\"Metrics\"}]",[5983,6082,6180],{"type":46,"tag":429,"props":5984,"children":5985},{"v-slot:klaviyo-campaigns":7},[5986],{"type":46,"tag":240,"props":5987,"children":5989},{"className":760,"code":5988,"language":762,"meta":7,"style":7},"name: raw.klaviyo_campaigns\ntype: ingestr\nparameters:\n  source_connection: klaviyo\n  source_table: campaigns\n  incremental_strategy: replace\n",[5990],{"type":46,"tag":99,"props":5991,"children":5992},{"__ignoreMap":7},[5993,6009,6024,6035,6051,6067],{"type":46,"tag":250,"props":5994,"children":5995},{"class":252,"line":23},[5996,6000,6004],{"type":46,"tag":250,"props":5997,"children":5998},{"style":772},[5999],{"type":52,"value":831},{"type":46,"tag":250,"props":6001,"children":6002},{"style":268},[6003],{"type":52,"value":836},{"type":46,"tag":250,"props":6005,"children":6006},{"style":262},[6007],{"type":52,"value":6008},"raw.klaviyo_campaigns\n",{"type":46,"tag":250,"props":6010,"children":6011},{"class":252,"line":285},[6012,6016,6020],{"type":46,"tag":250,"props":6013,"children":6014},{"style":772},[6015],{"type":52,"value":4540},{"type":46,"tag":250,"props":6017,"children":6018},{"style":268},[6019],{"type":52,"value":836},{"type":46,"tag":250,"props":6021,"children":6022},{"style":262},[6023],{"type":52,"value":4549},{"type":46,"tag":250,"props":6025,"children":6026},{"class":252,"line":299},[6027,6031],{"type":46,"tag":250,"props":6028,"children":6029},{"style":772},[6030],{"type":52,"value":4557},{"type":46,"tag":250,"props":6032,"children":6033},{"style":268},[6034],{"type":52,"value":780},{"type":46,"tag":250,"props":6036,"children":6037},{"class":252,"line":807},[6038,6042,6046],{"type":46,"tag":250,"props":6039,"children":6040},{"style":772},[6041],{"type":52,"value":4569},{"type":46,"tag":250,"props":6043,"children":6044},{"style":268},[6045],{"type":52,"value":836},{"type":46,"tag":250,"props":6047,"children":6048},{"style":262},[6049],{"type":52,"value":6050},"klaviyo\n",{"type":46,"tag":250,"props":6052,"children":6053},{"class":252,"line":820},[6054,6058,6062],{"type":46,"tag":250,"props":6055,"children":6056},{"style":772},[6057],{"type":52,"value":4586},{"type":46,"tag":250,"props":6059,"children":6060},{"style":268},[6061],{"type":52,"value":836},{"type":46,"tag":250,"props":6063,"children":6064},{"style":262},[6065],{"type":52,"value":6066},"campaigns\n",{"type":46,"tag":250,"props":6068,"children":6069},{"class":252,"line":844},[6070,6074,6078],{"type":46,"tag":250,"props":6071,"children":6072},{"style":772},[6073],{"type":52,"value":4620},{"type":46,"tag":250,"props":6075,"children":6076},{"style":268},[6077],{"type":52,"value":836},{"type":46,"tag":250,"props":6079,"children":6080},{"style":262},[6081],{"type":52,"value":5100},{"type":46,"tag":429,"props":6083,"children":6084},{"v-slot:klaviyo-flows":7},[6085],{"type":46,"tag":240,"props":6086,"children":6088},{"className":760,"code":6087,"language":762,"meta":7,"style":7},"name: raw.klaviyo_flows\ntype: ingestr\nparameters:\n  source_connection: klaviyo\n  source_table: flows\n  incremental_strategy: replace\n",[6089],{"type":46,"tag":99,"props":6090,"children":6091},{"__ignoreMap":7},[6092,6108,6123,6134,6149,6165],{"type":46,"tag":250,"props":6093,"children":6094},{"class":252,"line":23},[6095,6099,6103],{"type":46,"tag":250,"props":6096,"children":6097},{"style":772},[6098],{"type":52,"value":831},{"type":46,"tag":250,"props":6100,"children":6101},{"style":268},[6102],{"type":52,"value":836},{"type":46,"tag":250,"props":6104,"children":6105},{"style":262},[6106],{"type":52,"value":6107},"raw.klaviyo_flows\n",{"type":46,"tag":250,"props":6109,"children":6110},{"class":252,"line":285},[6111,6115,6119],{"type":46,"tag":250,"props":6112,"children":6113},{"style":772},[6114],{"type":52,"value":4540},{"type":46,"tag":250,"props":6116,"children":6117},{"style":268},[6118],{"type":52,"value":836},{"type":46,"tag":250,"props":6120,"children":6121},{"style":262},[6122],{"type":52,"value":4549},{"type":46,"tag":250,"props":6124,"children":6125},{"class":252,"line":299},[6126,6130],{"type":46,"tag":250,"props":6127,"children":6128},{"style":772},[6129],{"type":52,"value":4557},{"type":46,"tag":250,"props":6131,"children":6132},{"style":268},[6133],{"type":52,"value":780},{"type":46,"tag":250,"props":6135,"children":6136},{"class":252,"line":807},[6137,6141,6145],{"type":46,"tag":250,"props":6138,"children":6139},{"style":772},[6140],{"type":52,"value":4569},{"type":46,"tag":250,"props":6142,"children":6143},{"style":268},[6144],{"type":52,"value":836},{"type":46,"tag":250,"props":6146,"children":6147},{"style":262},[6148],{"type":52,"value":6050},{"type":46,"tag":250,"props":6150,"children":6151},{"class":252,"line":820},[6152,6156,6160],{"type":46,"tag":250,"props":6153,"children":6154},{"style":772},[6155],{"type":52,"value":4586},{"type":46,"tag":250,"props":6157,"children":6158},{"style":268},[6159],{"type":52,"value":836},{"type":46,"tag":250,"props":6161,"children":6162},{"style":262},[6163],{"type":52,"value":6164},"flows\n",{"type":46,"tag":250,"props":6166,"children":6167},{"class":252,"line":844},[6168,6172,6176],{"type":46,"tag":250,"props":6169,"children":6170},{"style":772},[6171],{"type":52,"value":4620},{"type":46,"tag":250,"props":6173,"children":6174},{"style":268},[6175],{"type":52,"value":836},{"type":46,"tag":250,"props":6177,"children":6178},{"style":262},[6179],{"type":52,"value":5100},{"type":46,"tag":429,"props":6181,"children":6182},{"v-slot:klaviyo-metrics":7},[6183],{"type":46,"tag":240,"props":6184,"children":6186},{"className":760,"code":6185,"language":762,"meta":7,"style":7},"name: raw.klaviyo_metrics\ntype: ingestr\nparameters:\n  source_connection: klaviyo\n  source_table: metrics\n  incremental_strategy: replace\n",[6187],{"type":46,"tag":99,"props":6188,"children":6189},{"__ignoreMap":7},[6190,6206,6221,6232,6247,6263],{"type":46,"tag":250,"props":6191,"children":6192},{"class":252,"line":23},[6193,6197,6201],{"type":46,"tag":250,"props":6194,"children":6195},{"style":772},[6196],{"type":52,"value":831},{"type":46,"tag":250,"props":6198,"children":6199},{"style":268},[6200],{"type":52,"value":836},{"type":46,"tag":250,"props":6202,"children":6203},{"style":262},[6204],{"type":52,"value":6205},"raw.klaviyo_metrics\n",{"type":46,"tag":250,"props":6207,"children":6208},{"class":252,"line":285},[6209,6213,6217],{"type":46,"tag":250,"props":6210,"children":6211},{"style":772},[6212],{"type":52,"value":4540},{"type":46,"tag":250,"props":6214,"children":6215},{"style":268},[6216],{"type":52,"value":836},{"type":46,"tag":250,"props":6218,"children":6219},{"style":262},[6220],{"type":52,"value":4549},{"type":46,"tag":250,"props":6222,"children":6223},{"class":252,"line":299},[6224,6228],{"type":46,"tag":250,"props":6225,"children":6226},{"style":772},[6227],{"type":52,"value":4557},{"type":46,"tag":250,"props":6229,"children":6230},{"style":268},[6231],{"type":52,"value":780},{"type":46,"tag":250,"props":6233,"children":6234},{"class":252,"line":807},[6235,6239,6243],{"type":46,"tag":250,"props":6236,"children":6237},{"style":772},[6238],{"type":52,"value":4569},{"type":46,"tag":250,"props":6240,"children":6241},{"style":268},[6242],{"type":52,"value":836},{"type":46,"tag":250,"props":6244,"children":6245},{"style":262},[6246],{"type":52,"value":6050},{"type":46,"tag":250,"props":6248,"children":6249},{"class":252,"line":820},[6250,6254,6258],{"type":46,"tag":250,"props":6251,"children":6252},{"style":772},[6253],{"type":52,"value":4586},{"type":46,"tag":250,"props":6255,"children":6256},{"style":268},[6257],{"type":52,"value":836},{"type":46,"tag":250,"props":6259,"children":6260},{"style":262},[6261],{"type":52,"value":6262},"metrics\n",{"type":46,"tag":250,"props":6264,"children":6265},{"class":252,"line":844},[6266,6270,6274],{"type":46,"tag":250,"props":6267,"children":6268},{"style":772},[6269],{"type":52,"value":4620},{"type":46,"tag":250,"props":6271,"children":6272},{"style":268},[6273],{"type":52,"value":836},{"type":46,"tag":250,"props":6275,"children":6276},{"style":262},[6277],{"type":52,"value":5100},{"type":46,"tag":429,"props":6279,"children":6280},{"v-slot:hubspot":7},[6281,6286,6291,6299,6320,6324,6362,6369],{"type":46,"tag":4472,"props":6282,"children":6284},{"id":6283},"hubspot",[6285],{"type":52,"value":4127},{"type":46,"tag":55,"props":6287,"children":6288},{},[6289],{"type":52,"value":6290},"HubSpot covers your CRM and marketing data: contacts, deals, email campaigns, and marketing activity.",{"type":46,"tag":55,"props":6292,"children":6293},{},[6294],{"type":46,"tag":80,"props":6295,"children":6296},{},[6297],{"type":52,"value":6298},"Add the HubSpot connection:",{"type":46,"tag":240,"props":6300,"children":6301},{"className":242,"code":477,"language":244,"meta":7,"style":7},[6302],{"type":46,"tag":99,"props":6303,"children":6304},{"__ignoreMap":7},[6305],{"type":46,"tag":250,"props":6306,"children":6307},{"class":252,"line":23},[6308,6312,6316],{"type":46,"tag":250,"props":6309,"children":6310},{"style":256},[6311],{"type":52,"value":305},{"type":46,"tag":250,"props":6313,"children":6314},{"style":262},[6315],{"type":52,"value":493},{"type":46,"tag":250,"props":6317,"children":6318},{"style":262},[6319],{"type":52,"value":498},{"type":46,"tag":55,"props":6321,"children":6322},{},[6323],{"type":52,"value":503},{"type":46,"tag":72,"props":6325,"children":6326},{},[6327,6340,6353],{"type":46,"tag":76,"props":6328,"children":6329},{},[6330,6334,6335],{"type":46,"tag":80,"props":6331,"children":6332},{},[6333],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":6336,"children":6338},{"className":6337},[],[6339],{"type":52,"value":6283},{"type":46,"tag":76,"props":6341,"children":6342},{},[6343,6347,6348],{"type":46,"tag":80,"props":6344,"children":6345},{},[6346],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":6349,"children":6351},{"className":6350},[],[6352],{"type":52,"value":6283},{"type":46,"tag":76,"props":6354,"children":6355},{},[6356,6360],{"type":46,"tag":80,"props":6357,"children":6358},{},[6359],{"type":52,"value":5261},{"type":52,"value":6361}," your HubSpot private app access token",{"type":46,"tag":55,"props":6363,"children":6364},{},[6365],{"type":46,"tag":80,"props":6366,"children":6367},{},[6368],{"type":52,"value":5278},{"type":46,"tag":423,"props":6370,"children":6372},{":variants":6371},"[{\"id\":\"hubspot-contacts\",\"label\":\"Contacts\"},{\"id\":\"hubspot-deals\",\"label\":\"Deals\"},{\"id\":\"hubspot-campaigns\",\"label\":\"Campaigns\"}]",[6373,6503,6631],{"type":46,"tag":429,"props":6374,"children":6375},{"v-slot:hubspot-contacts":7},[6376],{"type":46,"tag":240,"props":6377,"children":6379},{"className":760,"code":6378,"language":762,"meta":7,"style":7},"name: raw.hubspot_contacts\ntype: ingestr\nparameters:\n  source_connection: hubspot\n  source_table: contacts\n  incremental_strategy: merge\n  incremental_key: updatedAt\n  primary_key: id\n",[6380],{"type":46,"tag":99,"props":6381,"children":6382},{"__ignoreMap":7},[6383,6399,6414,6425,6441,6457,6472,6488],{"type":46,"tag":250,"props":6384,"children":6385},{"class":252,"line":23},[6386,6390,6394],{"type":46,"tag":250,"props":6387,"children":6388},{"style":772},[6389],{"type":52,"value":831},{"type":46,"tag":250,"props":6391,"children":6392},{"style":268},[6393],{"type":52,"value":836},{"type":46,"tag":250,"props":6395,"children":6396},{"style":262},[6397],{"type":52,"value":6398},"raw.hubspot_contacts\n",{"type":46,"tag":250,"props":6400,"children":6401},{"class":252,"line":285},[6402,6406,6410],{"type":46,"tag":250,"props":6403,"children":6404},{"style":772},[6405],{"type":52,"value":4540},{"type":46,"tag":250,"props":6407,"children":6408},{"style":268},[6409],{"type":52,"value":836},{"type":46,"tag":250,"props":6411,"children":6412},{"style":262},[6413],{"type":52,"value":4549},{"type":46,"tag":250,"props":6415,"children":6416},{"class":252,"line":299},[6417,6421],{"type":46,"tag":250,"props":6418,"children":6419},{"style":772},[6420],{"type":52,"value":4557},{"type":46,"tag":250,"props":6422,"children":6423},{"style":268},[6424],{"type":52,"value":780},{"type":46,"tag":250,"props":6426,"children":6427},{"class":252,"line":807},[6428,6432,6436],{"type":46,"tag":250,"props":6429,"children":6430},{"style":772},[6431],{"type":52,"value":4569},{"type":46,"tag":250,"props":6433,"children":6434},{"style":268},[6435],{"type":52,"value":836},{"type":46,"tag":250,"props":6437,"children":6438},{"style":262},[6439],{"type":52,"value":6440},"hubspot\n",{"type":46,"tag":250,"props":6442,"children":6443},{"class":252,"line":820},[6444,6448,6452],{"type":46,"tag":250,"props":6445,"children":6446},{"style":772},[6447],{"type":52,"value":4586},{"type":46,"tag":250,"props":6449,"children":6450},{"style":268},[6451],{"type":52,"value":836},{"type":46,"tag":250,"props":6453,"children":6454},{"style":262},[6455],{"type":52,"value":6456},"contacts\n",{"type":46,"tag":250,"props":6458,"children":6459},{"class":252,"line":844},[6460,6464,6468],{"type":46,"tag":250,"props":6461,"children":6462},{"style":772},[6463],{"type":52,"value":4620},{"type":46,"tag":250,"props":6465,"children":6466},{"style":268},[6467],{"type":52,"value":836},{"type":46,"tag":250,"props":6469,"children":6470},{"style":262},[6471],{"type":52,"value":4629},{"type":46,"tag":250,"props":6473,"children":6474},{"class":252,"line":862},[6475,6479,6483],{"type":46,"tag":250,"props":6476,"children":6477},{"style":772},[6478],{"type":52,"value":4637},{"type":46,"tag":250,"props":6480,"children":6481},{"style":268},[6482],{"type":52,"value":836},{"type":46,"tag":250,"props":6484,"children":6485},{"style":262},[6486],{"type":52,"value":6487},"updatedAt\n",{"type":46,"tag":250,"props":6489,"children":6490},{"class":252,"line":11},[6491,6495,6499],{"type":46,"tag":250,"props":6492,"children":6493},{"style":772},[6494],{"type":52,"value":4655},{"type":46,"tag":250,"props":6496,"children":6497},{"style":268},[6498],{"type":52,"value":836},{"type":46,"tag":250,"props":6500,"children":6501},{"style":262},[6502],{"type":52,"value":4664},{"type":46,"tag":429,"props":6504,"children":6505},{"v-slot:hubspot-deals":7},[6506],{"type":46,"tag":240,"props":6507,"children":6509},{"className":760,"code":6508,"language":762,"meta":7,"style":7},"name: raw.hubspot_deals\ntype: ingestr\nparameters:\n  source_connection: hubspot\n  source_table: deals\n  incremental_strategy: merge\n  incremental_key: updatedAt\n  primary_key: id\n",[6510],{"type":46,"tag":99,"props":6511,"children":6512},{"__ignoreMap":7},[6513,6529,6544,6555,6570,6586,6601,6616],{"type":46,"tag":250,"props":6514,"children":6515},{"class":252,"line":23},[6516,6520,6524],{"type":46,"tag":250,"props":6517,"children":6518},{"style":772},[6519],{"type":52,"value":831},{"type":46,"tag":250,"props":6521,"children":6522},{"style":268},[6523],{"type":52,"value":836},{"type":46,"tag":250,"props":6525,"children":6526},{"style":262},[6527],{"type":52,"value":6528},"raw.hubspot_deals\n",{"type":46,"tag":250,"props":6530,"children":6531},{"class":252,"line":285},[6532,6536,6540],{"type":46,"tag":250,"props":6533,"children":6534},{"style":772},[6535],{"type":52,"value":4540},{"type":46,"tag":250,"props":6537,"children":6538},{"style":268},[6539],{"type":52,"value":836},{"type":46,"tag":250,"props":6541,"children":6542},{"style":262},[6543],{"type":52,"value":4549},{"type":46,"tag":250,"props":6545,"children":6546},{"class":252,"line":299},[6547,6551],{"type":46,"tag":250,"props":6548,"children":6549},{"style":772},[6550],{"type":52,"value":4557},{"type":46,"tag":250,"props":6552,"children":6553},{"style":268},[6554],{"type":52,"value":780},{"type":46,"tag":250,"props":6556,"children":6557},{"class":252,"line":807},[6558,6562,6566],{"type":46,"tag":250,"props":6559,"children":6560},{"style":772},[6561],{"type":52,"value":4569},{"type":46,"tag":250,"props":6563,"children":6564},{"style":268},[6565],{"type":52,"value":836},{"type":46,"tag":250,"props":6567,"children":6568},{"style":262},[6569],{"type":52,"value":6440},{"type":46,"tag":250,"props":6571,"children":6572},{"class":252,"line":820},[6573,6577,6581],{"type":46,"tag":250,"props":6574,"children":6575},{"style":772},[6576],{"type":52,"value":4586},{"type":46,"tag":250,"props":6578,"children":6579},{"style":268},[6580],{"type":52,"value":836},{"type":46,"tag":250,"props":6582,"children":6583},{"style":262},[6584],{"type":52,"value":6585},"deals\n",{"type":46,"tag":250,"props":6587,"children":6588},{"class":252,"line":844},[6589,6593,6597],{"type":46,"tag":250,"props":6590,"children":6591},{"style":772},[6592],{"type":52,"value":4620},{"type":46,"tag":250,"props":6594,"children":6595},{"style":268},[6596],{"type":52,"value":836},{"type":46,"tag":250,"props":6598,"children":6599},{"style":262},[6600],{"type":52,"value":4629},{"type":46,"tag":250,"props":6602,"children":6603},{"class":252,"line":862},[6604,6608,6612],{"type":46,"tag":250,"props":6605,"children":6606},{"style":772},[6607],{"type":52,"value":4637},{"type":46,"tag":250,"props":6609,"children":6610},{"style":268},[6611],{"type":52,"value":836},{"type":46,"tag":250,"props":6613,"children":6614},{"style":262},[6615],{"type":52,"value":6487},{"type":46,"tag":250,"props":6617,"children":6618},{"class":252,"line":11},[6619,6623,6627],{"type":46,"tag":250,"props":6620,"children":6621},{"style":772},[6622],{"type":52,"value":4655},{"type":46,"tag":250,"props":6624,"children":6625},{"style":268},[6626],{"type":52,"value":836},{"type":46,"tag":250,"props":6628,"children":6629},{"style":262},[6630],{"type":52,"value":4664},{"type":46,"tag":429,"props":6632,"children":6633},{"v-slot:hubspot-campaigns":7},[6634],{"type":46,"tag":240,"props":6635,"children":6637},{"className":760,"code":6636,"language":762,"meta":7,"style":7},"name: raw.hubspot_campaigns\ntype: ingestr\nparameters:\n  source_connection: hubspot\n  source_table: campaigns\n  incremental_strategy: replace\n",[6638],{"type":46,"tag":99,"props":6639,"children":6640},{"__ignoreMap":7},[6641,6657,6672,6683,6698,6713],{"type":46,"tag":250,"props":6642,"children":6643},{"class":252,"line":23},[6644,6648,6652],{"type":46,"tag":250,"props":6645,"children":6646},{"style":772},[6647],{"type":52,"value":831},{"type":46,"tag":250,"props":6649,"children":6650},{"style":268},[6651],{"type":52,"value":836},{"type":46,"tag":250,"props":6653,"children":6654},{"style":262},[6655],{"type":52,"value":6656},"raw.hubspot_campaigns\n",{"type":46,"tag":250,"props":6658,"children":6659},{"class":252,"line":285},[6660,6664,6668],{"type":46,"tag":250,"props":6661,"children":6662},{"style":772},[6663],{"type":52,"value":4540},{"type":46,"tag":250,"props":6665,"children":6666},{"style":268},[6667],{"type":52,"value":836},{"type":46,"tag":250,"props":6669,"children":6670},{"style":262},[6671],{"type":52,"value":4549},{"type":46,"tag":250,"props":6673,"children":6674},{"class":252,"line":299},[6675,6679],{"type":46,"tag":250,"props":6676,"children":6677},{"style":772},[6678],{"type":52,"value":4557},{"type":46,"tag":250,"props":6680,"children":6681},{"style":268},[6682],{"type":52,"value":780},{"type":46,"tag":250,"props":6684,"children":6685},{"class":252,"line":807},[6686,6690,6694],{"type":46,"tag":250,"props":6687,"children":6688},{"style":772},[6689],{"type":52,"value":4569},{"type":46,"tag":250,"props":6691,"children":6692},{"style":268},[6693],{"type":52,"value":836},{"type":46,"tag":250,"props":6695,"children":6696},{"style":262},[6697],{"type":52,"value":6440},{"type":46,"tag":250,"props":6699,"children":6700},{"class":252,"line":820},[6701,6705,6709],{"type":46,"tag":250,"props":6702,"children":6703},{"style":772},[6704],{"type":52,"value":4586},{"type":46,"tag":250,"props":6706,"children":6707},{"style":268},[6708],{"type":52,"value":836},{"type":46,"tag":250,"props":6710,"children":6711},{"style":262},[6712],{"type":52,"value":6066},{"type":46,"tag":250,"props":6714,"children":6715},{"class":252,"line":844},[6716,6720,6724],{"type":46,"tag":250,"props":6717,"children":6718},{"style":772},[6719],{"type":52,"value":4620},{"type":46,"tag":250,"props":6721,"children":6722},{"style":268},[6723],{"type":52,"value":836},{"type":46,"tag":250,"props":6725,"children":6726},{"style":262},[6727],{"type":52,"value":5100},{"type":46,"tag":4373,"props":6729,"children":6730},{},[],{"type":46,"tag":220,"props":6732,"children":6734},{"id":6733},"advertising",[6735],{"type":52,"value":6736},"Advertising",{"type":46,"tag":423,"props":6738,"children":6741},{":variants":6739,"group":6740},"[{\"id\":\"facebook-ads\",\"label\":\"Facebook Ads\"},{\"id\":\"google-ads\",\"label\":\"Google Ads\"},{\"id\":\"tiktok-ads\",\"label\":\"TikTok Ads\"}]","ads",[6742,7084,7418],{"type":46,"tag":429,"props":6743,"children":6744},{"v-slot:facebook-ads":7},[6745,6750,6755,6763,6784,6788,6845,6852],{"type":46,"tag":4472,"props":6746,"children":6748},{"id":6747},"facebook-ads",[6749],{"type":52,"value":4128},{"type":46,"tag":55,"props":6751,"children":6752},{},[6753],{"type":52,"value":6754},"Facebook Ads shows you what you're spending on acquisition across Facebook and Instagram.",{"type":46,"tag":55,"props":6756,"children":6757},{},[6758],{"type":46,"tag":80,"props":6759,"children":6760},{},[6761],{"type":52,"value":6762},"Add the connection:",{"type":46,"tag":240,"props":6764,"children":6765},{"className":242,"code":477,"language":244,"meta":7,"style":7},[6766],{"type":46,"tag":99,"props":6767,"children":6768},{"__ignoreMap":7},[6769],{"type":46,"tag":250,"props":6770,"children":6771},{"class":252,"line":23},[6772,6776,6780],{"type":46,"tag":250,"props":6773,"children":6774},{"style":256},[6775],{"type":52,"value":305},{"type":46,"tag":250,"props":6777,"children":6778},{"style":262},[6779],{"type":52,"value":493},{"type":46,"tag":250,"props":6781,"children":6782},{"style":262},[6783],{"type":52,"value":498},{"type":46,"tag":55,"props":6785,"children":6786},{},[6787],{"type":52,"value":503},{"type":46,"tag":72,"props":6789,"children":6790},{},[6791,6805,6818,6835],{"type":46,"tag":76,"props":6792,"children":6793},{},[6794,6798,6799],{"type":46,"tag":80,"props":6795,"children":6796},{},[6797],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":6800,"children":6802},{"className":6801},[],[6803],{"type":52,"value":6804},"facebook_ads",{"type":46,"tag":76,"props":6806,"children":6807},{},[6808,6812,6813],{"type":46,"tag":80,"props":6809,"children":6810},{},[6811],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":6814,"children":6816},{"className":6815},[],[6817],{"type":52,"value":6804},{"type":46,"tag":76,"props":6819,"children":6820},{},[6821,6826,6828],{"type":46,"tag":80,"props":6822,"children":6823},{},[6824],{"type":52,"value":6825},"Access token:",{"type":52,"value":6827}," your ",{"type":46,"tag":88,"props":6829,"children":6832},{"href":6830,"rel":6831},"https:\u002F\u002Fdevelopers.facebook.com\u002Fdocs\u002Fmarketing-api\u002Foverview\u002Fauthorization",[92],[6833],{"type":52,"value":6834},"Facebook Marketing API access token",{"type":46,"tag":76,"props":6836,"children":6837},{},[6838,6843],{"type":46,"tag":80,"props":6839,"children":6840},{},[6841],{"type":52,"value":6842},"Account IDs:",{"type":52,"value":6844}," your ad account ID(s), comma-separated",{"type":46,"tag":55,"props":6846,"children":6847},{},[6848],{"type":46,"tag":80,"props":6849,"children":6850},{},[6851],{"type":52,"value":5278},{"type":46,"tag":423,"props":6853,"children":6855},{":variants":6854},"[{\"id\":\"fb-campaigns\",\"label\":\"Campaigns\"},{\"id\":\"fb-insights\",\"label\":\"Ad Insights\"}]",[6856,6954],{"type":46,"tag":429,"props":6857,"children":6858},{"v-slot:fb-campaigns":7},[6859],{"type":46,"tag":240,"props":6860,"children":6862},{"className":760,"code":6861,"language":762,"meta":7,"style":7},"name: raw.facebook_campaigns\ntype: ingestr\nparameters:\n  source_connection: facebook_ads\n  source_table: campaigns\n  incremental_strategy: replace\n",[6863],{"type":46,"tag":99,"props":6864,"children":6865},{"__ignoreMap":7},[6866,6882,6897,6908,6924,6939],{"type":46,"tag":250,"props":6867,"children":6868},{"class":252,"line":23},[6869,6873,6877],{"type":46,"tag":250,"props":6870,"children":6871},{"style":772},[6872],{"type":52,"value":831},{"type":46,"tag":250,"props":6874,"children":6875},{"style":268},[6876],{"type":52,"value":836},{"type":46,"tag":250,"props":6878,"children":6879},{"style":262},[6880],{"type":52,"value":6881},"raw.facebook_campaigns\n",{"type":46,"tag":250,"props":6883,"children":6884},{"class":252,"line":285},[6885,6889,6893],{"type":46,"tag":250,"props":6886,"children":6887},{"style":772},[6888],{"type":52,"value":4540},{"type":46,"tag":250,"props":6890,"children":6891},{"style":268},[6892],{"type":52,"value":836},{"type":46,"tag":250,"props":6894,"children":6895},{"style":262},[6896],{"type":52,"value":4549},{"type":46,"tag":250,"props":6898,"children":6899},{"class":252,"line":299},[6900,6904],{"type":46,"tag":250,"props":6901,"children":6902},{"style":772},[6903],{"type":52,"value":4557},{"type":46,"tag":250,"props":6905,"children":6906},{"style":268},[6907],{"type":52,"value":780},{"type":46,"tag":250,"props":6909,"children":6910},{"class":252,"line":807},[6911,6915,6919],{"type":46,"tag":250,"props":6912,"children":6913},{"style":772},[6914],{"type":52,"value":4569},{"type":46,"tag":250,"props":6916,"children":6917},{"style":268},[6918],{"type":52,"value":836},{"type":46,"tag":250,"props":6920,"children":6921},{"style":262},[6922],{"type":52,"value":6923},"facebook_ads\n",{"type":46,"tag":250,"props":6925,"children":6926},{"class":252,"line":820},[6927,6931,6935],{"type":46,"tag":250,"props":6928,"children":6929},{"style":772},[6930],{"type":52,"value":4586},{"type":46,"tag":250,"props":6932,"children":6933},{"style":268},[6934],{"type":52,"value":836},{"type":46,"tag":250,"props":6936,"children":6937},{"style":262},[6938],{"type":52,"value":6066},{"type":46,"tag":250,"props":6940,"children":6941},{"class":252,"line":844},[6942,6946,6950],{"type":46,"tag":250,"props":6943,"children":6944},{"style":772},[6945],{"type":52,"value":4620},{"type":46,"tag":250,"props":6947,"children":6948},{"style":268},[6949],{"type":52,"value":836},{"type":46,"tag":250,"props":6951,"children":6952},{"style":262},[6953],{"type":52,"value":5100},{"type":46,"tag":429,"props":6955,"children":6956},{"v-slot:fb-insights":7},[6957],{"type":46,"tag":240,"props":6958,"children":6960},{"className":760,"code":6959,"language":762,"meta":7,"style":7},"name: raw.facebook_ad_insights\ntype: ingestr\nparameters:\n  source_connection: facebook_ads\n  source_table: insights\n  incremental_strategy: merge\n  incremental_key: date_start\n  primary_key: \"date_start,campaign_id\"\n",[6961],{"type":46,"tag":99,"props":6962,"children":6963},{"__ignoreMap":7},[6964,6980,6995,7006,7021,7037,7052,7068],{"type":46,"tag":250,"props":6965,"children":6966},{"class":252,"line":23},[6967,6971,6975],{"type":46,"tag":250,"props":6968,"children":6969},{"style":772},[6970],{"type":52,"value":831},{"type":46,"tag":250,"props":6972,"children":6973},{"style":268},[6974],{"type":52,"value":836},{"type":46,"tag":250,"props":6976,"children":6977},{"style":262},[6978],{"type":52,"value":6979},"raw.facebook_ad_insights\n",{"type":46,"tag":250,"props":6981,"children":6982},{"class":252,"line":285},[6983,6987,6991],{"type":46,"tag":250,"props":6984,"children":6985},{"style":772},[6986],{"type":52,"value":4540},{"type":46,"tag":250,"props":6988,"children":6989},{"style":268},[6990],{"type":52,"value":836},{"type":46,"tag":250,"props":6992,"children":6993},{"style":262},[6994],{"type":52,"value":4549},{"type":46,"tag":250,"props":6996,"children":6997},{"class":252,"line":299},[6998,7002],{"type":46,"tag":250,"props":6999,"children":7000},{"style":772},[7001],{"type":52,"value":4557},{"type":46,"tag":250,"props":7003,"children":7004},{"style":268},[7005],{"type":52,"value":780},{"type":46,"tag":250,"props":7007,"children":7008},{"class":252,"line":807},[7009,7013,7017],{"type":46,"tag":250,"props":7010,"children":7011},{"style":772},[7012],{"type":52,"value":4569},{"type":46,"tag":250,"props":7014,"children":7015},{"style":268},[7016],{"type":52,"value":836},{"type":46,"tag":250,"props":7018,"children":7019},{"style":262},[7020],{"type":52,"value":6923},{"type":46,"tag":250,"props":7022,"children":7023},{"class":252,"line":820},[7024,7028,7032],{"type":46,"tag":250,"props":7025,"children":7026},{"style":772},[7027],{"type":52,"value":4586},{"type":46,"tag":250,"props":7029,"children":7030},{"style":268},[7031],{"type":52,"value":836},{"type":46,"tag":250,"props":7033,"children":7034},{"style":262},[7035],{"type":52,"value":7036},"insights\n",{"type":46,"tag":250,"props":7038,"children":7039},{"class":252,"line":844},[7040,7044,7048],{"type":46,"tag":250,"props":7041,"children":7042},{"style":772},[7043],{"type":52,"value":4620},{"type":46,"tag":250,"props":7045,"children":7046},{"style":268},[7047],{"type":52,"value":836},{"type":46,"tag":250,"props":7049,"children":7050},{"style":262},[7051],{"type":52,"value":4629},{"type":46,"tag":250,"props":7053,"children":7054},{"class":252,"line":862},[7055,7059,7063],{"type":46,"tag":250,"props":7056,"children":7057},{"style":772},[7058],{"type":52,"value":4637},{"type":46,"tag":250,"props":7060,"children":7061},{"style":268},[7062],{"type":52,"value":836},{"type":46,"tag":250,"props":7064,"children":7065},{"style":262},[7066],{"type":52,"value":7067},"date_start\n",{"type":46,"tag":250,"props":7069,"children":7070},{"class":252,"line":11},[7071,7075,7079],{"type":46,"tag":250,"props":7072,"children":7073},{"style":772},[7074],{"type":52,"value":4655},{"type":46,"tag":250,"props":7076,"children":7077},{"style":268},[7078],{"type":52,"value":836},{"type":46,"tag":250,"props":7080,"children":7081},{"style":262},[7082],{"type":52,"value":7083},"\"date_start,campaign_id\"\n",{"type":46,"tag":429,"props":7085,"children":7086},{"v-slot:google-ads":7},[7087,7092,7097,7104,7125,7129,7179,7186],{"type":46,"tag":4472,"props":7088,"children":7090},{"id":7089},"google-ads",[7091],{"type":52,"value":4129},{"type":46,"tag":55,"props":7093,"children":7094},{},[7095],{"type":52,"value":7096},"Google Ads covers your search and display ad spend and performance.",{"type":46,"tag":55,"props":7098,"children":7099},{},[7100],{"type":46,"tag":80,"props":7101,"children":7102},{},[7103],{"type":52,"value":6762},{"type":46,"tag":240,"props":7105,"children":7106},{"className":242,"code":477,"language":244,"meta":7,"style":7},[7107],{"type":46,"tag":99,"props":7108,"children":7109},{"__ignoreMap":7},[7110],{"type":46,"tag":250,"props":7111,"children":7112},{"class":252,"line":23},[7113,7117,7121],{"type":46,"tag":250,"props":7114,"children":7115},{"style":256},[7116],{"type":52,"value":305},{"type":46,"tag":250,"props":7118,"children":7119},{"style":262},[7120],{"type":52,"value":493},{"type":46,"tag":250,"props":7122,"children":7123},{"style":262},[7124],{"type":52,"value":498},{"type":46,"tag":55,"props":7126,"children":7127},{},[7128],{"type":52,"value":503},{"type":46,"tag":72,"props":7130,"children":7131},{},[7132,7146,7159,7169],{"type":46,"tag":76,"props":7133,"children":7134},{},[7135,7139,7140],{"type":46,"tag":80,"props":7136,"children":7137},{},[7138],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":7141,"children":7143},{"className":7142},[],[7144],{"type":52,"value":7145},"google_ads",{"type":46,"tag":76,"props":7147,"children":7148},{},[7149,7153,7154],{"type":46,"tag":80,"props":7150,"children":7151},{},[7152],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":7155,"children":7157},{"className":7156},[],[7158],{"type":52,"value":7145},{"type":46,"tag":76,"props":7160,"children":7161},{},[7162,7167],{"type":46,"tag":80,"props":7163,"children":7164},{},[7165],{"type":52,"value":7166},"Customer ID:",{"type":52,"value":7168}," your Google Ads customer ID",{"type":46,"tag":76,"props":7170,"children":7171},{},[7172,7177],{"type":46,"tag":80,"props":7173,"children":7174},{},[7175],{"type":52,"value":7176},"Credentials:",{"type":52,"value":7178}," path to your Google OAuth credentials JSON",{"type":46,"tag":55,"props":7180,"children":7181},{},[7182],{"type":46,"tag":80,"props":7183,"children":7184},{},[7185],{"type":52,"value":5278},{"type":46,"tag":423,"props":7187,"children":7189},{":variants":7188},"[{\"id\":\"gads-campaigns\",\"label\":\"Campaigns\"},{\"id\":\"gads-insights\",\"label\":\"Ad Insights\"}]",[7190,7288],{"type":46,"tag":429,"props":7191,"children":7192},{"v-slot:gads-campaigns":7},[7193],{"type":46,"tag":240,"props":7194,"children":7196},{"className":760,"code":7195,"language":762,"meta":7,"style":7},"name: raw.google_campaigns\ntype: ingestr\nparameters:\n  source_connection: google_ads\n  source_table: campaigns\n  incremental_strategy: replace\n",[7197],{"type":46,"tag":99,"props":7198,"children":7199},{"__ignoreMap":7},[7200,7216,7231,7242,7258,7273],{"type":46,"tag":250,"props":7201,"children":7202},{"class":252,"line":23},[7203,7207,7211],{"type":46,"tag":250,"props":7204,"children":7205},{"style":772},[7206],{"type":52,"value":831},{"type":46,"tag":250,"props":7208,"children":7209},{"style":268},[7210],{"type":52,"value":836},{"type":46,"tag":250,"props":7212,"children":7213},{"style":262},[7214],{"type":52,"value":7215},"raw.google_campaigns\n",{"type":46,"tag":250,"props":7217,"children":7218},{"class":252,"line":285},[7219,7223,7227],{"type":46,"tag":250,"props":7220,"children":7221},{"style":772},[7222],{"type":52,"value":4540},{"type":46,"tag":250,"props":7224,"children":7225},{"style":268},[7226],{"type":52,"value":836},{"type":46,"tag":250,"props":7228,"children":7229},{"style":262},[7230],{"type":52,"value":4549},{"type":46,"tag":250,"props":7232,"children":7233},{"class":252,"line":299},[7234,7238],{"type":46,"tag":250,"props":7235,"children":7236},{"style":772},[7237],{"type":52,"value":4557},{"type":46,"tag":250,"props":7239,"children":7240},{"style":268},[7241],{"type":52,"value":780},{"type":46,"tag":250,"props":7243,"children":7244},{"class":252,"line":807},[7245,7249,7253],{"type":46,"tag":250,"props":7246,"children":7247},{"style":772},[7248],{"type":52,"value":4569},{"type":46,"tag":250,"props":7250,"children":7251},{"style":268},[7252],{"type":52,"value":836},{"type":46,"tag":250,"props":7254,"children":7255},{"style":262},[7256],{"type":52,"value":7257},"google_ads\n",{"type":46,"tag":250,"props":7259,"children":7260},{"class":252,"line":820},[7261,7265,7269],{"type":46,"tag":250,"props":7262,"children":7263},{"style":772},[7264],{"type":52,"value":4586},{"type":46,"tag":250,"props":7266,"children":7267},{"style":268},[7268],{"type":52,"value":836},{"type":46,"tag":250,"props":7270,"children":7271},{"style":262},[7272],{"type":52,"value":6066},{"type":46,"tag":250,"props":7274,"children":7275},{"class":252,"line":844},[7276,7280,7284],{"type":46,"tag":250,"props":7277,"children":7278},{"style":772},[7279],{"type":52,"value":4620},{"type":46,"tag":250,"props":7281,"children":7282},{"style":268},[7283],{"type":52,"value":836},{"type":46,"tag":250,"props":7285,"children":7286},{"style":262},[7287],{"type":52,"value":5100},{"type":46,"tag":429,"props":7289,"children":7290},{"v-slot:gads-insights":7},[7291],{"type":46,"tag":240,"props":7292,"children":7294},{"className":760,"code":7293,"language":762,"meta":7,"style":7},"name: raw.google_ad_insights\ntype: ingestr\nparameters:\n  source_connection: google_ads\n  source_table: campaign_performance\n  incremental_strategy: merge\n  incremental_key: date\n  primary_key: \"date,campaign_id\"\n",[7295],{"type":46,"tag":99,"props":7296,"children":7297},{"__ignoreMap":7},[7298,7314,7329,7340,7355,7371,7386,7402],{"type":46,"tag":250,"props":7299,"children":7300},{"class":252,"line":23},[7301,7305,7309],{"type":46,"tag":250,"props":7302,"children":7303},{"style":772},[7304],{"type":52,"value":831},{"type":46,"tag":250,"props":7306,"children":7307},{"style":268},[7308],{"type":52,"value":836},{"type":46,"tag":250,"props":7310,"children":7311},{"style":262},[7312],{"type":52,"value":7313},"raw.google_ad_insights\n",{"type":46,"tag":250,"props":7315,"children":7316},{"class":252,"line":285},[7317,7321,7325],{"type":46,"tag":250,"props":7318,"children":7319},{"style":772},[7320],{"type":52,"value":4540},{"type":46,"tag":250,"props":7322,"children":7323},{"style":268},[7324],{"type":52,"value":836},{"type":46,"tag":250,"props":7326,"children":7327},{"style":262},[7328],{"type":52,"value":4549},{"type":46,"tag":250,"props":7330,"children":7331},{"class":252,"line":299},[7332,7336],{"type":46,"tag":250,"props":7333,"children":7334},{"style":772},[7335],{"type":52,"value":4557},{"type":46,"tag":250,"props":7337,"children":7338},{"style":268},[7339],{"type":52,"value":780},{"type":46,"tag":250,"props":7341,"children":7342},{"class":252,"line":807},[7343,7347,7351],{"type":46,"tag":250,"props":7344,"children":7345},{"style":772},[7346],{"type":52,"value":4569},{"type":46,"tag":250,"props":7348,"children":7349},{"style":268},[7350],{"type":52,"value":836},{"type":46,"tag":250,"props":7352,"children":7353},{"style":262},[7354],{"type":52,"value":7257},{"type":46,"tag":250,"props":7356,"children":7357},{"class":252,"line":820},[7358,7362,7366],{"type":46,"tag":250,"props":7359,"children":7360},{"style":772},[7361],{"type":52,"value":4586},{"type":46,"tag":250,"props":7363,"children":7364},{"style":268},[7365],{"type":52,"value":836},{"type":46,"tag":250,"props":7367,"children":7368},{"style":262},[7369],{"type":52,"value":7370},"campaign_performance\n",{"type":46,"tag":250,"props":7372,"children":7373},{"class":252,"line":844},[7374,7378,7382],{"type":46,"tag":250,"props":7375,"children":7376},{"style":772},[7377],{"type":52,"value":4620},{"type":46,"tag":250,"props":7379,"children":7380},{"style":268},[7381],{"type":52,"value":836},{"type":46,"tag":250,"props":7383,"children":7384},{"style":262},[7385],{"type":52,"value":4629},{"type":46,"tag":250,"props":7387,"children":7388},{"class":252,"line":862},[7389,7393,7397],{"type":46,"tag":250,"props":7390,"children":7391},{"style":772},[7392],{"type":52,"value":4637},{"type":46,"tag":250,"props":7394,"children":7395},{"style":268},[7396],{"type":52,"value":836},{"type":46,"tag":250,"props":7398,"children":7399},{"style":262},[7400],{"type":52,"value":7401},"date\n",{"type":46,"tag":250,"props":7403,"children":7404},{"class":252,"line":11},[7405,7409,7413],{"type":46,"tag":250,"props":7406,"children":7407},{"style":772},[7408],{"type":52,"value":4655},{"type":46,"tag":250,"props":7410,"children":7411},{"style":268},[7412],{"type":52,"value":836},{"type":46,"tag":250,"props":7414,"children":7415},{"style":262},[7416],{"type":52,"value":7417},"\"date,campaign_id\"\n",{"type":46,"tag":429,"props":7419,"children":7420},{"v-slot:tiktok-ads":7},[7421,7426,7431,7438,7459,7463,7512,7519],{"type":46,"tag":4472,"props":7422,"children":7424},{"id":7423},"tiktok-ads",[7425],{"type":52,"value":4130},{"type":46,"tag":55,"props":7427,"children":7428},{},[7429],{"type":52,"value":7430},"TikTok Ads covers your TikTok video ad spend and performance.",{"type":46,"tag":55,"props":7432,"children":7433},{},[7434],{"type":46,"tag":80,"props":7435,"children":7436},{},[7437],{"type":52,"value":6762},{"type":46,"tag":240,"props":7439,"children":7440},{"className":242,"code":477,"language":244,"meta":7,"style":7},[7441],{"type":46,"tag":99,"props":7442,"children":7443},{"__ignoreMap":7},[7444],{"type":46,"tag":250,"props":7445,"children":7446},{"class":252,"line":23},[7447,7451,7455],{"type":46,"tag":250,"props":7448,"children":7449},{"style":256},[7450],{"type":52,"value":305},{"type":46,"tag":250,"props":7452,"children":7453},{"style":262},[7454],{"type":52,"value":493},{"type":46,"tag":250,"props":7456,"children":7457},{"style":262},[7458],{"type":52,"value":498},{"type":46,"tag":55,"props":7460,"children":7461},{},[7462],{"type":52,"value":503},{"type":46,"tag":72,"props":7464,"children":7465},{},[7466,7480,7493,7502],{"type":46,"tag":76,"props":7467,"children":7468},{},[7469,7473,7474],{"type":46,"tag":80,"props":7470,"children":7471},{},[7472],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":7475,"children":7477},{"className":7476},[],[7478],{"type":52,"value":7479},"tiktok_ads",{"type":46,"tag":76,"props":7481,"children":7482},{},[7483,7487,7488],{"type":46,"tag":80,"props":7484,"children":7485},{},[7486],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":7489,"children":7491},{"className":7490},[],[7492],{"type":52,"value":7479},{"type":46,"tag":76,"props":7494,"children":7495},{},[7496,7500],{"type":46,"tag":80,"props":7497,"children":7498},{},[7499],{"type":52,"value":6825},{"type":52,"value":7501}," your TikTok Marketing API access token",{"type":46,"tag":76,"props":7503,"children":7504},{},[7505,7510],{"type":46,"tag":80,"props":7506,"children":7507},{},[7508],{"type":52,"value":7509},"Advertiser ID:",{"type":52,"value":7511}," your TikTok advertiser ID",{"type":46,"tag":55,"props":7513,"children":7514},{},[7515],{"type":46,"tag":80,"props":7516,"children":7517},{},[7518],{"type":52,"value":5278},{"type":46,"tag":423,"props":7520,"children":7522},{":variants":7521},"[{\"id\":\"tt-campaigns\",\"label\":\"Campaigns\"},{\"id\":\"tt-insights\",\"label\":\"Ad Insights\"}]",[7523,7621],{"type":46,"tag":429,"props":7524,"children":7525},{"v-slot:tt-campaigns":7},[7526],{"type":46,"tag":240,"props":7527,"children":7529},{"className":760,"code":7528,"language":762,"meta":7,"style":7},"name: raw.tiktok_campaigns\ntype: ingestr\nparameters:\n  source_connection: tiktok_ads\n  source_table: campaigns\n  incremental_strategy: replace\n",[7530],{"type":46,"tag":99,"props":7531,"children":7532},{"__ignoreMap":7},[7533,7549,7564,7575,7591,7606],{"type":46,"tag":250,"props":7534,"children":7535},{"class":252,"line":23},[7536,7540,7544],{"type":46,"tag":250,"props":7537,"children":7538},{"style":772},[7539],{"type":52,"value":831},{"type":46,"tag":250,"props":7541,"children":7542},{"style":268},[7543],{"type":52,"value":836},{"type":46,"tag":250,"props":7545,"children":7546},{"style":262},[7547],{"type":52,"value":7548},"raw.tiktok_campaigns\n",{"type":46,"tag":250,"props":7550,"children":7551},{"class":252,"line":285},[7552,7556,7560],{"type":46,"tag":250,"props":7553,"children":7554},{"style":772},[7555],{"type":52,"value":4540},{"type":46,"tag":250,"props":7557,"children":7558},{"style":268},[7559],{"type":52,"value":836},{"type":46,"tag":250,"props":7561,"children":7562},{"style":262},[7563],{"type":52,"value":4549},{"type":46,"tag":250,"props":7565,"children":7566},{"class":252,"line":299},[7567,7571],{"type":46,"tag":250,"props":7568,"children":7569},{"style":772},[7570],{"type":52,"value":4557},{"type":46,"tag":250,"props":7572,"children":7573},{"style":268},[7574],{"type":52,"value":780},{"type":46,"tag":250,"props":7576,"children":7577},{"class":252,"line":807},[7578,7582,7586],{"type":46,"tag":250,"props":7579,"children":7580},{"style":772},[7581],{"type":52,"value":4569},{"type":46,"tag":250,"props":7583,"children":7584},{"style":268},[7585],{"type":52,"value":836},{"type":46,"tag":250,"props":7587,"children":7588},{"style":262},[7589],{"type":52,"value":7590},"tiktok_ads\n",{"type":46,"tag":250,"props":7592,"children":7593},{"class":252,"line":820},[7594,7598,7602],{"type":46,"tag":250,"props":7595,"children":7596},{"style":772},[7597],{"type":52,"value":4586},{"type":46,"tag":250,"props":7599,"children":7600},{"style":268},[7601],{"type":52,"value":836},{"type":46,"tag":250,"props":7603,"children":7604},{"style":262},[7605],{"type":52,"value":6066},{"type":46,"tag":250,"props":7607,"children":7608},{"class":252,"line":844},[7609,7613,7617],{"type":46,"tag":250,"props":7610,"children":7611},{"style":772},[7612],{"type":52,"value":4620},{"type":46,"tag":250,"props":7614,"children":7615},{"style":268},[7616],{"type":52,"value":836},{"type":46,"tag":250,"props":7618,"children":7619},{"style":262},[7620],{"type":52,"value":5100},{"type":46,"tag":429,"props":7622,"children":7623},{"v-slot:tt-insights":7},[7624],{"type":46,"tag":240,"props":7625,"children":7627},{"className":760,"code":7626,"language":762,"meta":7,"style":7},"name: raw.tiktok_ad_insights\ntype: ingestr\nparameters:\n  source_connection: tiktok_ads\n  source_table: ads\n  incremental_strategy: merge\n  incremental_key: stat_datetime\n  primary_key: \"stat_datetime,campaign_id\"\n",[7628],{"type":46,"tag":99,"props":7629,"children":7630},{"__ignoreMap":7},[7631,7647,7662,7673,7688,7704,7719,7735],{"type":46,"tag":250,"props":7632,"children":7633},{"class":252,"line":23},[7634,7638,7642],{"type":46,"tag":250,"props":7635,"children":7636},{"style":772},[7637],{"type":52,"value":831},{"type":46,"tag":250,"props":7639,"children":7640},{"style":268},[7641],{"type":52,"value":836},{"type":46,"tag":250,"props":7643,"children":7644},{"style":262},[7645],{"type":52,"value":7646},"raw.tiktok_ad_insights\n",{"type":46,"tag":250,"props":7648,"children":7649},{"class":252,"line":285},[7650,7654,7658],{"type":46,"tag":250,"props":7651,"children":7652},{"style":772},[7653],{"type":52,"value":4540},{"type":46,"tag":250,"props":7655,"children":7656},{"style":268},[7657],{"type":52,"value":836},{"type":46,"tag":250,"props":7659,"children":7660},{"style":262},[7661],{"type":52,"value":4549},{"type":46,"tag":250,"props":7663,"children":7664},{"class":252,"line":299},[7665,7669],{"type":46,"tag":250,"props":7666,"children":7667},{"style":772},[7668],{"type":52,"value":4557},{"type":46,"tag":250,"props":7670,"children":7671},{"style":268},[7672],{"type":52,"value":780},{"type":46,"tag":250,"props":7674,"children":7675},{"class":252,"line":807},[7676,7680,7684],{"type":46,"tag":250,"props":7677,"children":7678},{"style":772},[7679],{"type":52,"value":4569},{"type":46,"tag":250,"props":7681,"children":7682},{"style":268},[7683],{"type":52,"value":836},{"type":46,"tag":250,"props":7685,"children":7686},{"style":262},[7687],{"type":52,"value":7590},{"type":46,"tag":250,"props":7689,"children":7690},{"class":252,"line":820},[7691,7695,7699],{"type":46,"tag":250,"props":7692,"children":7693},{"style":772},[7694],{"type":52,"value":4586},{"type":46,"tag":250,"props":7696,"children":7697},{"style":268},[7698],{"type":52,"value":836},{"type":46,"tag":250,"props":7700,"children":7701},{"style":262},[7702],{"type":52,"value":7703},"ads\n",{"type":46,"tag":250,"props":7705,"children":7706},{"class":252,"line":844},[7707,7711,7715],{"type":46,"tag":250,"props":7708,"children":7709},{"style":772},[7710],{"type":52,"value":4620},{"type":46,"tag":250,"props":7712,"children":7713},{"style":268},[7714],{"type":52,"value":836},{"type":46,"tag":250,"props":7716,"children":7717},{"style":262},[7718],{"type":52,"value":4629},{"type":46,"tag":250,"props":7720,"children":7721},{"class":252,"line":862},[7722,7726,7730],{"type":46,"tag":250,"props":7723,"children":7724},{"style":772},[7725],{"type":52,"value":4637},{"type":46,"tag":250,"props":7727,"children":7728},{"style":268},[7729],{"type":52,"value":836},{"type":46,"tag":250,"props":7731,"children":7732},{"style":262},[7733],{"type":52,"value":7734},"stat_datetime\n",{"type":46,"tag":250,"props":7736,"children":7737},{"class":252,"line":11},[7738,7742,7746],{"type":46,"tag":250,"props":7739,"children":7740},{"style":772},[7741],{"type":52,"value":4655},{"type":46,"tag":250,"props":7743,"children":7744},{"style":268},[7745],{"type":52,"value":836},{"type":46,"tag":250,"props":7747,"children":7748},{"style":262},[7749],{"type":52,"value":7750},"\"stat_datetime,campaign_id\"\n",{"type":46,"tag":4373,"props":7752,"children":7753},{},[],{"type":46,"tag":220,"props":7755,"children":7757},{"id":7756},"web-analytics",[7758],{"type":52,"value":7759},"Web Analytics",{"type":46,"tag":423,"props":7761,"children":7764},{":variants":7762,"group":7763},"[{\"id\":\"ga4\",\"label\":\"GA4\"},{\"id\":\"mixpanel\",\"label\":\"Mixpanel\"}]","analytics",[7765,8136],{"type":46,"tag":429,"props":7766,"children":7767},{"v-slot:ga4":7},[7768,7773,7778,7785,7806,7810,7867,7874],{"type":46,"tag":4472,"props":7769,"children":7771},{"id":7770},"ga4",[7772],{"type":52,"value":4134},{"type":46,"tag":55,"props":7774,"children":7775},{},[7776],{"type":52,"value":7777},"GA4 gives you the website funnel: who's visiting, where they come from, and what they do.",{"type":46,"tag":55,"props":7779,"children":7780},{},[7781],{"type":46,"tag":80,"props":7782,"children":7783},{},[7784],{"type":52,"value":6762},{"type":46,"tag":240,"props":7786,"children":7787},{"className":242,"code":477,"language":244,"meta":7,"style":7},[7788],{"type":46,"tag":99,"props":7789,"children":7790},{"__ignoreMap":7},[7791],{"type":46,"tag":250,"props":7792,"children":7793},{"class":252,"line":23},[7794,7798,7802],{"type":46,"tag":250,"props":7795,"children":7796},{"style":256},[7797],{"type":52,"value":305},{"type":46,"tag":250,"props":7799,"children":7800},{"style":262},[7801],{"type":52,"value":493},{"type":46,"tag":250,"props":7803,"children":7804},{"style":262},[7805],{"type":52,"value":498},{"type":46,"tag":55,"props":7807,"children":7808},{},[7809],{"type":52,"value":503},{"type":46,"tag":72,"props":7811,"children":7812},{},[7813,7827,7840,7857],{"type":46,"tag":76,"props":7814,"children":7815},{},[7816,7820,7821],{"type":46,"tag":80,"props":7817,"children":7818},{},[7819],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":7822,"children":7824},{"className":7823},[],[7825],{"type":52,"value":7826},"google_analytics",{"type":46,"tag":76,"props":7828,"children":7829},{},[7830,7834,7835],{"type":46,"tag":80,"props":7831,"children":7832},{},[7833],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":7836,"children":7838},{"className":7837},[],[7839],{"type":52,"value":7826},{"type":46,"tag":76,"props":7841,"children":7842},{},[7843,7848,7850],{"type":46,"tag":80,"props":7844,"children":7845},{},[7846],{"type":52,"value":7847},"Credentials path:",{"type":52,"value":7849}," path to your ",{"type":46,"tag":88,"props":7851,"children":7854},{"href":7852,"rel":7853},"https:\u002F\u002Fcloud.google.com\u002Fiam\u002Fdocs\u002Fkeys-create-delete",[92],[7855],{"type":52,"value":7856},"Google service account JSON",{"type":46,"tag":76,"props":7858,"children":7859},{},[7860,7865],{"type":46,"tag":80,"props":7861,"children":7862},{},[7863],{"type":52,"value":7864},"Property ID:",{"type":52,"value":7866}," your GA4 property ID (found in GA4 Admin > Property Settings)",{"type":46,"tag":55,"props":7868,"children":7869},{},[7870],{"type":46,"tag":80,"props":7871,"children":7872},{},[7873],{"type":52,"value":5278},{"type":46,"tag":423,"props":7875,"children":7877},{":variants":7876},"[{\"id\":\"ga4-events\",\"label\":\"Events\"},{\"id\":\"ga4-sessions\",\"label\":\"Sessions\"}]",[7878,8008],{"type":46,"tag":429,"props":7879,"children":7880},{"v-slot:ga4-events":7},[7881],{"type":46,"tag":240,"props":7882,"children":7884},{"className":760,"code":7883,"language":762,"meta":7,"style":7},"name: raw.ga4_events\ntype: ingestr\nparameters:\n  source_connection: google_analytics\n  source_table: events\n  incremental_strategy: merge\n  incremental_key: date\n  primary_key: \"date,event_name\"\n",[7885],{"type":46,"tag":99,"props":7886,"children":7887},{"__ignoreMap":7},[7888,7904,7919,7930,7946,7962,7977,7992],{"type":46,"tag":250,"props":7889,"children":7890},{"class":252,"line":23},[7891,7895,7899],{"type":46,"tag":250,"props":7892,"children":7893},{"style":772},[7894],{"type":52,"value":831},{"type":46,"tag":250,"props":7896,"children":7897},{"style":268},[7898],{"type":52,"value":836},{"type":46,"tag":250,"props":7900,"children":7901},{"style":262},[7902],{"type":52,"value":7903},"raw.ga4_events\n",{"type":46,"tag":250,"props":7905,"children":7906},{"class":252,"line":285},[7907,7911,7915],{"type":46,"tag":250,"props":7908,"children":7909},{"style":772},[7910],{"type":52,"value":4540},{"type":46,"tag":250,"props":7912,"children":7913},{"style":268},[7914],{"type":52,"value":836},{"type":46,"tag":250,"props":7916,"children":7917},{"style":262},[7918],{"type":52,"value":4549},{"type":46,"tag":250,"props":7920,"children":7921},{"class":252,"line":299},[7922,7926],{"type":46,"tag":250,"props":7923,"children":7924},{"style":772},[7925],{"type":52,"value":4557},{"type":46,"tag":250,"props":7927,"children":7928},{"style":268},[7929],{"type":52,"value":780},{"type":46,"tag":250,"props":7931,"children":7932},{"class":252,"line":807},[7933,7937,7941],{"type":46,"tag":250,"props":7934,"children":7935},{"style":772},[7936],{"type":52,"value":4569},{"type":46,"tag":250,"props":7938,"children":7939},{"style":268},[7940],{"type":52,"value":836},{"type":46,"tag":250,"props":7942,"children":7943},{"style":262},[7944],{"type":52,"value":7945},"google_analytics\n",{"type":46,"tag":250,"props":7947,"children":7948},{"class":252,"line":820},[7949,7953,7957],{"type":46,"tag":250,"props":7950,"children":7951},{"style":772},[7952],{"type":52,"value":4586},{"type":46,"tag":250,"props":7954,"children":7955},{"style":268},[7956],{"type":52,"value":836},{"type":46,"tag":250,"props":7958,"children":7959},{"style":262},[7960],{"type":52,"value":7961},"events\n",{"type":46,"tag":250,"props":7963,"children":7964},{"class":252,"line":844},[7965,7969,7973],{"type":46,"tag":250,"props":7966,"children":7967},{"style":772},[7968],{"type":52,"value":4620},{"type":46,"tag":250,"props":7970,"children":7971},{"style":268},[7972],{"type":52,"value":836},{"type":46,"tag":250,"props":7974,"children":7975},{"style":262},[7976],{"type":52,"value":4629},{"type":46,"tag":250,"props":7978,"children":7979},{"class":252,"line":862},[7980,7984,7988],{"type":46,"tag":250,"props":7981,"children":7982},{"style":772},[7983],{"type":52,"value":4637},{"type":46,"tag":250,"props":7985,"children":7986},{"style":268},[7987],{"type":52,"value":836},{"type":46,"tag":250,"props":7989,"children":7990},{"style":262},[7991],{"type":52,"value":7401},{"type":46,"tag":250,"props":7993,"children":7994},{"class":252,"line":11},[7995,7999,8003],{"type":46,"tag":250,"props":7996,"children":7997},{"style":772},[7998],{"type":52,"value":4655},{"type":46,"tag":250,"props":8000,"children":8001},{"style":268},[8002],{"type":52,"value":836},{"type":46,"tag":250,"props":8004,"children":8005},{"style":262},[8006],{"type":52,"value":8007},"\"date,event_name\"\n",{"type":46,"tag":429,"props":8009,"children":8010},{"v-slot:ga4-sessions":7},[8011],{"type":46,"tag":240,"props":8012,"children":8014},{"className":760,"code":8013,"language":762,"meta":7,"style":7},"name: raw.ga4_sessions\ntype: ingestr\nparameters:\n  source_connection: google_analytics\n  source_table: sessions\n  incremental_strategy: merge\n  incremental_key: date\n  primary_key: date\n",[8015],{"type":46,"tag":99,"props":8016,"children":8017},{"__ignoreMap":7},[8018,8034,8049,8060,8075,8091,8106,8121],{"type":46,"tag":250,"props":8019,"children":8020},{"class":252,"line":23},[8021,8025,8029],{"type":46,"tag":250,"props":8022,"children":8023},{"style":772},[8024],{"type":52,"value":831},{"type":46,"tag":250,"props":8026,"children":8027},{"style":268},[8028],{"type":52,"value":836},{"type":46,"tag":250,"props":8030,"children":8031},{"style":262},[8032],{"type":52,"value":8033},"raw.ga4_sessions\n",{"type":46,"tag":250,"props":8035,"children":8036},{"class":252,"line":285},[8037,8041,8045],{"type":46,"tag":250,"props":8038,"children":8039},{"style":772},[8040],{"type":52,"value":4540},{"type":46,"tag":250,"props":8042,"children":8043},{"style":268},[8044],{"type":52,"value":836},{"type":46,"tag":250,"props":8046,"children":8047},{"style":262},[8048],{"type":52,"value":4549},{"type":46,"tag":250,"props":8050,"children":8051},{"class":252,"line":299},[8052,8056],{"type":46,"tag":250,"props":8053,"children":8054},{"style":772},[8055],{"type":52,"value":4557},{"type":46,"tag":250,"props":8057,"children":8058},{"style":268},[8059],{"type":52,"value":780},{"type":46,"tag":250,"props":8061,"children":8062},{"class":252,"line":807},[8063,8067,8071],{"type":46,"tag":250,"props":8064,"children":8065},{"style":772},[8066],{"type":52,"value":4569},{"type":46,"tag":250,"props":8068,"children":8069},{"style":268},[8070],{"type":52,"value":836},{"type":46,"tag":250,"props":8072,"children":8073},{"style":262},[8074],{"type":52,"value":7945},{"type":46,"tag":250,"props":8076,"children":8077},{"class":252,"line":820},[8078,8082,8086],{"type":46,"tag":250,"props":8079,"children":8080},{"style":772},[8081],{"type":52,"value":4586},{"type":46,"tag":250,"props":8083,"children":8084},{"style":268},[8085],{"type":52,"value":836},{"type":46,"tag":250,"props":8087,"children":8088},{"style":262},[8089],{"type":52,"value":8090},"sessions\n",{"type":46,"tag":250,"props":8092,"children":8093},{"class":252,"line":844},[8094,8098,8102],{"type":46,"tag":250,"props":8095,"children":8096},{"style":772},[8097],{"type":52,"value":4620},{"type":46,"tag":250,"props":8099,"children":8100},{"style":268},[8101],{"type":52,"value":836},{"type":46,"tag":250,"props":8103,"children":8104},{"style":262},[8105],{"type":52,"value":4629},{"type":46,"tag":250,"props":8107,"children":8108},{"class":252,"line":862},[8109,8113,8117],{"type":46,"tag":250,"props":8110,"children":8111},{"style":772},[8112],{"type":52,"value":4637},{"type":46,"tag":250,"props":8114,"children":8115},{"style":268},[8116],{"type":52,"value":836},{"type":46,"tag":250,"props":8118,"children":8119},{"style":262},[8120],{"type":52,"value":7401},{"type":46,"tag":250,"props":8122,"children":8123},{"class":252,"line":11},[8124,8128,8132],{"type":46,"tag":250,"props":8125,"children":8126},{"style":772},[8127],{"type":52,"value":4655},{"type":46,"tag":250,"props":8129,"children":8130},{"style":268},[8131],{"type":52,"value":836},{"type":46,"tag":250,"props":8133,"children":8134},{"style":262},[8135],{"type":52,"value":7401},{"type":46,"tag":429,"props":8137,"children":8138},{"v-slot:mixpanel":7},[8139,8144,8149,8156,8177,8181,8220,8227],{"type":46,"tag":4472,"props":8140,"children":8142},{"id":8141},"mixpanel",[8143],{"type":52,"value":4132},{"type":46,"tag":55,"props":8145,"children":8146},{},[8147],{"type":52,"value":8148},"Mixpanel gives you product analytics: user events, funnels, and engagement data.",{"type":46,"tag":55,"props":8150,"children":8151},{},[8152],{"type":46,"tag":80,"props":8153,"children":8154},{},[8155],{"type":52,"value":6762},{"type":46,"tag":240,"props":8157,"children":8158},{"className":242,"code":477,"language":244,"meta":7,"style":7},[8159],{"type":46,"tag":99,"props":8160,"children":8161},{"__ignoreMap":7},[8162],{"type":46,"tag":250,"props":8163,"children":8164},{"class":252,"line":23},[8165,8169,8173],{"type":46,"tag":250,"props":8166,"children":8167},{"style":256},[8168],{"type":52,"value":305},{"type":46,"tag":250,"props":8170,"children":8171},{"style":262},[8172],{"type":52,"value":493},{"type":46,"tag":250,"props":8174,"children":8175},{"style":262},[8176],{"type":52,"value":498},{"type":46,"tag":55,"props":8178,"children":8179},{},[8180],{"type":52,"value":503},{"type":46,"tag":72,"props":8182,"children":8183},{},[8184,8197,8210],{"type":46,"tag":76,"props":8185,"children":8186},{},[8187,8191,8192],{"type":46,"tag":80,"props":8188,"children":8189},{},[8190],{"type":52,"value":514},{"type":52,"value":516},{"type":46,"tag":99,"props":8193,"children":8195},{"className":8194},[],[8196],{"type":52,"value":8141},{"type":46,"tag":76,"props":8198,"children":8199},{},[8200,8204,8205],{"type":46,"tag":80,"props":8201,"children":8202},{},[8203],{"type":52,"value":529},{"type":52,"value":516},{"type":46,"tag":99,"props":8206,"children":8208},{"className":8207},[],[8209],{"type":52,"value":8141},{"type":46,"tag":76,"props":8211,"children":8212},{},[8213,8218],{"type":46,"tag":80,"props":8214,"children":8215},{},[8216],{"type":52,"value":8217},"API secret:",{"type":52,"value":8219}," your Mixpanel API secret (found in Project Settings)",{"type":46,"tag":55,"props":8221,"children":8222},{},[8223],{"type":46,"tag":80,"props":8224,"children":8225},{},[8226],{"type":52,"value":5278},{"type":46,"tag":423,"props":8228,"children":8230},{":variants":8229},"[{\"id\":\"mp-events\",\"label\":\"Events\"},{\"id\":\"mp-funnels\",\"label\":\"Funnels\"}]",[8231,8361],{"type":46,"tag":429,"props":8232,"children":8233},{"v-slot:mp-events":7},[8234],{"type":46,"tag":240,"props":8235,"children":8237},{"className":760,"code":8236,"language":762,"meta":7,"style":7},"name: raw.mixpanel_events\ntype: ingestr\nparameters:\n  source_connection: mixpanel\n  source_table: events\n  incremental_strategy: merge\n  incremental_key: time\n  primary_key: \"distinct_id,time\"\n",[8238],{"type":46,"tag":99,"props":8239,"children":8240},{"__ignoreMap":7},[8241,8257,8272,8283,8299,8314,8329,8345],{"type":46,"tag":250,"props":8242,"children":8243},{"class":252,"line":23},[8244,8248,8252],{"type":46,"tag":250,"props":8245,"children":8246},{"style":772},[8247],{"type":52,"value":831},{"type":46,"tag":250,"props":8249,"children":8250},{"style":268},[8251],{"type":52,"value":836},{"type":46,"tag":250,"props":8253,"children":8254},{"style":262},[8255],{"type":52,"value":8256},"raw.mixpanel_events\n",{"type":46,"tag":250,"props":8258,"children":8259},{"class":252,"line":285},[8260,8264,8268],{"type":46,"tag":250,"props":8261,"children":8262},{"style":772},[8263],{"type":52,"value":4540},{"type":46,"tag":250,"props":8265,"children":8266},{"style":268},[8267],{"type":52,"value":836},{"type":46,"tag":250,"props":8269,"children":8270},{"style":262},[8271],{"type":52,"value":4549},{"type":46,"tag":250,"props":8273,"children":8274},{"class":252,"line":299},[8275,8279],{"type":46,"tag":250,"props":8276,"children":8277},{"style":772},[8278],{"type":52,"value":4557},{"type":46,"tag":250,"props":8280,"children":8281},{"style":268},[8282],{"type":52,"value":780},{"type":46,"tag":250,"props":8284,"children":8285},{"class":252,"line":807},[8286,8290,8294],{"type":46,"tag":250,"props":8287,"children":8288},{"style":772},[8289],{"type":52,"value":4569},{"type":46,"tag":250,"props":8291,"children":8292},{"style":268},[8293],{"type":52,"value":836},{"type":46,"tag":250,"props":8295,"children":8296},{"style":262},[8297],{"type":52,"value":8298},"mixpanel\n",{"type":46,"tag":250,"props":8300,"children":8301},{"class":252,"line":820},[8302,8306,8310],{"type":46,"tag":250,"props":8303,"children":8304},{"style":772},[8305],{"type":52,"value":4586},{"type":46,"tag":250,"props":8307,"children":8308},{"style":268},[8309],{"type":52,"value":836},{"type":46,"tag":250,"props":8311,"children":8312},{"style":262},[8313],{"type":52,"value":7961},{"type":46,"tag":250,"props":8315,"children":8316},{"class":252,"line":844},[8317,8321,8325],{"type":46,"tag":250,"props":8318,"children":8319},{"style":772},[8320],{"type":52,"value":4620},{"type":46,"tag":250,"props":8322,"children":8323},{"style":268},[8324],{"type":52,"value":836},{"type":46,"tag":250,"props":8326,"children":8327},{"style":262},[8328],{"type":52,"value":4629},{"type":46,"tag":250,"props":8330,"children":8331},{"class":252,"line":862},[8332,8336,8340],{"type":46,"tag":250,"props":8333,"children":8334},{"style":772},[8335],{"type":52,"value":4637},{"type":46,"tag":250,"props":8337,"children":8338},{"style":268},[8339],{"type":52,"value":836},{"type":46,"tag":250,"props":8341,"children":8342},{"style":262},[8343],{"type":52,"value":8344},"time\n",{"type":46,"tag":250,"props":8346,"children":8347},{"class":252,"line":11},[8348,8352,8356],{"type":46,"tag":250,"props":8349,"children":8350},{"style":772},[8351],{"type":52,"value":4655},{"type":46,"tag":250,"props":8353,"children":8354},{"style":268},[8355],{"type":52,"value":836},{"type":46,"tag":250,"props":8357,"children":8358},{"style":262},[8359],{"type":52,"value":8360},"\"distinct_id,time\"\n",{"type":46,"tag":429,"props":8362,"children":8363},{"v-slot:mp-funnels":7},[8364],{"type":46,"tag":240,"props":8365,"children":8367},{"className":760,"code":8366,"language":762,"meta":7,"style":7},"name: raw.mixpanel_funnels\ntype: ingestr\nparameters:\n  source_connection: mixpanel\n  source_table: funnels\n  incremental_strategy: replace\n",[8368],{"type":46,"tag":99,"props":8369,"children":8370},{"__ignoreMap":7},[8371,8387,8402,8413,8428,8444],{"type":46,"tag":250,"props":8372,"children":8373},{"class":252,"line":23},[8374,8378,8382],{"type":46,"tag":250,"props":8375,"children":8376},{"style":772},[8377],{"type":52,"value":831},{"type":46,"tag":250,"props":8379,"children":8380},{"style":268},[8381],{"type":52,"value":836},{"type":46,"tag":250,"props":8383,"children":8384},{"style":262},[8385],{"type":52,"value":8386},"raw.mixpanel_funnels\n",{"type":46,"tag":250,"props":8388,"children":8389},{"class":252,"line":285},[8390,8394,8398],{"type":46,"tag":250,"props":8391,"children":8392},{"style":772},[8393],{"type":52,"value":4540},{"type":46,"tag":250,"props":8395,"children":8396},{"style":268},[8397],{"type":52,"value":836},{"type":46,"tag":250,"props":8399,"children":8400},{"style":262},[8401],{"type":52,"value":4549},{"type":46,"tag":250,"props":8403,"children":8404},{"class":252,"line":299},[8405,8409],{"type":46,"tag":250,"props":8406,"children":8407},{"style":772},[8408],{"type":52,"value":4557},{"type":46,"tag":250,"props":8410,"children":8411},{"style":268},[8412],{"type":52,"value":780},{"type":46,"tag":250,"props":8414,"children":8415},{"class":252,"line":807},[8416,8420,8424],{"type":46,"tag":250,"props":8417,"children":8418},{"style":772},[8419],{"type":52,"value":4569},{"type":46,"tag":250,"props":8421,"children":8422},{"style":268},[8423],{"type":52,"value":836},{"type":46,"tag":250,"props":8425,"children":8426},{"style":262},[8427],{"type":52,"value":8298},{"type":46,"tag":250,"props":8429,"children":8430},{"class":252,"line":820},[8431,8435,8439],{"type":46,"tag":250,"props":8432,"children":8433},{"style":772},[8434],{"type":52,"value":4586},{"type":46,"tag":250,"props":8436,"children":8437},{"style":268},[8438],{"type":52,"value":836},{"type":46,"tag":250,"props":8440,"children":8441},{"style":262},[8442],{"type":52,"value":8443},"funnels\n",{"type":46,"tag":250,"props":8445,"children":8446},{"class":252,"line":844},[8447,8451,8455],{"type":46,"tag":250,"props":8448,"children":8449},{"style":772},[8450],{"type":52,"value":4620},{"type":46,"tag":250,"props":8452,"children":8453},{"style":268},[8454],{"type":52,"value":836},{"type":46,"tag":250,"props":8456,"children":8457},{"style":262},[8458],{"type":52,"value":5100},{"type":46,"tag":4373,"props":8460,"children":8461},{},[],{"type":46,"tag":220,"props":8463,"children":8465},{"id":8464},"validate-and-run",[8466],{"type":52,"value":8467},"Validate and run",{"type":46,"tag":55,"props":8469,"children":8470},{},[8471],{"type":52,"value":8472},"Validate that all your asset definitions are correct:",{"type":46,"tag":240,"props":8474,"children":8475},{"className":242,"code":1489,"language":244,"meta":7,"style":7},[8476],{"type":46,"tag":99,"props":8477,"children":8478},{"__ignoreMap":7},[8479],{"type":46,"tag":250,"props":8480,"children":8481},{"class":252,"line":23},[8482,8486,8490],{"type":46,"tag":250,"props":8483,"children":8484},{"style":256},[8485],{"type":52,"value":305},{"type":46,"tag":250,"props":8487,"children":8488},{"style":262},[8489],{"type":52,"value":1505},{"type":46,"tag":250,"props":8491,"children":8492},{"style":262},[8493],{"type":52,"value":1510},{"type":46,"tag":55,"props":8495,"children":8496},{},[8497],{"type":52,"value":8498},"Or ask Claude Code:",{"type":46,"tag":1434,"props":8500,"children":8501},{},[8502],{"type":46,"tag":55,"props":8503,"children":8504},{},[8505],{"type":52,"value":8506},"Run bruin validate and fix any issues you find in the asset files.",{"type":46,"tag":55,"props":8508,"children":8509},{},[8510],{"type":52,"value":8511},"Fix any errors - the most common issue is a typo in a connection name or a missing required field.",{"type":46,"tag":55,"props":8513,"children":8514},{},[8515],{"type":52,"value":8516},"Then run the pipeline. For your first run, start with a small date range (about a month) to verify everything works before doing a full backfill:",{"type":46,"tag":240,"props":8518,"children":8520},{"className":242,"code":8519,"language":244,"meta":7,"style":7},"bruin run --start-date 2025-01-01 --end-date 2025-02-01 .\n",[8521],{"type":46,"tag":99,"props":8522,"children":8523},{"__ignoreMap":7},[8524],{"type":46,"tag":250,"props":8525,"children":8526},{"class":252,"line":23},[8527,8531,8536,8541,8546,8551,8556],{"type":46,"tag":250,"props":8528,"children":8529},{"style":256},[8530],{"type":52,"value":305},{"type":46,"tag":250,"props":8532,"children":8533},{"style":262},[8534],{"type":52,"value":8535}," run",{"type":46,"tag":250,"props":8537,"children":8538},{"style":274},[8539],{"type":52,"value":8540}," --start-date",{"type":46,"tag":250,"props":8542,"children":8543},{"style":262},[8544],{"type":52,"value":8545}," 2025-01-01",{"type":46,"tag":250,"props":8547,"children":8548},{"style":274},[8549],{"type":52,"value":8550}," --end-date",{"type":46,"tag":250,"props":8552,"children":8553},{"style":262},[8554],{"type":52,"value":8555}," 2025-02-01",{"type":46,"tag":250,"props":8557,"children":8558},{"style":262},[8559],{"type":52,"value":1510},{"type":46,"tag":55,"props":8561,"children":8562},{},[8563,8565,8571,8573,8579,8581,8586,8587,8591],{"type":52,"value":8564},"This tells Bruin to only pull data within that interval. The ",{"type":46,"tag":99,"props":8566,"children":8568},{"className":8567},[],[8569],{"type":52,"value":8570},"--start-date",{"type":52,"value":8572}," and ",{"type":46,"tag":99,"props":8574,"children":8576},{"className":8575},[],[8577],{"type":52,"value":8578},"--end-date",{"type":52,"value":8580}," flags control the date range passed to each ",{"type":46,"tag":88,"props":8582,"children":8583},{"href":161},[8584],{"type":52,"value":8585},"ingestor asset",{"type":52,"value":4311},{"type":46,"tag":88,"props":8588,"children":8589},{"href":176},[8590],{"type":52,"value":179},{"type":52,"value":8592}," for all available flags.",{"type":46,"tag":55,"props":8594,"children":8595},{},[8596,8598,8604,8605,8611],{"type":52,"value":8597},"If you have multiple environments (e.g. ",{"type":46,"tag":99,"props":8599,"children":8601},{"className":8600},[],[8602],{"type":52,"value":8603},"dev",{"type":52,"value":8572},{"type":46,"tag":99,"props":8606,"children":8608},{"className":8607},[],[8609],{"type":52,"value":8610},"prod",{"type":52,"value":8612},"), you can specify which one to use:",{"type":46,"tag":240,"props":8614,"children":8616},{"className":242,"code":8615,"language":244,"meta":7,"style":7},"bruin run --start-date 2025-01-01 --end-date 2025-02-01 -e default .\n",[8617],{"type":46,"tag":99,"props":8618,"children":8619},{"__ignoreMap":7},[8620],{"type":46,"tag":250,"props":8621,"children":8622},{"class":252,"line":23},[8623,8627,8631,8635,8639,8643,8647,8652,8657],{"type":46,"tag":250,"props":8624,"children":8625},{"style":256},[8626],{"type":52,"value":305},{"type":46,"tag":250,"props":8628,"children":8629},{"style":262},[8630],{"type":52,"value":8535},{"type":46,"tag":250,"props":8632,"children":8633},{"style":274},[8634],{"type":52,"value":8540},{"type":46,"tag":250,"props":8636,"children":8637},{"style":262},[8638],{"type":52,"value":8545},{"type":46,"tag":250,"props":8640,"children":8641},{"style":274},[8642],{"type":52,"value":8550},{"type":46,"tag":250,"props":8644,"children":8645},{"style":262},[8646],{"type":52,"value":8555},{"type":46,"tag":250,"props":8648,"children":8649},{"style":274},[8650],{"type":52,"value":8651}," -e",{"type":46,"tag":250,"props":8653,"children":8654},{"style":262},[8655],{"type":52,"value":8656}," default",{"type":46,"tag":250,"props":8658,"children":8659},{"style":262},[8660],{"type":52,"value":1510},{"type":46,"tag":55,"props":8662,"children":8663},{},[8664],{"type":52,"value":8665},"Once you've confirmed the data looks right, do a full backfill with a wider range:",{"type":46,"tag":240,"props":8667,"children":8669},{"className":242,"code":8668,"language":244,"meta":7,"style":7},"bruin run --start-date 2024-01-01 --end-date 2026-04-01 .\n",[8670],{"type":46,"tag":99,"props":8671,"children":8672},{"__ignoreMap":7},[8673],{"type":46,"tag":250,"props":8674,"children":8675},{"class":252,"line":23},[8676,8680,8684,8688,8693,8697,8702],{"type":46,"tag":250,"props":8677,"children":8678},{"style":256},[8679],{"type":52,"value":305},{"type":46,"tag":250,"props":8681,"children":8682},{"style":262},[8683],{"type":52,"value":8535},{"type":46,"tag":250,"props":8685,"children":8686},{"style":274},[8687],{"type":52,"value":8540},{"type":46,"tag":250,"props":8689,"children":8690},{"style":262},[8691],{"type":52,"value":8692}," 2024-01-01",{"type":46,"tag":250,"props":8694,"children":8695},{"style":274},[8696],{"type":52,"value":8550},{"type":46,"tag":250,"props":8698,"children":8699},{"style":262},[8700],{"type":52,"value":8701}," 2026-04-01",{"type":46,"tag":250,"props":8703,"children":8704},{"style":262},[8705],{"type":52,"value":1510},{"type":46,"tag":220,"props":8707,"children":8709},{"id":8708},"verify-data-landed",[8710],{"type":52,"value":8711},"Verify data landed",{"type":46,"tag":55,"props":8713,"children":8714},{},[8715],{"type":52,"value":8716},"Ask Claude Code to check all your tables at once:",{"type":46,"tag":1434,"props":8718,"children":8719},{},[8720],{"type":46,"tag":55,"props":8721,"children":8722},{},[8723],{"type":52,"value":8724},"Query each raw table in the warehouse and give me the row count for every source we ingested.",{"type":46,"tag":55,"props":8726,"children":8727},{},[8728],{"type":52,"value":8729},"If you see row counts greater than zero, your ingestion is working. If a table is empty, ask Claude Code to troubleshoot:",{"type":46,"tag":1434,"props":8731,"children":8732},{},[8733],{"type":46,"tag":55,"props":8734,"children":8735},{},[8736],{"type":52,"value":8737},"The raw.shopify_orders table is empty after running the pipeline. Check the asset definition and connection, and tell me what might be wrong.",{"type":46,"tag":47,"props":8739,"children":8740},{"id":1531},[8741],{"type":52,"value":1534},{"type":46,"tag":55,"props":8743,"children":8744},{},[8745,8747,8751],{"type":52,"value":8746},"You now have raw ecommerce data flowing from your SaaS sources into your warehouse. Each ",{"type":46,"tag":88,"props":8748,"children":8749},{"href":161},[8750],{"type":52,"value":8585},{"type":52,"value":8752}," uses incremental loading - on subsequent runs, it only pulls new and updated records instead of re-fetching everything.",{"type":46,"tag":55,"props":8754,"children":8755},{},[8756],{"type":52,"value":8757},"Next, you'll build a staging layer on top of this raw data to clean, join, and deduplicate across sources.",{"type":46,"tag":1541,"props":8759,"children":8760},{},[8761],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":8763},[8764,8765,8768,8778],{"id":49,"depth":285,"text":53},{"id":183,"depth":285,"text":186,"children":8766},[8767],{"id":4182,"depth":299,"text":4185},{"id":215,"depth":285,"text":218,"children":8769},[8770,8771,8772,8773,8774,8775,8776,8777],{"id":4210,"depth":299,"text":4213},{"id":4378,"depth":299,"text":4381},{"id":5130,"depth":299,"text":5133},{"id":5879,"depth":299,"text":5882},{"id":6733,"depth":299,"text":6736},{"id":7756,"depth":299,"text":7759},{"id":8464,"depth":299,"text":8467},{"id":8708,"depth":299,"text":8711},{"id":1531,"depth":285,"text":1534},"content:tutorials:ecommerce-pipeline:ingest-data.md","tutorials\u002Fecommerce-pipeline\u002Fingest-data.md","tutorials\u002Fecommerce-pipeline\u002Fingest-data",{"_path":8783,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8784,"description":8785,"date":10,"readingTime":4121,"category":12,"tags":8786,"difficulty":8788,"module":5,"subSteps":22,"step":299,"variants":8789,"journeys":8790,"learnMore":8791,"author":8801,"body":8802,"_type":1560,"_id":16775,"_source":1562,"_file":16776,"_stem":16777,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fdata-preparation","Clean & Join Your Data","Build a staging layer that cleans, deduplicates, and joins data across Shopify, Stripe, and your marketing, ads, and analytics sources into consistent, analysis-ready tables.",[14,15,8787,17,18,19,20],"SQL","Intermediate",[17,18,19],[26,27],[8792,8795,8798],{"label":8793,"url":8794},"Materialization strategies","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fassets\u002Fmaterialization.html",{"label":8796,"url":8797},"Quality checks","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fquality\u002Foverview.html",{"label":8799,"url":8800},"Asset dependencies","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fassets\u002Fdefinition-schema.html",{"name":39,"role":40,"image":41},{"type":43,"children":8803,"toc":16755},[8804,8808,8813,8817,8822,8827,8831,8844,8868,8874,8879,8887,8892,8897,9046,9058,9063,9151,9167,11908,11928,11940,11974,12044,12058,12727,12745,12757,12776,12806,12820,13137,13149,13154,13168,13196,13202,14223,14229,14242,14849,14879,14891,14896,14910,14916,14944,15976,15982,16015,16499,16507,16513,16534,16539,16576,16587,16626,16632,16637,16645,16650,16658,16662,16739,16751],{"type":46,"tag":47,"props":8805,"children":8806},{"id":49},[8807],{"type":52,"value":53},{"type":46,"tag":55,"props":8809,"children":8810},{},[8811],{"type":52,"value":8812},"Write SQL assets that clean and join the raw data from Step 2 into a staging layer - five consistent tables that the report layer builds on.",{"type":46,"tag":47,"props":8814,"children":8815},{"id":183},[8816],{"type":52,"value":186},{"type":46,"tag":55,"props":8818,"children":8819},{},[8820],{"type":52,"value":8821},"Raw data from five different SaaS tools has different formats, timestamps, IDs, and conventions. Shopify stores amounts in dollars, Stripe stores them in cents. Your email platform tracks opens, your ads platform tracks impressions - both are \"engagement\" but they look nothing alike.",{"type":46,"tag":55,"props":8823,"children":8824},{},[8825],{"type":52,"value":8826},"The staging layer normalizes everything into a consistent format so that reports are accurate and trustworthy.",{"type":46,"tag":47,"props":8828,"children":8829},{"id":215},[8830],{"type":52,"value":218},{"type":46,"tag":55,"props":8832,"children":8833},{},[8834,8836,8842],{"type":52,"value":8835},"Create a ",{"type":46,"tag":99,"props":8837,"children":8839},{"className":8838},[],[8840],{"type":52,"value":8841},"staging\u002F",{"type":52,"value":8843}," subfolder to keep your staging assets organized:",{"type":46,"tag":240,"props":8845,"children":8847},{"className":242,"code":8846,"language":244,"meta":7,"style":7},"mkdir -p ecommerce\u002Fassets\u002Fstaging\n",[8848],{"type":46,"tag":99,"props":8849,"children":8850},{"__ignoreMap":7},[8851],{"type":46,"tag":250,"props":8852,"children":8853},{"class":252,"line":23},[8854,8858,8863],{"type":46,"tag":250,"props":8855,"children":8856},{"style":256},[8857],{"type":52,"value":259},{"type":46,"tag":250,"props":8859,"children":8860},{"style":274},[8861],{"type":52,"value":8862}," -p",{"type":46,"tag":250,"props":8864,"children":8865},{"style":262},[8866],{"type":52,"value":8867}," ecommerce\u002Fassets\u002Fstaging\n",{"type":46,"tag":220,"props":8869,"children":8871},{"id":8870},"using-claude-code-to-write-staging-sql",[8872],{"type":52,"value":8873},"Using Claude Code to write staging SQL",{"type":46,"tag":55,"props":8875,"children":8876},{},[8877],{"type":52,"value":8878},"This is where Claude Code really helps. Instead of writing every SQL file from scratch, you can ask Claude Code to look at your raw tables and generate the staging queries for you:",{"type":46,"tag":1434,"props":8880,"children":8881},{},[8882],{"type":46,"tag":55,"props":8883,"children":8884},{},[8885],{"type":52,"value":8886},"Look at the schemas for raw.shopify_orders and raw.stripe_charges in my warehouse. Write a Bruin SQL asset that joins them into a staging.stg_orders table - deduplicate, convert Stripe cents to dollars, and add not_null and unique checks on order_id. Put it in ecommerce\u002Fassets\u002Fstaging\u002Fstg_orders.sql.",{"type":46,"tag":55,"props":8888,"children":8889},{},[8890],{"type":52,"value":8891},"Claude Code will use the Bruin MCP to inspect the actual column names and types in your warehouse, then write SQL that matches your real data. You can do this for each staging table below.",{"type":46,"tag":55,"props":8893,"children":8894},{},[8895],{"type":52,"value":8896},"The SQL examples below are what the files should look like. You can create them manually, or have Claude Code generate them and just review the output.",{"type":46,"tag":198,"props":8898,"children":8899},{"type":5103},[8900,8910],{"type":46,"tag":55,"props":8901,"children":8902},{},[8903,8908],{"type":46,"tag":80,"props":8904,"children":8905},{},[8906],{"type":52,"value":8907},"Production tips from a real Shopify pipeline:",{"type":52,"value":8909}," Shopify's raw data has some quirks to handle in staging:",{"type":46,"tag":72,"props":8911,"children":8912},{},[8913,8931,8949,8989,9015],{"type":46,"tag":76,"props":8914,"children":8915},{},[8916,8921,8923,8929],{"type":46,"tag":80,"props":8917,"children":8918},{},[8919],{"type":52,"value":8920},"Test orders:",{"type":52,"value":8922}," Filter with ",{"type":46,"tag":99,"props":8924,"children":8926},{"className":8925},[],[8927],{"type":52,"value":8928},"WHERE test IS NOT TRUE",{"type":52,"value":8930}," to exclude test transactions",{"type":46,"tag":76,"props":8932,"children":8933},{},[8934,8939,8941,8947],{"type":46,"tag":80,"props":8935,"children":8936},{},[8937],{"type":52,"value":8938},"Deduplication:",{"type":52,"value":8940}," Shopify can send the same order multiple times. Add ",{"type":46,"tag":99,"props":8942,"children":8944},{"className":8943},[],[8945],{"type":52,"value":8946},"QUALIFY ROW_NUMBER() OVER (PARTITION BY id ORDER BY updated_at DESC) = 1",{"type":52,"value":8948}," to keep only the latest version",{"type":46,"tag":76,"props":8950,"children":8951},{},[8952,8957,8959,8965,8966,8972,8973,8979,8981,8987],{"type":46,"tag":80,"props":8953,"children":8954},{},[8955],{"type":52,"value":8956},"JSON fields:",{"type":52,"value":8958}," Fields like ",{"type":46,"tag":99,"props":8960,"children":8962},{"className":8961},[],[8963],{"type":52,"value":8964},"customer",{"type":52,"value":151},{"type":46,"tag":99,"props":8967,"children":8969},{"className":8968},[],[8970],{"type":52,"value":8971},"shipping_address",{"type":52,"value":173},{"type":46,"tag":99,"props":8974,"children":8976},{"className":8975},[],[8977],{"type":52,"value":8978},"line_items",{"type":52,"value":8980}," are nested JSON. Extract them with ",{"type":46,"tag":99,"props":8982,"children":8984},{"className":8983},[],[8985],{"type":52,"value":8986},"JSON_EXTRACT_SCALAR(customer, '$.id')",{"type":52,"value":8988}," (BigQuery) or equivalent",{"type":46,"tag":76,"props":8990,"children":8991},{},[8992,8997,8999,9005,9007,9013],{"type":46,"tag":80,"props":8993,"children":8994},{},[8995],{"type":52,"value":8996},"Product IDs:",{"type":52,"value":8998}," Shopify product IDs come in GID format (",{"type":46,"tag":99,"props":9000,"children":9002},{"className":9001},[],[9003],{"type":52,"value":9004},"gid:\u002F\u002Fshopify\u002FProduct\u002F123456789",{"type":52,"value":9006},"). Parse with ",{"type":46,"tag":99,"props":9008,"children":9010},{"className":9009},[],[9011],{"type":52,"value":9012},"REPLACE(id, 'gid:\u002F\u002Fshopify\u002FProduct\u002F', '')",{"type":52,"value":9014}," in your products staging table",{"type":46,"tag":76,"props":9016,"children":9017},{},[9018,9023,9025,9031,9033,9038,9040],{"type":46,"tag":80,"props":9019,"children":9020},{},[9021],{"type":52,"value":9022},"Line items:",{"type":52,"value":9024}," For product-level analytics, create a ",{"type":46,"tag":99,"props":9026,"children":9028},{"className":9027},[],[9029],{"type":52,"value":9030},"staging.stg_order_line_items",{"type":52,"value":9032}," table that flattens the ",{"type":46,"tag":99,"props":9034,"children":9036},{"className":9035},[],[9037],{"type":52,"value":8978},{"type":52,"value":9039}," JSON array using ",{"type":46,"tag":99,"props":9041,"children":9043},{"className":9042},[],[9044],{"type":52,"value":9045},"UNNEST(JSON_EXTRACT_ARRAY(line_items))",{"type":46,"tag":220,"props":9047,"children":9049},{"id":9048},"_1-staged-orders-stg_orderssql",[9050,9052],{"type":52,"value":9051},"1) Staged orders - ",{"type":46,"tag":99,"props":9053,"children":9055},{"className":9054},[],[9056],{"type":52,"value":9057},"stg_orders.sql",{"type":46,"tag":55,"props":9059,"children":9060},{},[9061],{"type":52,"value":9062},"This is the core table: every order, enriched with Stripe payment data.",{"type":46,"tag":198,"props":9064,"children":9066},{"type":9065},"warning",[9067],{"type":46,"tag":55,"props":9068,"children":9069},{},[9070,9072,9078,9080,9086,9088,9094,9096,9100,9102,9107,9109,9114,9116,9121,9123,9129,9131,9136,9138,9143,9144,9149],{"type":52,"value":9071},"The SQL below includes a ",{"type":46,"tag":99,"props":9073,"children":9075},{"className":9074},[],[9076],{"type":52,"value":9077},"LEFT JOIN",{"type":52,"value":9079}," to ",{"type":46,"tag":99,"props":9081,"children":9083},{"className":9082},[],[9084],{"type":52,"value":9085},"raw.stripe_charges",{"type":52,"value":9087}," and lists it in ",{"type":46,"tag":99,"props":9089,"children":9091},{"className":9090},[],[9092],{"type":52,"value":9093},"depends",{"type":52,"value":9095},". This only applies if you set up Stripe in Step 2. If you're using ",{"type":46,"tag":80,"props":9097,"children":9098},{},[9099],{"type":52,"value":5146},{"type":52,"value":9101},", remove ",{"type":46,"tag":99,"props":9103,"children":9105},{"className":9104},[],[9106],{"type":52,"value":9085},{"type":52,"value":9108}," from the ",{"type":46,"tag":99,"props":9110,"children":9112},{"className":9111},[],[9113],{"type":52,"value":9093},{"type":52,"value":9115}," list and remove the ",{"type":46,"tag":99,"props":9117,"children":9119},{"className":9118},[],[9120],{"type":52,"value":9077},{"type":52,"value":9122}," and the three ",{"type":46,"tag":99,"props":9124,"children":9126},{"className":9125},[],[9127],{"type":52,"value":9128},"stripe_*",{"type":52,"value":9130}," columns from the SELECT. The payment data is already in ",{"type":46,"tag":99,"props":9132,"children":9134},{"className":9133},[],[9135],{"type":52,"value":5177},{"type":52,"value":9137}," (the ",{"type":46,"tag":99,"props":9139,"children":9141},{"className":9140},[],[9142],{"type":52,"value":5157},{"type":52,"value":8572},{"type":46,"tag":99,"props":9145,"children":9147},{"className":9146},[],[9148],{"type":52,"value":5164},{"type":52,"value":9150}," fields). Ask Claude Code to adjust the query for you if needed.",{"type":46,"tag":55,"props":9152,"children":9153},{},[9154,9156,9165],{"type":52,"value":9155},"Create ",{"type":46,"tag":80,"props":9157,"children":9158},{},[9159],{"type":46,"tag":99,"props":9160,"children":9162},{"className":9161},[],[9163],{"type":52,"value":9164},"ecommerce\u002Fassets\u002Fstaging\u002Fstg_orders.sql",{"type":52,"value":9166},":",{"type":46,"tag":423,"props":9168,"children":9169},{":variants":425,"group":426},[9170,10115,11080],{"type":46,"tag":429,"props":9171,"children":9172},{"v-slot:clickhouse":7},[9173],{"type":46,"tag":240,"props":9174,"children":9178},{"className":9175,"code":9176,"language":9177,"meta":7,"style":7},"language-sql shiki shiki-themes github-dark","\u002F* @bruin\nname: staging.stg_orders\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.shopify_orders\n  - raw.stripe_charges\ncolumns:\n  - name: order_id\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n  - name: order_date\n    type: timestamp\n    checks:\n      - name: not_null\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM staging.stg_orders\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    o.id AS order_id,\n    o.order_number,\n    o.email AS customer_email,\n    o.created_at AS order_date,\n    o.financial_status AS payment_status,\n    o.fulfillment_status,\n    CAST(o.total_price AS DECIMAL(12,2)) AS order_total,\n    CAST(o.subtotal_price AS DECIMAL(12,2)) AS subtotal,\n    CAST(o.total_tax AS DECIMAL(12,2)) AS tax_amount,\n    CAST(o.total_discounts AS DECIMAL(12,2)) AS discount_amount,\n    o.currency,\n    o.cancel_reason,\n    o.cancelled_at,\n    c.amount \u002F 100.0 AS stripe_charge_amount,\n    c.status AS stripe_status,\n    c.paid AS stripe_paid\nFROM raw.shopify_orders o\nLEFT JOIN raw.stripe_charges c\n    ON o.email = c.receipt_email\n    AND toDate(o.created_at) = toDate(c.created)\n","sql",[9179],{"type":46,"tag":99,"props":9180,"children":9181},{"__ignoreMap":7},[9182,9191,9199,9207,9215,9223,9231,9239,9247,9255,9264,9273,9282,9291,9300,9308,9317,9325,9333,9342,9351,9360,9369,9378,9387,9396,9424,9446,9472,9498,9523,9544,9614,9676,9738,9800,9821,9842,9863,9909,9935,9961,9989,10015,10056],{"type":46,"tag":250,"props":9183,"children":9184},{"class":252,"line":23},[9185],{"type":46,"tag":250,"props":9186,"children":9188},{"style":9187},"--shiki-default:#6A737D",[9189],{"type":52,"value":9190},"\u002F* @bruin\n",{"type":46,"tag":250,"props":9192,"children":9193},{"class":252,"line":285},[9194],{"type":46,"tag":250,"props":9195,"children":9196},{"style":9187},[9197],{"type":52,"value":9198},"name: staging.stg_orders\n",{"type":46,"tag":250,"props":9200,"children":9201},{"class":252,"line":299},[9202],{"type":46,"tag":250,"props":9203,"children":9204},{"style":9187},[9205],{"type":52,"value":9206},"type: sql\n",{"type":46,"tag":250,"props":9208,"children":9209},{"class":252,"line":807},[9210],{"type":46,"tag":250,"props":9211,"children":9212},{"style":9187},[9213],{"type":52,"value":9214},"materialization:\n",{"type":46,"tag":250,"props":9216,"children":9217},{"class":252,"line":820},[9218],{"type":46,"tag":250,"props":9219,"children":9220},{"style":9187},[9221],{"type":52,"value":9222},"  type: table\n",{"type":46,"tag":250,"props":9224,"children":9225},{"class":252,"line":844},[9226],{"type":46,"tag":250,"props":9227,"children":9228},{"style":9187},[9229],{"type":52,"value":9230},"depends:\n",{"type":46,"tag":250,"props":9232,"children":9233},{"class":252,"line":862},[9234],{"type":46,"tag":250,"props":9235,"children":9236},{"style":9187},[9237],{"type":52,"value":9238},"  - raw.shopify_orders\n",{"type":46,"tag":250,"props":9240,"children":9241},{"class":252,"line":11},[9242],{"type":46,"tag":250,"props":9243,"children":9244},{"style":9187},[9245],{"type":52,"value":9246},"  - raw.stripe_charges\n",{"type":46,"tag":250,"props":9248,"children":9249},{"class":252,"line":4649},[9250],{"type":46,"tag":250,"props":9251,"children":9252},{"style":9187},[9253],{"type":52,"value":9254},"columns:\n",{"type":46,"tag":250,"props":9256,"children":9258},{"class":252,"line":9257},10,[9259],{"type":46,"tag":250,"props":9260,"children":9261},{"style":9187},[9262],{"type":52,"value":9263},"  - name: order_id\n",{"type":46,"tag":250,"props":9265,"children":9267},{"class":252,"line":9266},11,[9268],{"type":46,"tag":250,"props":9269,"children":9270},{"style":9187},[9271],{"type":52,"value":9272},"    type: varchar\n",{"type":46,"tag":250,"props":9274,"children":9276},{"class":252,"line":9275},12,[9277],{"type":46,"tag":250,"props":9278,"children":9279},{"style":9187},[9280],{"type":52,"value":9281},"    checks:\n",{"type":46,"tag":250,"props":9283,"children":9285},{"class":252,"line":9284},13,[9286],{"type":46,"tag":250,"props":9287,"children":9288},{"style":9187},[9289],{"type":52,"value":9290},"      - name: not_null\n",{"type":46,"tag":250,"props":9292,"children":9294},{"class":252,"line":9293},14,[9295],{"type":46,"tag":250,"props":9296,"children":9297},{"style":9187},[9298],{"type":52,"value":9299},"      - name: unique\n",{"type":46,"tag":250,"props":9301,"children":9302},{"class":252,"line":4121},[9303],{"type":46,"tag":250,"props":9304,"children":9305},{"style":9187},[9306],{"type":52,"value":9307},"  - name: order_date\n",{"type":46,"tag":250,"props":9309,"children":9311},{"class":252,"line":9310},16,[9312],{"type":46,"tag":250,"props":9313,"children":9314},{"style":9187},[9315],{"type":52,"value":9316},"    type: timestamp\n",{"type":46,"tag":250,"props":9318,"children":9320},{"class":252,"line":9319},17,[9321],{"type":46,"tag":250,"props":9322,"children":9323},{"style":9187},[9324],{"type":52,"value":9281},{"type":46,"tag":250,"props":9326,"children":9328},{"class":252,"line":9327},18,[9329],{"type":46,"tag":250,"props":9330,"children":9331},{"style":9187},[9332],{"type":52,"value":9290},{"type":46,"tag":250,"props":9334,"children":9336},{"class":252,"line":9335},19,[9337],{"type":46,"tag":250,"props":9338,"children":9339},{"style":9187},[9340],{"type":52,"value":9341},"custom_checks:\n",{"type":46,"tag":250,"props":9343,"children":9345},{"class":252,"line":9344},20,[9346],{"type":46,"tag":250,"props":9347,"children":9348},{"style":9187},[9349],{"type":52,"value":9350},"  - name: has_rows\n",{"type":46,"tag":250,"props":9352,"children":9354},{"class":252,"line":9353},21,[9355],{"type":46,"tag":250,"props":9356,"children":9357},{"style":9187},[9358],{"type":52,"value":9359},"    query: \"SELECT count(*) > 0 FROM staging.stg_orders\"\n",{"type":46,"tag":250,"props":9361,"children":9363},{"class":252,"line":9362},22,[9364],{"type":46,"tag":250,"props":9365,"children":9366},{"style":9187},[9367],{"type":52,"value":9368},"    value: 1\n",{"type":46,"tag":250,"props":9370,"children":9372},{"class":252,"line":9371},23,[9373],{"type":46,"tag":250,"props":9374,"children":9375},{"style":9187},[9376],{"type":52,"value":9377},"@bruin *\u002F\n",{"type":46,"tag":250,"props":9379,"children":9381},{"class":252,"line":9380},24,[9382],{"type":46,"tag":250,"props":9383,"children":9384},{"emptyLinePlaceholder":22},[9385],{"type":52,"value":9386},"\n",{"type":46,"tag":250,"props":9388,"children":9390},{"class":252,"line":9389},25,[9391],{"type":46,"tag":250,"props":9392,"children":9393},{"style":375},[9394],{"type":52,"value":9395},"SELECT\n",{"type":46,"tag":250,"props":9397,"children":9399},{"class":252,"line":9398},26,[9400,9405,9409,9414,9419],{"type":46,"tag":250,"props":9401,"children":9402},{"style":274},[9403],{"type":52,"value":9404},"    o",{"type":46,"tag":250,"props":9406,"children":9407},{"style":268},[9408],{"type":52,"value":106},{"type":46,"tag":250,"props":9410,"children":9411},{"style":274},[9412],{"type":52,"value":9413},"id",{"type":46,"tag":250,"props":9415,"children":9416},{"style":375},[9417],{"type":52,"value":9418}," AS",{"type":46,"tag":250,"props":9420,"children":9421},{"style":268},[9422],{"type":52,"value":9423}," order_id,\n",{"type":46,"tag":250,"props":9425,"children":9427},{"class":252,"line":9426},27,[9428,9432,9436,9441],{"type":46,"tag":250,"props":9429,"children":9430},{"style":274},[9431],{"type":52,"value":9404},{"type":46,"tag":250,"props":9433,"children":9434},{"style":268},[9435],{"type":52,"value":106},{"type":46,"tag":250,"props":9437,"children":9438},{"style":274},[9439],{"type":52,"value":9440},"order_number",{"type":46,"tag":250,"props":9442,"children":9443},{"style":268},[9444],{"type":52,"value":9445},",\n",{"type":46,"tag":250,"props":9447,"children":9449},{"class":252,"line":9448},28,[9450,9454,9458,9463,9467],{"type":46,"tag":250,"props":9451,"children":9452},{"style":274},[9453],{"type":52,"value":9404},{"type":46,"tag":250,"props":9455,"children":9456},{"style":268},[9457],{"type":52,"value":106},{"type":46,"tag":250,"props":9459,"children":9460},{"style":274},[9461],{"type":52,"value":9462},"email",{"type":46,"tag":250,"props":9464,"children":9465},{"style":375},[9466],{"type":52,"value":9418},{"type":46,"tag":250,"props":9468,"children":9469},{"style":268},[9470],{"type":52,"value":9471}," customer_email,\n",{"type":46,"tag":250,"props":9473,"children":9475},{"class":252,"line":9474},29,[9476,9480,9484,9489,9493],{"type":46,"tag":250,"props":9477,"children":9478},{"style":274},[9479],{"type":52,"value":9404},{"type":46,"tag":250,"props":9481,"children":9482},{"style":268},[9483],{"type":52,"value":106},{"type":46,"tag":250,"props":9485,"children":9486},{"style":274},[9487],{"type":52,"value":9488},"created_at",{"type":46,"tag":250,"props":9490,"children":9491},{"style":375},[9492],{"type":52,"value":9418},{"type":46,"tag":250,"props":9494,"children":9495},{"style":268},[9496],{"type":52,"value":9497}," order_date,\n",{"type":46,"tag":250,"props":9499,"children":9501},{"class":252,"line":9500},30,[9502,9506,9510,9514,9518],{"type":46,"tag":250,"props":9503,"children":9504},{"style":274},[9505],{"type":52,"value":9404},{"type":46,"tag":250,"props":9507,"children":9508},{"style":268},[9509],{"type":52,"value":106},{"type":46,"tag":250,"props":9511,"children":9512},{"style":274},[9513],{"type":52,"value":5157},{"type":46,"tag":250,"props":9515,"children":9516},{"style":375},[9517],{"type":52,"value":9418},{"type":46,"tag":250,"props":9519,"children":9520},{"style":268},[9521],{"type":52,"value":9522}," payment_status,\n",{"type":46,"tag":250,"props":9524,"children":9526},{"class":252,"line":9525},31,[9527,9531,9535,9540],{"type":46,"tag":250,"props":9528,"children":9529},{"style":274},[9530],{"type":52,"value":9404},{"type":46,"tag":250,"props":9532,"children":9533},{"style":268},[9534],{"type":52,"value":106},{"type":46,"tag":250,"props":9536,"children":9537},{"style":274},[9538],{"type":52,"value":9539},"fulfillment_status",{"type":46,"tag":250,"props":9541,"children":9542},{"style":268},[9543],{"type":52,"value":9445},{"type":46,"tag":250,"props":9545,"children":9547},{"class":252,"line":9546},32,[9548,9553,9558,9563,9567,9571,9575,9580,9584,9589,9594,9599,9604,9609],{"type":46,"tag":250,"props":9549,"children":9550},{"style":274},[9551],{"type":52,"value":9552},"    CAST",{"type":46,"tag":250,"props":9554,"children":9555},{"style":268},[9556],{"type":52,"value":9557},"(",{"type":46,"tag":250,"props":9559,"children":9560},{"style":274},[9561],{"type":52,"value":9562},"o",{"type":46,"tag":250,"props":9564,"children":9565},{"style":268},[9566],{"type":52,"value":106},{"type":46,"tag":250,"props":9568,"children":9569},{"style":274},[9570],{"type":52,"value":5164},{"type":46,"tag":250,"props":9572,"children":9573},{"style":375},[9574],{"type":52,"value":9418},{"type":46,"tag":250,"props":9576,"children":9577},{"style":375},[9578],{"type":52,"value":9579}," DECIMAL",{"type":46,"tag":250,"props":9581,"children":9582},{"style":268},[9583],{"type":52,"value":9557},{"type":46,"tag":250,"props":9585,"children":9586},{"style":274},[9587],{"type":52,"value":9588},"12",{"type":46,"tag":250,"props":9590,"children":9591},{"style":268},[9592],{"type":52,"value":9593},",",{"type":46,"tag":250,"props":9595,"children":9596},{"style":274},[9597],{"type":52,"value":9598},"2",{"type":46,"tag":250,"props":9600,"children":9601},{"style":268},[9602],{"type":52,"value":9603},")) ",{"type":46,"tag":250,"props":9605,"children":9606},{"style":375},[9607],{"type":52,"value":9608},"AS",{"type":46,"tag":250,"props":9610,"children":9611},{"style":268},[9612],{"type":52,"value":9613}," order_total,\n",{"type":46,"tag":250,"props":9615,"children":9617},{"class":252,"line":9616},33,[9618,9622,9626,9630,9634,9639,9643,9647,9651,9655,9659,9663,9667,9671],{"type":46,"tag":250,"props":9619,"children":9620},{"style":274},[9621],{"type":52,"value":9552},{"type":46,"tag":250,"props":9623,"children":9624},{"style":268},[9625],{"type":52,"value":9557},{"type":46,"tag":250,"props":9627,"children":9628},{"style":274},[9629],{"type":52,"value":9562},{"type":46,"tag":250,"props":9631,"children":9632},{"style":268},[9633],{"type":52,"value":106},{"type":46,"tag":250,"props":9635,"children":9636},{"style":274},[9637],{"type":52,"value":9638},"subtotal_price",{"type":46,"tag":250,"props":9640,"children":9641},{"style":375},[9642],{"type":52,"value":9418},{"type":46,"tag":250,"props":9644,"children":9645},{"style":375},[9646],{"type":52,"value":9579},{"type":46,"tag":250,"props":9648,"children":9649},{"style":268},[9650],{"type":52,"value":9557},{"type":46,"tag":250,"props":9652,"children":9653},{"style":274},[9654],{"type":52,"value":9588},{"type":46,"tag":250,"props":9656,"children":9657},{"style":268},[9658],{"type":52,"value":9593},{"type":46,"tag":250,"props":9660,"children":9661},{"style":274},[9662],{"type":52,"value":9598},{"type":46,"tag":250,"props":9664,"children":9665},{"style":268},[9666],{"type":52,"value":9603},{"type":46,"tag":250,"props":9668,"children":9669},{"style":375},[9670],{"type":52,"value":9608},{"type":46,"tag":250,"props":9672,"children":9673},{"style":268},[9674],{"type":52,"value":9675}," subtotal,\n",{"type":46,"tag":250,"props":9677,"children":9679},{"class":252,"line":9678},34,[9680,9684,9688,9692,9696,9701,9705,9709,9713,9717,9721,9725,9729,9733],{"type":46,"tag":250,"props":9681,"children":9682},{"style":274},[9683],{"type":52,"value":9552},{"type":46,"tag":250,"props":9685,"children":9686},{"style":268},[9687],{"type":52,"value":9557},{"type":46,"tag":250,"props":9689,"children":9690},{"style":274},[9691],{"type":52,"value":9562},{"type":46,"tag":250,"props":9693,"children":9694},{"style":268},[9695],{"type":52,"value":106},{"type":46,"tag":250,"props":9697,"children":9698},{"style":274},[9699],{"type":52,"value":9700},"total_tax",{"type":46,"tag":250,"props":9702,"children":9703},{"style":375},[9704],{"type":52,"value":9418},{"type":46,"tag":250,"props":9706,"children":9707},{"style":375},[9708],{"type":52,"value":9579},{"type":46,"tag":250,"props":9710,"children":9711},{"style":268},[9712],{"type":52,"value":9557},{"type":46,"tag":250,"props":9714,"children":9715},{"style":274},[9716],{"type":52,"value":9588},{"type":46,"tag":250,"props":9718,"children":9719},{"style":268},[9720],{"type":52,"value":9593},{"type":46,"tag":250,"props":9722,"children":9723},{"style":274},[9724],{"type":52,"value":9598},{"type":46,"tag":250,"props":9726,"children":9727},{"style":268},[9728],{"type":52,"value":9603},{"type":46,"tag":250,"props":9730,"children":9731},{"style":375},[9732],{"type":52,"value":9608},{"type":46,"tag":250,"props":9734,"children":9735},{"style":268},[9736],{"type":52,"value":9737}," tax_amount,\n",{"type":46,"tag":250,"props":9739,"children":9741},{"class":252,"line":9740},35,[9742,9746,9750,9754,9758,9763,9767,9771,9775,9779,9783,9787,9791,9795],{"type":46,"tag":250,"props":9743,"children":9744},{"style":274},[9745],{"type":52,"value":9552},{"type":46,"tag":250,"props":9747,"children":9748},{"style":268},[9749],{"type":52,"value":9557},{"type":46,"tag":250,"props":9751,"children":9752},{"style":274},[9753],{"type":52,"value":9562},{"type":46,"tag":250,"props":9755,"children":9756},{"style":268},[9757],{"type":52,"value":106},{"type":46,"tag":250,"props":9759,"children":9760},{"style":274},[9761],{"type":52,"value":9762},"total_discounts",{"type":46,"tag":250,"props":9764,"children":9765},{"style":375},[9766],{"type":52,"value":9418},{"type":46,"tag":250,"props":9768,"children":9769},{"style":375},[9770],{"type":52,"value":9579},{"type":46,"tag":250,"props":9772,"children":9773},{"style":268},[9774],{"type":52,"value":9557},{"type":46,"tag":250,"props":9776,"children":9777},{"style":274},[9778],{"type":52,"value":9588},{"type":46,"tag":250,"props":9780,"children":9781},{"style":268},[9782],{"type":52,"value":9593},{"type":46,"tag":250,"props":9784,"children":9785},{"style":274},[9786],{"type":52,"value":9598},{"type":46,"tag":250,"props":9788,"children":9789},{"style":268},[9790],{"type":52,"value":9603},{"type":46,"tag":250,"props":9792,"children":9793},{"style":375},[9794],{"type":52,"value":9608},{"type":46,"tag":250,"props":9796,"children":9797},{"style":268},[9798],{"type":52,"value":9799}," discount_amount,\n",{"type":46,"tag":250,"props":9801,"children":9803},{"class":252,"line":9802},36,[9804,9808,9812,9817],{"type":46,"tag":250,"props":9805,"children":9806},{"style":274},[9807],{"type":52,"value":9404},{"type":46,"tag":250,"props":9809,"children":9810},{"style":268},[9811],{"type":52,"value":106},{"type":46,"tag":250,"props":9813,"children":9814},{"style":274},[9815],{"type":52,"value":9816},"currency",{"type":46,"tag":250,"props":9818,"children":9819},{"style":268},[9820],{"type":52,"value":9445},{"type":46,"tag":250,"props":9822,"children":9824},{"class":252,"line":9823},37,[9825,9829,9833,9838],{"type":46,"tag":250,"props":9826,"children":9827},{"style":274},[9828],{"type":52,"value":9404},{"type":46,"tag":250,"props":9830,"children":9831},{"style":268},[9832],{"type":52,"value":106},{"type":46,"tag":250,"props":9834,"children":9835},{"style":274},[9836],{"type":52,"value":9837},"cancel_reason",{"type":46,"tag":250,"props":9839,"children":9840},{"style":268},[9841],{"type":52,"value":9445},{"type":46,"tag":250,"props":9843,"children":9845},{"class":252,"line":9844},38,[9846,9850,9854,9859],{"type":46,"tag":250,"props":9847,"children":9848},{"style":274},[9849],{"type":52,"value":9404},{"type":46,"tag":250,"props":9851,"children":9852},{"style":268},[9853],{"type":52,"value":106},{"type":46,"tag":250,"props":9855,"children":9856},{"style":274},[9857],{"type":52,"value":9858},"cancelled_at",{"type":46,"tag":250,"props":9860,"children":9861},{"style":268},[9862],{"type":52,"value":9445},{"type":46,"tag":250,"props":9864,"children":9866},{"class":252,"line":9865},39,[9867,9872,9876,9881,9886,9891,9895,9900,9904],{"type":46,"tag":250,"props":9868,"children":9869},{"style":274},[9870],{"type":52,"value":9871},"    c",{"type":46,"tag":250,"props":9873,"children":9874},{"style":268},[9875],{"type":52,"value":106},{"type":46,"tag":250,"props":9877,"children":9878},{"style":274},[9879],{"type":52,"value":9880},"amount",{"type":46,"tag":250,"props":9882,"children":9883},{"style":375},[9884],{"type":52,"value":9885}," \u002F",{"type":46,"tag":250,"props":9887,"children":9888},{"style":274},[9889],{"type":52,"value":9890}," 100",{"type":46,"tag":250,"props":9892,"children":9893},{"style":268},[9894],{"type":52,"value":106},{"type":46,"tag":250,"props":9896,"children":9897},{"style":274},[9898],{"type":52,"value":9899},"0",{"type":46,"tag":250,"props":9901,"children":9902},{"style":375},[9903],{"type":52,"value":9418},{"type":46,"tag":250,"props":9905,"children":9906},{"style":268},[9907],{"type":52,"value":9908}," stripe_charge_amount,\n",{"type":46,"tag":250,"props":9910,"children":9912},{"class":252,"line":9911},40,[9913,9917,9921,9926,9930],{"type":46,"tag":250,"props":9914,"children":9915},{"style":274},[9916],{"type":52,"value":9871},{"type":46,"tag":250,"props":9918,"children":9919},{"style":268},[9920],{"type":52,"value":106},{"type":46,"tag":250,"props":9922,"children":9923},{"style":274},[9924],{"type":52,"value":9925},"status",{"type":46,"tag":250,"props":9927,"children":9928},{"style":375},[9929],{"type":52,"value":9418},{"type":46,"tag":250,"props":9931,"children":9932},{"style":268},[9933],{"type":52,"value":9934}," stripe_status,\n",{"type":46,"tag":250,"props":9936,"children":9938},{"class":252,"line":9937},41,[9939,9943,9947,9952,9956],{"type":46,"tag":250,"props":9940,"children":9941},{"style":274},[9942],{"type":52,"value":9871},{"type":46,"tag":250,"props":9944,"children":9945},{"style":268},[9946],{"type":52,"value":106},{"type":46,"tag":250,"props":9948,"children":9949},{"style":274},[9950],{"type":52,"value":9951},"paid",{"type":46,"tag":250,"props":9953,"children":9954},{"style":375},[9955],{"type":52,"value":9418},{"type":46,"tag":250,"props":9957,"children":9958},{"style":268},[9959],{"type":52,"value":9960}," stripe_paid\n",{"type":46,"tag":250,"props":9962,"children":9964},{"class":252,"line":9963},42,[9965,9970,9975,9979,9984],{"type":46,"tag":250,"props":9966,"children":9967},{"style":375},[9968],{"type":52,"value":9969},"FROM",{"type":46,"tag":250,"props":9971,"children":9972},{"style":274},[9973],{"type":52,"value":9974}," raw",{"type":46,"tag":250,"props":9976,"children":9977},{"style":268},[9978],{"type":52,"value":106},{"type":46,"tag":250,"props":9980,"children":9981},{"style":274},[9982],{"type":52,"value":9983},"shopify_orders",{"type":46,"tag":250,"props":9985,"children":9986},{"style":268},[9987],{"type":52,"value":9988}," o\n",{"type":46,"tag":250,"props":9990,"children":9992},{"class":252,"line":9991},43,[9993,9997,10001,10005,10010],{"type":46,"tag":250,"props":9994,"children":9995},{"style":375},[9996],{"type":52,"value":9077},{"type":46,"tag":250,"props":9998,"children":9999},{"style":274},[10000],{"type":52,"value":9974},{"type":46,"tag":250,"props":10002,"children":10003},{"style":268},[10004],{"type":52,"value":106},{"type":46,"tag":250,"props":10006,"children":10007},{"style":274},[10008],{"type":52,"value":10009},"stripe_charges",{"type":46,"tag":250,"props":10011,"children":10012},{"style":268},[10013],{"type":52,"value":10014}," c\n",{"type":46,"tag":250,"props":10016,"children":10018},{"class":252,"line":10017},44,[10019,10024,10029,10033,10037,10042,10047,10051],{"type":46,"tag":250,"props":10020,"children":10021},{"style":375},[10022],{"type":52,"value":10023},"    ON",{"type":46,"tag":250,"props":10025,"children":10026},{"style":274},[10027],{"type":52,"value":10028}," o",{"type":46,"tag":250,"props":10030,"children":10031},{"style":268},[10032],{"type":52,"value":106},{"type":46,"tag":250,"props":10034,"children":10035},{"style":274},[10036],{"type":52,"value":9462},{"type":46,"tag":250,"props":10038,"children":10039},{"style":375},[10040],{"type":52,"value":10041}," =",{"type":46,"tag":250,"props":10043,"children":10044},{"style":274},[10045],{"type":52,"value":10046}," c",{"type":46,"tag":250,"props":10048,"children":10049},{"style":268},[10050],{"type":52,"value":106},{"type":46,"tag":250,"props":10052,"children":10053},{"style":274},[10054],{"type":52,"value":10055},"receipt_email\n",{"type":46,"tag":250,"props":10057,"children":10059},{"class":252,"line":10058},45,[10060,10065,10070,10074,10078,10082,10087,10092,10096,10101,10105,10110],{"type":46,"tag":250,"props":10061,"children":10062},{"style":375},[10063],{"type":52,"value":10064},"    AND",{"type":46,"tag":250,"props":10066,"children":10067},{"style":268},[10068],{"type":52,"value":10069}," toDate(",{"type":46,"tag":250,"props":10071,"children":10072},{"style":274},[10073],{"type":52,"value":9562},{"type":46,"tag":250,"props":10075,"children":10076},{"style":268},[10077],{"type":52,"value":106},{"type":46,"tag":250,"props":10079,"children":10080},{"style":274},[10081],{"type":52,"value":9488},{"type":46,"tag":250,"props":10083,"children":10084},{"style":268},[10085],{"type":52,"value":10086},") ",{"type":46,"tag":250,"props":10088,"children":10089},{"style":375},[10090],{"type":52,"value":10091},"=",{"type":46,"tag":250,"props":10093,"children":10094},{"style":268},[10095],{"type":52,"value":10069},{"type":46,"tag":250,"props":10097,"children":10098},{"style":274},[10099],{"type":52,"value":10100},"c",{"type":46,"tag":250,"props":10102,"children":10103},{"style":268},[10104],{"type":52,"value":106},{"type":46,"tag":250,"props":10106,"children":10107},{"style":274},[10108],{"type":52,"value":10109},"created",{"type":46,"tag":250,"props":10111,"children":10112},{"style":268},[10113],{"type":52,"value":10114},")\n",{"type":46,"tag":429,"props":10116,"children":10117},{"v-slot:bigquery":7},[10118],{"type":46,"tag":240,"props":10119,"children":10121},{"className":9175,"code":10120,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_orders\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.shopify_orders\n  - raw.stripe_charges\ncolumns:\n  - name: order_id\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n  - name: order_date\n    type: timestamp\n    checks:\n      - name: not_null\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM staging.stg_orders\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    o.id AS order_id,\n    o.order_number,\n    o.email AS customer_email,\n    o.created_at AS order_date,\n    o.financial_status AS payment_status,\n    o.fulfillment_status,\n    SAFE_CAST(o.total_price AS DECIMAL(12,2)) AS order_total,\n    SAFE_CAST(o.subtotal_price AS DECIMAL(12,2)) AS subtotal,\n    SAFE_CAST(o.total_tax AS DECIMAL(12,2)) AS tax_amount,\n    SAFE_CAST(o.total_discounts AS DECIMAL(12,2)) AS discount_amount,\n    o.currency,\n    o.cancel_reason,\n    o.cancelled_at,\n    c.amount \u002F 100.0 AS stripe_charge_amount,\n    c.status AS stripe_status,\n    c.paid AS stripe_paid\nFROM raw.shopify_orders o\nLEFT JOIN raw.stripe_charges c\n    ON o.email = c.receipt_email\n    AND DATE(o.created_at) = DATE(c.created)\nWHERE o.test IS NOT TRUE AND o.financial_status IS NOT NULL\nQUALIFY ROW_NUMBER() OVER (PARTITION BY o.id ORDER BY o.updated_at DESC) = 1\n",[10122],{"type":46,"tag":99,"props":10123,"children":10124},{"__ignoreMap":7},[10125,10132,10139,10146,10153,10160,10167,10174,10181,10188,10195,10202,10209,10216,10223,10230,10237,10244,10251,10258,10265,10272,10279,10286,10293,10300,10323,10342,10365,10388,10411,10430,10486,10541,10596,10651,10670,10689,10708,10747,10770,10793,10816,10839,10874,10934,10993],{"type":46,"tag":250,"props":10126,"children":10127},{"class":252,"line":23},[10128],{"type":46,"tag":250,"props":10129,"children":10130},{"style":9187},[10131],{"type":52,"value":9190},{"type":46,"tag":250,"props":10133,"children":10134},{"class":252,"line":285},[10135],{"type":46,"tag":250,"props":10136,"children":10137},{"style":9187},[10138],{"type":52,"value":9198},{"type":46,"tag":250,"props":10140,"children":10141},{"class":252,"line":299},[10142],{"type":46,"tag":250,"props":10143,"children":10144},{"style":9187},[10145],{"type":52,"value":9206},{"type":46,"tag":250,"props":10147,"children":10148},{"class":252,"line":807},[10149],{"type":46,"tag":250,"props":10150,"children":10151},{"style":9187},[10152],{"type":52,"value":9214},{"type":46,"tag":250,"props":10154,"children":10155},{"class":252,"line":820},[10156],{"type":46,"tag":250,"props":10157,"children":10158},{"style":9187},[10159],{"type":52,"value":9222},{"type":46,"tag":250,"props":10161,"children":10162},{"class":252,"line":844},[10163],{"type":46,"tag":250,"props":10164,"children":10165},{"style":9187},[10166],{"type":52,"value":9230},{"type":46,"tag":250,"props":10168,"children":10169},{"class":252,"line":862},[10170],{"type":46,"tag":250,"props":10171,"children":10172},{"style":9187},[10173],{"type":52,"value":9238},{"type":46,"tag":250,"props":10175,"children":10176},{"class":252,"line":11},[10177],{"type":46,"tag":250,"props":10178,"children":10179},{"style":9187},[10180],{"type":52,"value":9246},{"type":46,"tag":250,"props":10182,"children":10183},{"class":252,"line":4649},[10184],{"type":46,"tag":250,"props":10185,"children":10186},{"style":9187},[10187],{"type":52,"value":9254},{"type":46,"tag":250,"props":10189,"children":10190},{"class":252,"line":9257},[10191],{"type":46,"tag":250,"props":10192,"children":10193},{"style":9187},[10194],{"type":52,"value":9263},{"type":46,"tag":250,"props":10196,"children":10197},{"class":252,"line":9266},[10198],{"type":46,"tag":250,"props":10199,"children":10200},{"style":9187},[10201],{"type":52,"value":9272},{"type":46,"tag":250,"props":10203,"children":10204},{"class":252,"line":9275},[10205],{"type":46,"tag":250,"props":10206,"children":10207},{"style":9187},[10208],{"type":52,"value":9281},{"type":46,"tag":250,"props":10210,"children":10211},{"class":252,"line":9284},[10212],{"type":46,"tag":250,"props":10213,"children":10214},{"style":9187},[10215],{"type":52,"value":9290},{"type":46,"tag":250,"props":10217,"children":10218},{"class":252,"line":9293},[10219],{"type":46,"tag":250,"props":10220,"children":10221},{"style":9187},[10222],{"type":52,"value":9299},{"type":46,"tag":250,"props":10224,"children":10225},{"class":252,"line":4121},[10226],{"type":46,"tag":250,"props":10227,"children":10228},{"style":9187},[10229],{"type":52,"value":9307},{"type":46,"tag":250,"props":10231,"children":10232},{"class":252,"line":9310},[10233],{"type":46,"tag":250,"props":10234,"children":10235},{"style":9187},[10236],{"type":52,"value":9316},{"type":46,"tag":250,"props":10238,"children":10239},{"class":252,"line":9319},[10240],{"type":46,"tag":250,"props":10241,"children":10242},{"style":9187},[10243],{"type":52,"value":9281},{"type":46,"tag":250,"props":10245,"children":10246},{"class":252,"line":9327},[10247],{"type":46,"tag":250,"props":10248,"children":10249},{"style":9187},[10250],{"type":52,"value":9290},{"type":46,"tag":250,"props":10252,"children":10253},{"class":252,"line":9335},[10254],{"type":46,"tag":250,"props":10255,"children":10256},{"style":9187},[10257],{"type":52,"value":9341},{"type":46,"tag":250,"props":10259,"children":10260},{"class":252,"line":9344},[10261],{"type":46,"tag":250,"props":10262,"children":10263},{"style":9187},[10264],{"type":52,"value":9350},{"type":46,"tag":250,"props":10266,"children":10267},{"class":252,"line":9353},[10268],{"type":46,"tag":250,"props":10269,"children":10270},{"style":9187},[10271],{"type":52,"value":9359},{"type":46,"tag":250,"props":10273,"children":10274},{"class":252,"line":9362},[10275],{"type":46,"tag":250,"props":10276,"children":10277},{"style":9187},[10278],{"type":52,"value":9368},{"type":46,"tag":250,"props":10280,"children":10281},{"class":252,"line":9371},[10282],{"type":46,"tag":250,"props":10283,"children":10284},{"style":9187},[10285],{"type":52,"value":9377},{"type":46,"tag":250,"props":10287,"children":10288},{"class":252,"line":9380},[10289],{"type":46,"tag":250,"props":10290,"children":10291},{"emptyLinePlaceholder":22},[10292],{"type":52,"value":9386},{"type":46,"tag":250,"props":10294,"children":10295},{"class":252,"line":9389},[10296],{"type":46,"tag":250,"props":10297,"children":10298},{"style":375},[10299],{"type":52,"value":9395},{"type":46,"tag":250,"props":10301,"children":10302},{"class":252,"line":9398},[10303,10307,10311,10315,10319],{"type":46,"tag":250,"props":10304,"children":10305},{"style":274},[10306],{"type":52,"value":9404},{"type":46,"tag":250,"props":10308,"children":10309},{"style":268},[10310],{"type":52,"value":106},{"type":46,"tag":250,"props":10312,"children":10313},{"style":274},[10314],{"type":52,"value":9413},{"type":46,"tag":250,"props":10316,"children":10317},{"style":375},[10318],{"type":52,"value":9418},{"type":46,"tag":250,"props":10320,"children":10321},{"style":268},[10322],{"type":52,"value":9423},{"type":46,"tag":250,"props":10324,"children":10325},{"class":252,"line":9426},[10326,10330,10334,10338],{"type":46,"tag":250,"props":10327,"children":10328},{"style":274},[10329],{"type":52,"value":9404},{"type":46,"tag":250,"props":10331,"children":10332},{"style":268},[10333],{"type":52,"value":106},{"type":46,"tag":250,"props":10335,"children":10336},{"style":274},[10337],{"type":52,"value":9440},{"type":46,"tag":250,"props":10339,"children":10340},{"style":268},[10341],{"type":52,"value":9445},{"type":46,"tag":250,"props":10343,"children":10344},{"class":252,"line":9448},[10345,10349,10353,10357,10361],{"type":46,"tag":250,"props":10346,"children":10347},{"style":274},[10348],{"type":52,"value":9404},{"type":46,"tag":250,"props":10350,"children":10351},{"style":268},[10352],{"type":52,"value":106},{"type":46,"tag":250,"props":10354,"children":10355},{"style":274},[10356],{"type":52,"value":9462},{"type":46,"tag":250,"props":10358,"children":10359},{"style":375},[10360],{"type":52,"value":9418},{"type":46,"tag":250,"props":10362,"children":10363},{"style":268},[10364],{"type":52,"value":9471},{"type":46,"tag":250,"props":10366,"children":10367},{"class":252,"line":9474},[10368,10372,10376,10380,10384],{"type":46,"tag":250,"props":10369,"children":10370},{"style":274},[10371],{"type":52,"value":9404},{"type":46,"tag":250,"props":10373,"children":10374},{"style":268},[10375],{"type":52,"value":106},{"type":46,"tag":250,"props":10377,"children":10378},{"style":274},[10379],{"type":52,"value":9488},{"type":46,"tag":250,"props":10381,"children":10382},{"style":375},[10383],{"type":52,"value":9418},{"type":46,"tag":250,"props":10385,"children":10386},{"style":268},[10387],{"type":52,"value":9497},{"type":46,"tag":250,"props":10389,"children":10390},{"class":252,"line":9500},[10391,10395,10399,10403,10407],{"type":46,"tag":250,"props":10392,"children":10393},{"style":274},[10394],{"type":52,"value":9404},{"type":46,"tag":250,"props":10396,"children":10397},{"style":268},[10398],{"type":52,"value":106},{"type":46,"tag":250,"props":10400,"children":10401},{"style":274},[10402],{"type":52,"value":5157},{"type":46,"tag":250,"props":10404,"children":10405},{"style":375},[10406],{"type":52,"value":9418},{"type":46,"tag":250,"props":10408,"children":10409},{"style":268},[10410],{"type":52,"value":9522},{"type":46,"tag":250,"props":10412,"children":10413},{"class":252,"line":9525},[10414,10418,10422,10426],{"type":46,"tag":250,"props":10415,"children":10416},{"style":274},[10417],{"type":52,"value":9404},{"type":46,"tag":250,"props":10419,"children":10420},{"style":268},[10421],{"type":52,"value":106},{"type":46,"tag":250,"props":10423,"children":10424},{"style":274},[10425],{"type":52,"value":9539},{"type":46,"tag":250,"props":10427,"children":10428},{"style":268},[10429],{"type":52,"value":9445},{"type":46,"tag":250,"props":10431,"children":10432},{"class":252,"line":9546},[10433,10438,10442,10446,10450,10454,10458,10462,10466,10470,10474,10478,10482],{"type":46,"tag":250,"props":10434,"children":10435},{"style":268},[10436],{"type":52,"value":10437},"    SAFE_CAST(",{"type":46,"tag":250,"props":10439,"children":10440},{"style":274},[10441],{"type":52,"value":9562},{"type":46,"tag":250,"props":10443,"children":10444},{"style":268},[10445],{"type":52,"value":106},{"type":46,"tag":250,"props":10447,"children":10448},{"style":274},[10449],{"type":52,"value":5164},{"type":46,"tag":250,"props":10451,"children":10452},{"style":375},[10453],{"type":52,"value":9418},{"type":46,"tag":250,"props":10455,"children":10456},{"style":375},[10457],{"type":52,"value":9579},{"type":46,"tag":250,"props":10459,"children":10460},{"style":268},[10461],{"type":52,"value":9557},{"type":46,"tag":250,"props":10463,"children":10464},{"style":274},[10465],{"type":52,"value":9588},{"type":46,"tag":250,"props":10467,"children":10468},{"style":268},[10469],{"type":52,"value":9593},{"type":46,"tag":250,"props":10471,"children":10472},{"style":274},[10473],{"type":52,"value":9598},{"type":46,"tag":250,"props":10475,"children":10476},{"style":268},[10477],{"type":52,"value":9603},{"type":46,"tag":250,"props":10479,"children":10480},{"style":375},[10481],{"type":52,"value":9608},{"type":46,"tag":250,"props":10483,"children":10484},{"style":268},[10485],{"type":52,"value":9613},{"type":46,"tag":250,"props":10487,"children":10488},{"class":252,"line":9616},[10489,10493,10497,10501,10505,10509,10513,10517,10521,10525,10529,10533,10537],{"type":46,"tag":250,"props":10490,"children":10491},{"style":268},[10492],{"type":52,"value":10437},{"type":46,"tag":250,"props":10494,"children":10495},{"style":274},[10496],{"type":52,"value":9562},{"type":46,"tag":250,"props":10498,"children":10499},{"style":268},[10500],{"type":52,"value":106},{"type":46,"tag":250,"props":10502,"children":10503},{"style":274},[10504],{"type":52,"value":9638},{"type":46,"tag":250,"props":10506,"children":10507},{"style":375},[10508],{"type":52,"value":9418},{"type":46,"tag":250,"props":10510,"children":10511},{"style":375},[10512],{"type":52,"value":9579},{"type":46,"tag":250,"props":10514,"children":10515},{"style":268},[10516],{"type":52,"value":9557},{"type":46,"tag":250,"props":10518,"children":10519},{"style":274},[10520],{"type":52,"value":9588},{"type":46,"tag":250,"props":10522,"children":10523},{"style":268},[10524],{"type":52,"value":9593},{"type":46,"tag":250,"props":10526,"children":10527},{"style":274},[10528],{"type":52,"value":9598},{"type":46,"tag":250,"props":10530,"children":10531},{"style":268},[10532],{"type":52,"value":9603},{"type":46,"tag":250,"props":10534,"children":10535},{"style":375},[10536],{"type":52,"value":9608},{"type":46,"tag":250,"props":10538,"children":10539},{"style":268},[10540],{"type":52,"value":9675},{"type":46,"tag":250,"props":10542,"children":10543},{"class":252,"line":9678},[10544,10548,10552,10556,10560,10564,10568,10572,10576,10580,10584,10588,10592],{"type":46,"tag":250,"props":10545,"children":10546},{"style":268},[10547],{"type":52,"value":10437},{"type":46,"tag":250,"props":10549,"children":10550},{"style":274},[10551],{"type":52,"value":9562},{"type":46,"tag":250,"props":10553,"children":10554},{"style":268},[10555],{"type":52,"value":106},{"type":46,"tag":250,"props":10557,"children":10558},{"style":274},[10559],{"type":52,"value":9700},{"type":46,"tag":250,"props":10561,"children":10562},{"style":375},[10563],{"type":52,"value":9418},{"type":46,"tag":250,"props":10565,"children":10566},{"style":375},[10567],{"type":52,"value":9579},{"type":46,"tag":250,"props":10569,"children":10570},{"style":268},[10571],{"type":52,"value":9557},{"type":46,"tag":250,"props":10573,"children":10574},{"style":274},[10575],{"type":52,"value":9588},{"type":46,"tag":250,"props":10577,"children":10578},{"style":268},[10579],{"type":52,"value":9593},{"type":46,"tag":250,"props":10581,"children":10582},{"style":274},[10583],{"type":52,"value":9598},{"type":46,"tag":250,"props":10585,"children":10586},{"style":268},[10587],{"type":52,"value":9603},{"type":46,"tag":250,"props":10589,"children":10590},{"style":375},[10591],{"type":52,"value":9608},{"type":46,"tag":250,"props":10593,"children":10594},{"style":268},[10595],{"type":52,"value":9737},{"type":46,"tag":250,"props":10597,"children":10598},{"class":252,"line":9740},[10599,10603,10607,10611,10615,10619,10623,10627,10631,10635,10639,10643,10647],{"type":46,"tag":250,"props":10600,"children":10601},{"style":268},[10602],{"type":52,"value":10437},{"type":46,"tag":250,"props":10604,"children":10605},{"style":274},[10606],{"type":52,"value":9562},{"type":46,"tag":250,"props":10608,"children":10609},{"style":268},[10610],{"type":52,"value":106},{"type":46,"tag":250,"props":10612,"children":10613},{"style":274},[10614],{"type":52,"value":9762},{"type":46,"tag":250,"props":10616,"children":10617},{"style":375},[10618],{"type":52,"value":9418},{"type":46,"tag":250,"props":10620,"children":10621},{"style":375},[10622],{"type":52,"value":9579},{"type":46,"tag":250,"props":10624,"children":10625},{"style":268},[10626],{"type":52,"value":9557},{"type":46,"tag":250,"props":10628,"children":10629},{"style":274},[10630],{"type":52,"value":9588},{"type":46,"tag":250,"props":10632,"children":10633},{"style":268},[10634],{"type":52,"value":9593},{"type":46,"tag":250,"props":10636,"children":10637},{"style":274},[10638],{"type":52,"value":9598},{"type":46,"tag":250,"props":10640,"children":10641},{"style":268},[10642],{"type":52,"value":9603},{"type":46,"tag":250,"props":10644,"children":10645},{"style":375},[10646],{"type":52,"value":9608},{"type":46,"tag":250,"props":10648,"children":10649},{"style":268},[10650],{"type":52,"value":9799},{"type":46,"tag":250,"props":10652,"children":10653},{"class":252,"line":9802},[10654,10658,10662,10666],{"type":46,"tag":250,"props":10655,"children":10656},{"style":274},[10657],{"type":52,"value":9404},{"type":46,"tag":250,"props":10659,"children":10660},{"style":268},[10661],{"type":52,"value":106},{"type":46,"tag":250,"props":10663,"children":10664},{"style":274},[10665],{"type":52,"value":9816},{"type":46,"tag":250,"props":10667,"children":10668},{"style":268},[10669],{"type":52,"value":9445},{"type":46,"tag":250,"props":10671,"children":10672},{"class":252,"line":9823},[10673,10677,10681,10685],{"type":46,"tag":250,"props":10674,"children":10675},{"style":274},[10676],{"type":52,"value":9404},{"type":46,"tag":250,"props":10678,"children":10679},{"style":268},[10680],{"type":52,"value":106},{"type":46,"tag":250,"props":10682,"children":10683},{"style":274},[10684],{"type":52,"value":9837},{"type":46,"tag":250,"props":10686,"children":10687},{"style":268},[10688],{"type":52,"value":9445},{"type":46,"tag":250,"props":10690,"children":10691},{"class":252,"line":9844},[10692,10696,10700,10704],{"type":46,"tag":250,"props":10693,"children":10694},{"style":274},[10695],{"type":52,"value":9404},{"type":46,"tag":250,"props":10697,"children":10698},{"style":268},[10699],{"type":52,"value":106},{"type":46,"tag":250,"props":10701,"children":10702},{"style":274},[10703],{"type":52,"value":9858},{"type":46,"tag":250,"props":10705,"children":10706},{"style":268},[10707],{"type":52,"value":9445},{"type":46,"tag":250,"props":10709,"children":10710},{"class":252,"line":9865},[10711,10715,10719,10723,10727,10731,10735,10739,10743],{"type":46,"tag":250,"props":10712,"children":10713},{"style":274},[10714],{"type":52,"value":9871},{"type":46,"tag":250,"props":10716,"children":10717},{"style":268},[10718],{"type":52,"value":106},{"type":46,"tag":250,"props":10720,"children":10721},{"style":274},[10722],{"type":52,"value":9880},{"type":46,"tag":250,"props":10724,"children":10725},{"style":375},[10726],{"type":52,"value":9885},{"type":46,"tag":250,"props":10728,"children":10729},{"style":274},[10730],{"type":52,"value":9890},{"type":46,"tag":250,"props":10732,"children":10733},{"style":268},[10734],{"type":52,"value":106},{"type":46,"tag":250,"props":10736,"children":10737},{"style":274},[10738],{"type":52,"value":9899},{"type":46,"tag":250,"props":10740,"children":10741},{"style":375},[10742],{"type":52,"value":9418},{"type":46,"tag":250,"props":10744,"children":10745},{"style":268},[10746],{"type":52,"value":9908},{"type":46,"tag":250,"props":10748,"children":10749},{"class":252,"line":9911},[10750,10754,10758,10762,10766],{"type":46,"tag":250,"props":10751,"children":10752},{"style":274},[10753],{"type":52,"value":9871},{"type":46,"tag":250,"props":10755,"children":10756},{"style":268},[10757],{"type":52,"value":106},{"type":46,"tag":250,"props":10759,"children":10760},{"style":274},[10761],{"type":52,"value":9925},{"type":46,"tag":250,"props":10763,"children":10764},{"style":375},[10765],{"type":52,"value":9418},{"type":46,"tag":250,"props":10767,"children":10768},{"style":268},[10769],{"type":52,"value":9934},{"type":46,"tag":250,"props":10771,"children":10772},{"class":252,"line":9937},[10773,10777,10781,10785,10789],{"type":46,"tag":250,"props":10774,"children":10775},{"style":274},[10776],{"type":52,"value":9871},{"type":46,"tag":250,"props":10778,"children":10779},{"style":268},[10780],{"type":52,"value":106},{"type":46,"tag":250,"props":10782,"children":10783},{"style":274},[10784],{"type":52,"value":9951},{"type":46,"tag":250,"props":10786,"children":10787},{"style":375},[10788],{"type":52,"value":9418},{"type":46,"tag":250,"props":10790,"children":10791},{"style":268},[10792],{"type":52,"value":9960},{"type":46,"tag":250,"props":10794,"children":10795},{"class":252,"line":9963},[10796,10800,10804,10808,10812],{"type":46,"tag":250,"props":10797,"children":10798},{"style":375},[10799],{"type":52,"value":9969},{"type":46,"tag":250,"props":10801,"children":10802},{"style":274},[10803],{"type":52,"value":9974},{"type":46,"tag":250,"props":10805,"children":10806},{"style":268},[10807],{"type":52,"value":106},{"type":46,"tag":250,"props":10809,"children":10810},{"style":274},[10811],{"type":52,"value":9983},{"type":46,"tag":250,"props":10813,"children":10814},{"style":268},[10815],{"type":52,"value":9988},{"type":46,"tag":250,"props":10817,"children":10818},{"class":252,"line":9991},[10819,10823,10827,10831,10835],{"type":46,"tag":250,"props":10820,"children":10821},{"style":375},[10822],{"type":52,"value":9077},{"type":46,"tag":250,"props":10824,"children":10825},{"style":274},[10826],{"type":52,"value":9974},{"type":46,"tag":250,"props":10828,"children":10829},{"style":268},[10830],{"type":52,"value":106},{"type":46,"tag":250,"props":10832,"children":10833},{"style":274},[10834],{"type":52,"value":10009},{"type":46,"tag":250,"props":10836,"children":10837},{"style":268},[10838],{"type":52,"value":10014},{"type":46,"tag":250,"props":10840,"children":10841},{"class":252,"line":10017},[10842,10846,10850,10854,10858,10862,10866,10870],{"type":46,"tag":250,"props":10843,"children":10844},{"style":375},[10845],{"type":52,"value":10023},{"type":46,"tag":250,"props":10847,"children":10848},{"style":274},[10849],{"type":52,"value":10028},{"type":46,"tag":250,"props":10851,"children":10852},{"style":268},[10853],{"type":52,"value":106},{"type":46,"tag":250,"props":10855,"children":10856},{"style":274},[10857],{"type":52,"value":9462},{"type":46,"tag":250,"props":10859,"children":10860},{"style":375},[10861],{"type":52,"value":10041},{"type":46,"tag":250,"props":10863,"children":10864},{"style":274},[10865],{"type":52,"value":10046},{"type":46,"tag":250,"props":10867,"children":10868},{"style":268},[10869],{"type":52,"value":106},{"type":46,"tag":250,"props":10871,"children":10872},{"style":274},[10873],{"type":52,"value":10055},{"type":46,"tag":250,"props":10875,"children":10876},{"class":252,"line":10058},[10877,10881,10886,10890,10894,10898,10902,10906,10910,10914,10918,10922,10926,10930],{"type":46,"tag":250,"props":10878,"children":10879},{"style":375},[10880],{"type":52,"value":10064},{"type":46,"tag":250,"props":10882,"children":10883},{"style":375},[10884],{"type":52,"value":10885}," DATE",{"type":46,"tag":250,"props":10887,"children":10888},{"style":268},[10889],{"type":52,"value":9557},{"type":46,"tag":250,"props":10891,"children":10892},{"style":274},[10893],{"type":52,"value":9562},{"type":46,"tag":250,"props":10895,"children":10896},{"style":268},[10897],{"type":52,"value":106},{"type":46,"tag":250,"props":10899,"children":10900},{"style":274},[10901],{"type":52,"value":9488},{"type":46,"tag":250,"props":10903,"children":10904},{"style":268},[10905],{"type":52,"value":10086},{"type":46,"tag":250,"props":10907,"children":10908},{"style":375},[10909],{"type":52,"value":10091},{"type":46,"tag":250,"props":10911,"children":10912},{"style":375},[10913],{"type":52,"value":10885},{"type":46,"tag":250,"props":10915,"children":10916},{"style":268},[10917],{"type":52,"value":9557},{"type":46,"tag":250,"props":10919,"children":10920},{"style":274},[10921],{"type":52,"value":10100},{"type":46,"tag":250,"props":10923,"children":10924},{"style":268},[10925],{"type":52,"value":106},{"type":46,"tag":250,"props":10927,"children":10928},{"style":274},[10929],{"type":52,"value":10109},{"type":46,"tag":250,"props":10931,"children":10932},{"style":268},[10933],{"type":52,"value":10114},{"type":46,"tag":250,"props":10935,"children":10937},{"class":252,"line":10936},46,[10938,10943,10947,10951,10956,10961,10966,10971,10976,10980,10984,10988],{"type":46,"tag":250,"props":10939,"children":10940},{"style":375},[10941],{"type":52,"value":10942},"WHERE",{"type":46,"tag":250,"props":10944,"children":10945},{"style":274},[10946],{"type":52,"value":10028},{"type":46,"tag":250,"props":10948,"children":10949},{"style":268},[10950],{"type":52,"value":106},{"type":46,"tag":250,"props":10952,"children":10953},{"style":274},[10954],{"type":52,"value":10955},"test",{"type":46,"tag":250,"props":10957,"children":10958},{"style":375},[10959],{"type":52,"value":10960}," IS",{"type":46,"tag":250,"props":10962,"children":10963},{"style":375},[10964],{"type":52,"value":10965}," NOT",{"type":46,"tag":250,"props":10967,"children":10968},{"style":268},[10969],{"type":52,"value":10970}," TRUE ",{"type":46,"tag":250,"props":10972,"children":10973},{"style":375},[10974],{"type":52,"value":10975},"AND",{"type":46,"tag":250,"props":10977,"children":10978},{"style":274},[10979],{"type":52,"value":10028},{"type":46,"tag":250,"props":10981,"children":10982},{"style":268},[10983],{"type":52,"value":106},{"type":46,"tag":250,"props":10985,"children":10986},{"style":274},[10987],{"type":52,"value":5157},{"type":46,"tag":250,"props":10989,"children":10990},{"style":375},[10991],{"type":52,"value":10992}," IS NOT NULL\n",{"type":46,"tag":250,"props":10994,"children":10996},{"class":252,"line":10995},47,[10997,11002,11007,11012,11017,11022,11027,11032,11036,11040,11044,11049,11053,11057,11062,11067,11071,11075],{"type":46,"tag":250,"props":10998,"children":10999},{"style":268},[11000],{"type":52,"value":11001},"QUALIFY ",{"type":46,"tag":250,"props":11003,"children":11004},{"style":274},[11005],{"type":52,"value":11006},"ROW_NUMBER",{"type":46,"tag":250,"props":11008,"children":11009},{"style":268},[11010],{"type":52,"value":11011},"() ",{"type":46,"tag":250,"props":11013,"children":11014},{"style":375},[11015],{"type":52,"value":11016},"OVER",{"type":46,"tag":250,"props":11018,"children":11019},{"style":268},[11020],{"type":52,"value":11021}," (",{"type":46,"tag":250,"props":11023,"children":11024},{"style":375},[11025],{"type":52,"value":11026},"PARTITION",{"type":46,"tag":250,"props":11028,"children":11029},{"style":375},[11030],{"type":52,"value":11031}," BY",{"type":46,"tag":250,"props":11033,"children":11034},{"style":274},[11035],{"type":52,"value":10028},{"type":46,"tag":250,"props":11037,"children":11038},{"style":268},[11039],{"type":52,"value":106},{"type":46,"tag":250,"props":11041,"children":11042},{"style":274},[11043],{"type":52,"value":9413},{"type":46,"tag":250,"props":11045,"children":11046},{"style":375},[11047],{"type":52,"value":11048}," ORDER BY",{"type":46,"tag":250,"props":11050,"children":11051},{"style":274},[11052],{"type":52,"value":10028},{"type":46,"tag":250,"props":11054,"children":11055},{"style":268},[11056],{"type":52,"value":106},{"type":46,"tag":250,"props":11058,"children":11059},{"style":274},[11060],{"type":52,"value":11061},"updated_at",{"type":46,"tag":250,"props":11063,"children":11064},{"style":375},[11065],{"type":52,"value":11066}," DESC",{"type":46,"tag":250,"props":11068,"children":11069},{"style":268},[11070],{"type":52,"value":10086},{"type":46,"tag":250,"props":11072,"children":11073},{"style":375},[11074],{"type":52,"value":10091},{"type":46,"tag":250,"props":11076,"children":11077},{"style":274},[11078],{"type":52,"value":11079}," 1\n",{"type":46,"tag":429,"props":11081,"children":11082},{"v-slot:snowflake":7},[11083],{"type":46,"tag":240,"props":11084,"children":11086},{"className":9175,"code":11085,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_orders\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.shopify_orders\n  - raw.stripe_charges\ncolumns:\n  - name: order_id\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n  - name: order_date\n    type: timestamp\n    checks:\n      - name: not_null\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM staging.stg_orders\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    o.id AS order_id,\n    o.order_number,\n    o.email AS customer_email,\n    o.created_at AS order_date,\n    o.financial_status AS payment_status,\n    o.fulfillment_status,\n    CAST(o.total_price AS DECIMAL(12,2)) AS order_total,\n    CAST(o.subtotal_price AS DECIMAL(12,2)) AS subtotal,\n    CAST(o.total_tax AS DECIMAL(12,2)) AS tax_amount,\n    CAST(o.total_discounts AS DECIMAL(12,2)) AS discount_amount,\n    o.currency,\n    o.cancel_reason,\n    o.cancelled_at,\n    c.amount \u002F 100.0 AS stripe_charge_amount,\n    c.status AS stripe_status,\n    c.paid AS stripe_paid\nFROM raw.shopify_orders o\nLEFT JOIN raw.stripe_charges c\n    ON o.email = c.receipt_email\n    AND o.created_at::DATE = c.created::DATE\n",[11087],{"type":46,"tag":99,"props":11088,"children":11089},{"__ignoreMap":7},[11090,11097,11104,11111,11118,11125,11132,11139,11146,11153,11160,11167,11174,11181,11188,11195,11202,11209,11216,11223,11230,11237,11244,11251,11258,11265,11288,11307,11330,11353,11376,11395,11454,11513,11572,11631,11650,11669,11688,11727,11750,11773,11796,11819,11854],{"type":46,"tag":250,"props":11091,"children":11092},{"class":252,"line":23},[11093],{"type":46,"tag":250,"props":11094,"children":11095},{"style":9187},[11096],{"type":52,"value":9190},{"type":46,"tag":250,"props":11098,"children":11099},{"class":252,"line":285},[11100],{"type":46,"tag":250,"props":11101,"children":11102},{"style":9187},[11103],{"type":52,"value":9198},{"type":46,"tag":250,"props":11105,"children":11106},{"class":252,"line":299},[11107],{"type":46,"tag":250,"props":11108,"children":11109},{"style":9187},[11110],{"type":52,"value":9206},{"type":46,"tag":250,"props":11112,"children":11113},{"class":252,"line":807},[11114],{"type":46,"tag":250,"props":11115,"children":11116},{"style":9187},[11117],{"type":52,"value":9214},{"type":46,"tag":250,"props":11119,"children":11120},{"class":252,"line":820},[11121],{"type":46,"tag":250,"props":11122,"children":11123},{"style":9187},[11124],{"type":52,"value":9222},{"type":46,"tag":250,"props":11126,"children":11127},{"class":252,"line":844},[11128],{"type":46,"tag":250,"props":11129,"children":11130},{"style":9187},[11131],{"type":52,"value":9230},{"type":46,"tag":250,"props":11133,"children":11134},{"class":252,"line":862},[11135],{"type":46,"tag":250,"props":11136,"children":11137},{"style":9187},[11138],{"type":52,"value":9238},{"type":46,"tag":250,"props":11140,"children":11141},{"class":252,"line":11},[11142],{"type":46,"tag":250,"props":11143,"children":11144},{"style":9187},[11145],{"type":52,"value":9246},{"type":46,"tag":250,"props":11147,"children":11148},{"class":252,"line":4649},[11149],{"type":46,"tag":250,"props":11150,"children":11151},{"style":9187},[11152],{"type":52,"value":9254},{"type":46,"tag":250,"props":11154,"children":11155},{"class":252,"line":9257},[11156],{"type":46,"tag":250,"props":11157,"children":11158},{"style":9187},[11159],{"type":52,"value":9263},{"type":46,"tag":250,"props":11161,"children":11162},{"class":252,"line":9266},[11163],{"type":46,"tag":250,"props":11164,"children":11165},{"style":9187},[11166],{"type":52,"value":9272},{"type":46,"tag":250,"props":11168,"children":11169},{"class":252,"line":9275},[11170],{"type":46,"tag":250,"props":11171,"children":11172},{"style":9187},[11173],{"type":52,"value":9281},{"type":46,"tag":250,"props":11175,"children":11176},{"class":252,"line":9284},[11177],{"type":46,"tag":250,"props":11178,"children":11179},{"style":9187},[11180],{"type":52,"value":9290},{"type":46,"tag":250,"props":11182,"children":11183},{"class":252,"line":9293},[11184],{"type":46,"tag":250,"props":11185,"children":11186},{"style":9187},[11187],{"type":52,"value":9299},{"type":46,"tag":250,"props":11189,"children":11190},{"class":252,"line":4121},[11191],{"type":46,"tag":250,"props":11192,"children":11193},{"style":9187},[11194],{"type":52,"value":9307},{"type":46,"tag":250,"props":11196,"children":11197},{"class":252,"line":9310},[11198],{"type":46,"tag":250,"props":11199,"children":11200},{"style":9187},[11201],{"type":52,"value":9316},{"type":46,"tag":250,"props":11203,"children":11204},{"class":252,"line":9319},[11205],{"type":46,"tag":250,"props":11206,"children":11207},{"style":9187},[11208],{"type":52,"value":9281},{"type":46,"tag":250,"props":11210,"children":11211},{"class":252,"line":9327},[11212],{"type":46,"tag":250,"props":11213,"children":11214},{"style":9187},[11215],{"type":52,"value":9290},{"type":46,"tag":250,"props":11217,"children":11218},{"class":252,"line":9335},[11219],{"type":46,"tag":250,"props":11220,"children":11221},{"style":9187},[11222],{"type":52,"value":9341},{"type":46,"tag":250,"props":11224,"children":11225},{"class":252,"line":9344},[11226],{"type":46,"tag":250,"props":11227,"children":11228},{"style":9187},[11229],{"type":52,"value":9350},{"type":46,"tag":250,"props":11231,"children":11232},{"class":252,"line":9353},[11233],{"type":46,"tag":250,"props":11234,"children":11235},{"style":9187},[11236],{"type":52,"value":9359},{"type":46,"tag":250,"props":11238,"children":11239},{"class":252,"line":9362},[11240],{"type":46,"tag":250,"props":11241,"children":11242},{"style":9187},[11243],{"type":52,"value":9368},{"type":46,"tag":250,"props":11245,"children":11246},{"class":252,"line":9371},[11247],{"type":46,"tag":250,"props":11248,"children":11249},{"style":9187},[11250],{"type":52,"value":9377},{"type":46,"tag":250,"props":11252,"children":11253},{"class":252,"line":9380},[11254],{"type":46,"tag":250,"props":11255,"children":11256},{"emptyLinePlaceholder":22},[11257],{"type":52,"value":9386},{"type":46,"tag":250,"props":11259,"children":11260},{"class":252,"line":9389},[11261],{"type":46,"tag":250,"props":11262,"children":11263},{"style":375},[11264],{"type":52,"value":9395},{"type":46,"tag":250,"props":11266,"children":11267},{"class":252,"line":9398},[11268,11272,11276,11280,11284],{"type":46,"tag":250,"props":11269,"children":11270},{"style":274},[11271],{"type":52,"value":9404},{"type":46,"tag":250,"props":11273,"children":11274},{"style":268},[11275],{"type":52,"value":106},{"type":46,"tag":250,"props":11277,"children":11278},{"style":274},[11279],{"type":52,"value":9413},{"type":46,"tag":250,"props":11281,"children":11282},{"style":375},[11283],{"type":52,"value":9418},{"type":46,"tag":250,"props":11285,"children":11286},{"style":268},[11287],{"type":52,"value":9423},{"type":46,"tag":250,"props":11289,"children":11290},{"class":252,"line":9426},[11291,11295,11299,11303],{"type":46,"tag":250,"props":11292,"children":11293},{"style":274},[11294],{"type":52,"value":9404},{"type":46,"tag":250,"props":11296,"children":11297},{"style":268},[11298],{"type":52,"value":106},{"type":46,"tag":250,"props":11300,"children":11301},{"style":274},[11302],{"type":52,"value":9440},{"type":46,"tag":250,"props":11304,"children":11305},{"style":268},[11306],{"type":52,"value":9445},{"type":46,"tag":250,"props":11308,"children":11309},{"class":252,"line":9448},[11310,11314,11318,11322,11326],{"type":46,"tag":250,"props":11311,"children":11312},{"style":274},[11313],{"type":52,"value":9404},{"type":46,"tag":250,"props":11315,"children":11316},{"style":268},[11317],{"type":52,"value":106},{"type":46,"tag":250,"props":11319,"children":11320},{"style":274},[11321],{"type":52,"value":9462},{"type":46,"tag":250,"props":11323,"children":11324},{"style":375},[11325],{"type":52,"value":9418},{"type":46,"tag":250,"props":11327,"children":11328},{"style":268},[11329],{"type":52,"value":9471},{"type":46,"tag":250,"props":11331,"children":11332},{"class":252,"line":9474},[11333,11337,11341,11345,11349],{"type":46,"tag":250,"props":11334,"children":11335},{"style":274},[11336],{"type":52,"value":9404},{"type":46,"tag":250,"props":11338,"children":11339},{"style":268},[11340],{"type":52,"value":106},{"type":46,"tag":250,"props":11342,"children":11343},{"style":274},[11344],{"type":52,"value":9488},{"type":46,"tag":250,"props":11346,"children":11347},{"style":375},[11348],{"type":52,"value":9418},{"type":46,"tag":250,"props":11350,"children":11351},{"style":268},[11352],{"type":52,"value":9497},{"type":46,"tag":250,"props":11354,"children":11355},{"class":252,"line":9500},[11356,11360,11364,11368,11372],{"type":46,"tag":250,"props":11357,"children":11358},{"style":274},[11359],{"type":52,"value":9404},{"type":46,"tag":250,"props":11361,"children":11362},{"style":268},[11363],{"type":52,"value":106},{"type":46,"tag":250,"props":11365,"children":11366},{"style":274},[11367],{"type":52,"value":5157},{"type":46,"tag":250,"props":11369,"children":11370},{"style":375},[11371],{"type":52,"value":9418},{"type":46,"tag":250,"props":11373,"children":11374},{"style":268},[11375],{"type":52,"value":9522},{"type":46,"tag":250,"props":11377,"children":11378},{"class":252,"line":9525},[11379,11383,11387,11391],{"type":46,"tag":250,"props":11380,"children":11381},{"style":274},[11382],{"type":52,"value":9404},{"type":46,"tag":250,"props":11384,"children":11385},{"style":268},[11386],{"type":52,"value":106},{"type":46,"tag":250,"props":11388,"children":11389},{"style":274},[11390],{"type":52,"value":9539},{"type":46,"tag":250,"props":11392,"children":11393},{"style":268},[11394],{"type":52,"value":9445},{"type":46,"tag":250,"props":11396,"children":11397},{"class":252,"line":9546},[11398,11402,11406,11410,11414,11418,11422,11426,11430,11434,11438,11442,11446,11450],{"type":46,"tag":250,"props":11399,"children":11400},{"style":274},[11401],{"type":52,"value":9552},{"type":46,"tag":250,"props":11403,"children":11404},{"style":268},[11405],{"type":52,"value":9557},{"type":46,"tag":250,"props":11407,"children":11408},{"style":274},[11409],{"type":52,"value":9562},{"type":46,"tag":250,"props":11411,"children":11412},{"style":268},[11413],{"type":52,"value":106},{"type":46,"tag":250,"props":11415,"children":11416},{"style":274},[11417],{"type":52,"value":5164},{"type":46,"tag":250,"props":11419,"children":11420},{"style":375},[11421],{"type":52,"value":9418},{"type":46,"tag":250,"props":11423,"children":11424},{"style":375},[11425],{"type":52,"value":9579},{"type":46,"tag":250,"props":11427,"children":11428},{"style":268},[11429],{"type":52,"value":9557},{"type":46,"tag":250,"props":11431,"children":11432},{"style":274},[11433],{"type":52,"value":9588},{"type":46,"tag":250,"props":11435,"children":11436},{"style":268},[11437],{"type":52,"value":9593},{"type":46,"tag":250,"props":11439,"children":11440},{"style":274},[11441],{"type":52,"value":9598},{"type":46,"tag":250,"props":11443,"children":11444},{"style":268},[11445],{"type":52,"value":9603},{"type":46,"tag":250,"props":11447,"children":11448},{"style":375},[11449],{"type":52,"value":9608},{"type":46,"tag":250,"props":11451,"children":11452},{"style":268},[11453],{"type":52,"value":9613},{"type":46,"tag":250,"props":11455,"children":11456},{"class":252,"line":9616},[11457,11461,11465,11469,11473,11477,11481,11485,11489,11493,11497,11501,11505,11509],{"type":46,"tag":250,"props":11458,"children":11459},{"style":274},[11460],{"type":52,"value":9552},{"type":46,"tag":250,"props":11462,"children":11463},{"style":268},[11464],{"type":52,"value":9557},{"type":46,"tag":250,"props":11466,"children":11467},{"style":274},[11468],{"type":52,"value":9562},{"type":46,"tag":250,"props":11470,"children":11471},{"style":268},[11472],{"type":52,"value":106},{"type":46,"tag":250,"props":11474,"children":11475},{"style":274},[11476],{"type":52,"value":9638},{"type":46,"tag":250,"props":11478,"children":11479},{"style":375},[11480],{"type":52,"value":9418},{"type":46,"tag":250,"props":11482,"children":11483},{"style":375},[11484],{"type":52,"value":9579},{"type":46,"tag":250,"props":11486,"children":11487},{"style":268},[11488],{"type":52,"value":9557},{"type":46,"tag":250,"props":11490,"children":11491},{"style":274},[11492],{"type":52,"value":9588},{"type":46,"tag":250,"props":11494,"children":11495},{"style":268},[11496],{"type":52,"value":9593},{"type":46,"tag":250,"props":11498,"children":11499},{"style":274},[11500],{"type":52,"value":9598},{"type":46,"tag":250,"props":11502,"children":11503},{"style":268},[11504],{"type":52,"value":9603},{"type":46,"tag":250,"props":11506,"children":11507},{"style":375},[11508],{"type":52,"value":9608},{"type":46,"tag":250,"props":11510,"children":11511},{"style":268},[11512],{"type":52,"value":9675},{"type":46,"tag":250,"props":11514,"children":11515},{"class":252,"line":9678},[11516,11520,11524,11528,11532,11536,11540,11544,11548,11552,11556,11560,11564,11568],{"type":46,"tag":250,"props":11517,"children":11518},{"style":274},[11519],{"type":52,"value":9552},{"type":46,"tag":250,"props":11521,"children":11522},{"style":268},[11523],{"type":52,"value":9557},{"type":46,"tag":250,"props":11525,"children":11526},{"style":274},[11527],{"type":52,"value":9562},{"type":46,"tag":250,"props":11529,"children":11530},{"style":268},[11531],{"type":52,"value":106},{"type":46,"tag":250,"props":11533,"children":11534},{"style":274},[11535],{"type":52,"value":9700},{"type":46,"tag":250,"props":11537,"children":11538},{"style":375},[11539],{"type":52,"value":9418},{"type":46,"tag":250,"props":11541,"children":11542},{"style":375},[11543],{"type":52,"value":9579},{"type":46,"tag":250,"props":11545,"children":11546},{"style":268},[11547],{"type":52,"value":9557},{"type":46,"tag":250,"props":11549,"children":11550},{"style":274},[11551],{"type":52,"value":9588},{"type":46,"tag":250,"props":11553,"children":11554},{"style":268},[11555],{"type":52,"value":9593},{"type":46,"tag":250,"props":11557,"children":11558},{"style":274},[11559],{"type":52,"value":9598},{"type":46,"tag":250,"props":11561,"children":11562},{"style":268},[11563],{"type":52,"value":9603},{"type":46,"tag":250,"props":11565,"children":11566},{"style":375},[11567],{"type":52,"value":9608},{"type":46,"tag":250,"props":11569,"children":11570},{"style":268},[11571],{"type":52,"value":9737},{"type":46,"tag":250,"props":11573,"children":11574},{"class":252,"line":9740},[11575,11579,11583,11587,11591,11595,11599,11603,11607,11611,11615,11619,11623,11627],{"type":46,"tag":250,"props":11576,"children":11577},{"style":274},[11578],{"type":52,"value":9552},{"type":46,"tag":250,"props":11580,"children":11581},{"style":268},[11582],{"type":52,"value":9557},{"type":46,"tag":250,"props":11584,"children":11585},{"style":274},[11586],{"type":52,"value":9562},{"type":46,"tag":250,"props":11588,"children":11589},{"style":268},[11590],{"type":52,"value":106},{"type":46,"tag":250,"props":11592,"children":11593},{"style":274},[11594],{"type":52,"value":9762},{"type":46,"tag":250,"props":11596,"children":11597},{"style":375},[11598],{"type":52,"value":9418},{"type":46,"tag":250,"props":11600,"children":11601},{"style":375},[11602],{"type":52,"value":9579},{"type":46,"tag":250,"props":11604,"children":11605},{"style":268},[11606],{"type":52,"value":9557},{"type":46,"tag":250,"props":11608,"children":11609},{"style":274},[11610],{"type":52,"value":9588},{"type":46,"tag":250,"props":11612,"children":11613},{"style":268},[11614],{"type":52,"value":9593},{"type":46,"tag":250,"props":11616,"children":11617},{"style":274},[11618],{"type":52,"value":9598},{"type":46,"tag":250,"props":11620,"children":11621},{"style":268},[11622],{"type":52,"value":9603},{"type":46,"tag":250,"props":11624,"children":11625},{"style":375},[11626],{"type":52,"value":9608},{"type":46,"tag":250,"props":11628,"children":11629},{"style":268},[11630],{"type":52,"value":9799},{"type":46,"tag":250,"props":11632,"children":11633},{"class":252,"line":9802},[11634,11638,11642,11646],{"type":46,"tag":250,"props":11635,"children":11636},{"style":274},[11637],{"type":52,"value":9404},{"type":46,"tag":250,"props":11639,"children":11640},{"style":268},[11641],{"type":52,"value":106},{"type":46,"tag":250,"props":11643,"children":11644},{"style":274},[11645],{"type":52,"value":9816},{"type":46,"tag":250,"props":11647,"children":11648},{"style":268},[11649],{"type":52,"value":9445},{"type":46,"tag":250,"props":11651,"children":11652},{"class":252,"line":9823},[11653,11657,11661,11665],{"type":46,"tag":250,"props":11654,"children":11655},{"style":274},[11656],{"type":52,"value":9404},{"type":46,"tag":250,"props":11658,"children":11659},{"style":268},[11660],{"type":52,"value":106},{"type":46,"tag":250,"props":11662,"children":11663},{"style":274},[11664],{"type":52,"value":9837},{"type":46,"tag":250,"props":11666,"children":11667},{"style":268},[11668],{"type":52,"value":9445},{"type":46,"tag":250,"props":11670,"children":11671},{"class":252,"line":9844},[11672,11676,11680,11684],{"type":46,"tag":250,"props":11673,"children":11674},{"style":274},[11675],{"type":52,"value":9404},{"type":46,"tag":250,"props":11677,"children":11678},{"style":268},[11679],{"type":52,"value":106},{"type":46,"tag":250,"props":11681,"children":11682},{"style":274},[11683],{"type":52,"value":9858},{"type":46,"tag":250,"props":11685,"children":11686},{"style":268},[11687],{"type":52,"value":9445},{"type":46,"tag":250,"props":11689,"children":11690},{"class":252,"line":9865},[11691,11695,11699,11703,11707,11711,11715,11719,11723],{"type":46,"tag":250,"props":11692,"children":11693},{"style":274},[11694],{"type":52,"value":9871},{"type":46,"tag":250,"props":11696,"children":11697},{"style":268},[11698],{"type":52,"value":106},{"type":46,"tag":250,"props":11700,"children":11701},{"style":274},[11702],{"type":52,"value":9880},{"type":46,"tag":250,"props":11704,"children":11705},{"style":375},[11706],{"type":52,"value":9885},{"type":46,"tag":250,"props":11708,"children":11709},{"style":274},[11710],{"type":52,"value":9890},{"type":46,"tag":250,"props":11712,"children":11713},{"style":268},[11714],{"type":52,"value":106},{"type":46,"tag":250,"props":11716,"children":11717},{"style":274},[11718],{"type":52,"value":9899},{"type":46,"tag":250,"props":11720,"children":11721},{"style":375},[11722],{"type":52,"value":9418},{"type":46,"tag":250,"props":11724,"children":11725},{"style":268},[11726],{"type":52,"value":9908},{"type":46,"tag":250,"props":11728,"children":11729},{"class":252,"line":9911},[11730,11734,11738,11742,11746],{"type":46,"tag":250,"props":11731,"children":11732},{"style":274},[11733],{"type":52,"value":9871},{"type":46,"tag":250,"props":11735,"children":11736},{"style":268},[11737],{"type":52,"value":106},{"type":46,"tag":250,"props":11739,"children":11740},{"style":274},[11741],{"type":52,"value":9925},{"type":46,"tag":250,"props":11743,"children":11744},{"style":375},[11745],{"type":52,"value":9418},{"type":46,"tag":250,"props":11747,"children":11748},{"style":268},[11749],{"type":52,"value":9934},{"type":46,"tag":250,"props":11751,"children":11752},{"class":252,"line":9937},[11753,11757,11761,11765,11769],{"type":46,"tag":250,"props":11754,"children":11755},{"style":274},[11756],{"type":52,"value":9871},{"type":46,"tag":250,"props":11758,"children":11759},{"style":268},[11760],{"type":52,"value":106},{"type":46,"tag":250,"props":11762,"children":11763},{"style":274},[11764],{"type":52,"value":9951},{"type":46,"tag":250,"props":11766,"children":11767},{"style":375},[11768],{"type":52,"value":9418},{"type":46,"tag":250,"props":11770,"children":11771},{"style":268},[11772],{"type":52,"value":9960},{"type":46,"tag":250,"props":11774,"children":11775},{"class":252,"line":9963},[11776,11780,11784,11788,11792],{"type":46,"tag":250,"props":11777,"children":11778},{"style":375},[11779],{"type":52,"value":9969},{"type":46,"tag":250,"props":11781,"children":11782},{"style":274},[11783],{"type":52,"value":9974},{"type":46,"tag":250,"props":11785,"children":11786},{"style":268},[11787],{"type":52,"value":106},{"type":46,"tag":250,"props":11789,"children":11790},{"style":274},[11791],{"type":52,"value":9983},{"type":46,"tag":250,"props":11793,"children":11794},{"style":268},[11795],{"type":52,"value":9988},{"type":46,"tag":250,"props":11797,"children":11798},{"class":252,"line":9991},[11799,11803,11807,11811,11815],{"type":46,"tag":250,"props":11800,"children":11801},{"style":375},[11802],{"type":52,"value":9077},{"type":46,"tag":250,"props":11804,"children":11805},{"style":274},[11806],{"type":52,"value":9974},{"type":46,"tag":250,"props":11808,"children":11809},{"style":268},[11810],{"type":52,"value":106},{"type":46,"tag":250,"props":11812,"children":11813},{"style":274},[11814],{"type":52,"value":10009},{"type":46,"tag":250,"props":11816,"children":11817},{"style":268},[11818],{"type":52,"value":10014},{"type":46,"tag":250,"props":11820,"children":11821},{"class":252,"line":10017},[11822,11826,11830,11834,11838,11842,11846,11850],{"type":46,"tag":250,"props":11823,"children":11824},{"style":375},[11825],{"type":52,"value":10023},{"type":46,"tag":250,"props":11827,"children":11828},{"style":274},[11829],{"type":52,"value":10028},{"type":46,"tag":250,"props":11831,"children":11832},{"style":268},[11833],{"type":52,"value":106},{"type":46,"tag":250,"props":11835,"children":11836},{"style":274},[11837],{"type":52,"value":9462},{"type":46,"tag":250,"props":11839,"children":11840},{"style":375},[11841],{"type":52,"value":10041},{"type":46,"tag":250,"props":11843,"children":11844},{"style":274},[11845],{"type":52,"value":10046},{"type":46,"tag":250,"props":11847,"children":11848},{"style":268},[11849],{"type":52,"value":106},{"type":46,"tag":250,"props":11851,"children":11852},{"style":274},[11853],{"type":52,"value":10055},{"type":46,"tag":250,"props":11855,"children":11856},{"class":252,"line":10058},[11857,11861,11865,11869,11873,11878,11883,11887,11891,11895,11899,11903],{"type":46,"tag":250,"props":11858,"children":11859},{"style":375},[11860],{"type":52,"value":10064},{"type":46,"tag":250,"props":11862,"children":11863},{"style":274},[11864],{"type":52,"value":10028},{"type":46,"tag":250,"props":11866,"children":11867},{"style":268},[11868],{"type":52,"value":106},{"type":46,"tag":250,"props":11870,"children":11871},{"style":274},[11872],{"type":52,"value":9488},{"type":46,"tag":250,"props":11874,"children":11875},{"style":268},[11876],{"type":52,"value":11877},"::",{"type":46,"tag":250,"props":11879,"children":11880},{"style":375},[11881],{"type":52,"value":11882},"DATE",{"type":46,"tag":250,"props":11884,"children":11885},{"style":375},[11886],{"type":52,"value":10041},{"type":46,"tag":250,"props":11888,"children":11889},{"style":274},[11890],{"type":52,"value":10046},{"type":46,"tag":250,"props":11892,"children":11893},{"style":268},[11894],{"type":52,"value":106},{"type":46,"tag":250,"props":11896,"children":11897},{"style":274},[11898],{"type":52,"value":10109},{"type":46,"tag":250,"props":11900,"children":11901},{"style":268},[11902],{"type":52,"value":11877},{"type":46,"tag":250,"props":11904,"children":11905},{"style":375},[11906],{"type":52,"value":11907},"DATE\n",{"type":46,"tag":55,"props":11909,"children":11910},{},[11911,11913,11918,11920,11926],{"type":52,"value":11912},"The ",{"type":46,"tag":99,"props":11914,"children":11916},{"className":11915},[],[11917],{"type":52,"value":9077},{"type":52,"value":11919}," keeps all Shopify orders even if the Stripe charge hasn't synced yet. The ",{"type":46,"tag":99,"props":11921,"children":11923},{"className":11922},[],[11924],{"type":52,"value":11925},"\u002F 100.0",{"type":52,"value":11927}," converts Stripe's cent-based amounts to dollars.",{"type":46,"tag":220,"props":11929,"children":11931},{"id":11930},"_2-staged-customers-stg_customerssql",[11932,11934],{"type":52,"value":11933},"2) Staged customers - ",{"type":46,"tag":99,"props":11935,"children":11937},{"className":11936},[],[11938],{"type":52,"value":11939},"stg_customers.sql",{"type":46,"tag":55,"props":11941,"children":11942},{},[11943,11945,11951,11952,11958,11959,11965,11966,11972],{"type":52,"value":11944},"A unified customer table that merges Shopify and Stripe profiles. This query uses ",{"type":46,"tag":99,"props":11946,"children":11948},{"className":11947},[],[11949],{"type":52,"value":11950},"COALESCE",{"type":52,"value":151},{"type":46,"tag":99,"props":11953,"children":11955},{"className":11954},[],[11956],{"type":52,"value":11957},"LEAST",{"type":52,"value":151},{"type":46,"tag":99,"props":11960,"children":11962},{"className":11961},[],[11963],{"type":52,"value":11964},"FULL OUTER JOIN",{"type":52,"value":173},{"type":46,"tag":99,"props":11967,"children":11969},{"className":11968},[],[11970],{"type":52,"value":11971},"lower()",{"type":52,"value":11973}," - all of which work the same across warehouses, so there is no warehouse-specific variant needed.",{"type":46,"tag":198,"props":11975,"children":11976},{"type":9065},[11977],{"type":46,"tag":55,"props":11978,"children":11979},{},[11980,11982,11988,11990,11996,11997,12001,12002,12007,12008,12013,12015,12020,12022,12028,12030,12035,12037,12042],{"type":52,"value":11981},"The SQL below joins ",{"type":46,"tag":99,"props":11983,"children":11985},{"className":11984},[],[11986],{"type":52,"value":11987},"raw.shopify_customers",{"type":52,"value":11989}," with ",{"type":46,"tag":99,"props":11991,"children":11993},{"className":11992},[],[11994],{"type":52,"value":11995},"raw.stripe_customers",{"type":52,"value":9095},{"type":46,"tag":80,"props":11998,"children":11999},{},[12000],{"type":52,"value":5146},{"type":52,"value":9101},{"type":46,"tag":99,"props":12003,"children":12005},{"className":12004},[],[12006],{"type":52,"value":11995},{"type":52,"value":9108},{"type":46,"tag":99,"props":12009,"children":12011},{"className":12010},[],[12012],{"type":52,"value":9093},{"type":52,"value":12014}," list, replace the ",{"type":46,"tag":99,"props":12016,"children":12018},{"className":12017},[],[12019],{"type":52,"value":11964},{"type":52,"value":12021}," with a plain ",{"type":46,"tag":99,"props":12023,"children":12025},{"className":12024},[],[12026],{"type":52,"value":12027},"SELECT",{"type":52,"value":12029}," from ",{"type":46,"tag":99,"props":12031,"children":12033},{"className":12032},[],[12034],{"type":52,"value":11987},{"type":52,"value":12036},", and drop the ",{"type":46,"tag":99,"props":12038,"children":12040},{"className":12039},[],[12041],{"type":52,"value":9128},{"type":52,"value":12043}," columns. Ask Claude Code to adjust the query for you if needed.",{"type":46,"tag":55,"props":12045,"children":12046},{},[12047,12048,12057],{"type":52,"value":9155},{"type":46,"tag":80,"props":12049,"children":12050},{},[12051],{"type":46,"tag":99,"props":12052,"children":12054},{"className":12053},[],[12055],{"type":52,"value":12056},"ecommerce\u002Fassets\u002Fstaging\u002Fstg_customers.sql",{"type":52,"value":9166},{"type":46,"tag":240,"props":12059,"children":12061},{"className":9175,"code":12060,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_customers\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.shopify_customers\n  - raw.stripe_customers\ncolumns:\n  - name: customer_email\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nSELECT\n    COALESCE(sc.email, st.email) AS customer_email,\n    sc.id AS shopify_customer_id,\n    st.id AS stripe_customer_id,\n    sc.first_name,\n    sc.last_name,\n    sc.created_at AS shopify_created_at,\n    st.created AS stripe_created_at,\n    LEAST(sc.created_at, st.created) AS first_seen_at,\n    sc.orders_count,\n    CAST(sc.total_spent AS DECIMAL(12,2)) AS shopify_total_spent,\n    sc.tags AS customer_tags,\n    sc.state AS customer_state\nFROM raw.shopify_customers sc\nFULL OUTER JOIN raw.stripe_customers st\n    ON lower(sc.email) = lower(st.email)\nWHERE COALESCE(sc.email, st.email) IS NOT NULL\n",[12062],{"type":46,"tag":99,"props":12063,"children":12064},{"__ignoreMap":7},[12065,12072,12080,12087,12094,12101,12108,12116,12124,12131,12139,12146,12153,12160,12167,12174,12181,12188,12242,12267,12292,12312,12332,12356,12380,12433,12453,12514,12539,12564,12589,12614,12674],{"type":46,"tag":250,"props":12066,"children":12067},{"class":252,"line":23},[12068],{"type":46,"tag":250,"props":12069,"children":12070},{"style":9187},[12071],{"type":52,"value":9190},{"type":46,"tag":250,"props":12073,"children":12074},{"class":252,"line":285},[12075],{"type":46,"tag":250,"props":12076,"children":12077},{"style":9187},[12078],{"type":52,"value":12079},"name: staging.stg_customers\n",{"type":46,"tag":250,"props":12081,"children":12082},{"class":252,"line":299},[12083],{"type":46,"tag":250,"props":12084,"children":12085},{"style":9187},[12086],{"type":52,"value":9206},{"type":46,"tag":250,"props":12088,"children":12089},{"class":252,"line":807},[12090],{"type":46,"tag":250,"props":12091,"children":12092},{"style":9187},[12093],{"type":52,"value":9214},{"type":46,"tag":250,"props":12095,"children":12096},{"class":252,"line":820},[12097],{"type":46,"tag":250,"props":12098,"children":12099},{"style":9187},[12100],{"type":52,"value":9222},{"type":46,"tag":250,"props":12102,"children":12103},{"class":252,"line":844},[12104],{"type":46,"tag":250,"props":12105,"children":12106},{"style":9187},[12107],{"type":52,"value":9230},{"type":46,"tag":250,"props":12109,"children":12110},{"class":252,"line":862},[12111],{"type":46,"tag":250,"props":12112,"children":12113},{"style":9187},[12114],{"type":52,"value":12115},"  - raw.shopify_customers\n",{"type":46,"tag":250,"props":12117,"children":12118},{"class":252,"line":11},[12119],{"type":46,"tag":250,"props":12120,"children":12121},{"style":9187},[12122],{"type":52,"value":12123},"  - raw.stripe_customers\n",{"type":46,"tag":250,"props":12125,"children":12126},{"class":252,"line":4649},[12127],{"type":46,"tag":250,"props":12128,"children":12129},{"style":9187},[12130],{"type":52,"value":9254},{"type":46,"tag":250,"props":12132,"children":12133},{"class":252,"line":9257},[12134],{"type":46,"tag":250,"props":12135,"children":12136},{"style":9187},[12137],{"type":52,"value":12138},"  - name: customer_email\n",{"type":46,"tag":250,"props":12140,"children":12141},{"class":252,"line":9266},[12142],{"type":46,"tag":250,"props":12143,"children":12144},{"style":9187},[12145],{"type":52,"value":9272},{"type":46,"tag":250,"props":12147,"children":12148},{"class":252,"line":9275},[12149],{"type":46,"tag":250,"props":12150,"children":12151},{"style":9187},[12152],{"type":52,"value":9281},{"type":46,"tag":250,"props":12154,"children":12155},{"class":252,"line":9284},[12156],{"type":46,"tag":250,"props":12157,"children":12158},{"style":9187},[12159],{"type":52,"value":9290},{"type":46,"tag":250,"props":12161,"children":12162},{"class":252,"line":9293},[12163],{"type":46,"tag":250,"props":12164,"children":12165},{"style":9187},[12166],{"type":52,"value":9299},{"type":46,"tag":250,"props":12168,"children":12169},{"class":252,"line":4121},[12170],{"type":46,"tag":250,"props":12171,"children":12172},{"style":9187},[12173],{"type":52,"value":9377},{"type":46,"tag":250,"props":12175,"children":12176},{"class":252,"line":9310},[12177],{"type":46,"tag":250,"props":12178,"children":12179},{"emptyLinePlaceholder":22},[12180],{"type":52,"value":9386},{"type":46,"tag":250,"props":12182,"children":12183},{"class":252,"line":9319},[12184],{"type":46,"tag":250,"props":12185,"children":12186},{"style":375},[12187],{"type":52,"value":9395},{"type":46,"tag":250,"props":12189,"children":12190},{"class":252,"line":9327},[12191,12196,12200,12205,12209,12213,12217,12222,12226,12230,12234,12238],{"type":46,"tag":250,"props":12192,"children":12193},{"style":274},[12194],{"type":52,"value":12195},"    COALESCE",{"type":46,"tag":250,"props":12197,"children":12198},{"style":268},[12199],{"type":52,"value":9557},{"type":46,"tag":250,"props":12201,"children":12202},{"style":274},[12203],{"type":52,"value":12204},"sc",{"type":46,"tag":250,"props":12206,"children":12207},{"style":268},[12208],{"type":52,"value":106},{"type":46,"tag":250,"props":12210,"children":12211},{"style":274},[12212],{"type":52,"value":9462},{"type":46,"tag":250,"props":12214,"children":12215},{"style":268},[12216],{"type":52,"value":151},{"type":46,"tag":250,"props":12218,"children":12219},{"style":274},[12220],{"type":52,"value":12221},"st",{"type":46,"tag":250,"props":12223,"children":12224},{"style":268},[12225],{"type":52,"value":106},{"type":46,"tag":250,"props":12227,"children":12228},{"style":274},[12229],{"type":52,"value":9462},{"type":46,"tag":250,"props":12231,"children":12232},{"style":268},[12233],{"type":52,"value":10086},{"type":46,"tag":250,"props":12235,"children":12236},{"style":375},[12237],{"type":52,"value":9608},{"type":46,"tag":250,"props":12239,"children":12240},{"style":268},[12241],{"type":52,"value":9471},{"type":46,"tag":250,"props":12243,"children":12244},{"class":252,"line":9335},[12245,12250,12254,12258,12262],{"type":46,"tag":250,"props":12246,"children":12247},{"style":274},[12248],{"type":52,"value":12249},"    sc",{"type":46,"tag":250,"props":12251,"children":12252},{"style":268},[12253],{"type":52,"value":106},{"type":46,"tag":250,"props":12255,"children":12256},{"style":274},[12257],{"type":52,"value":9413},{"type":46,"tag":250,"props":12259,"children":12260},{"style":375},[12261],{"type":52,"value":9418},{"type":46,"tag":250,"props":12263,"children":12264},{"style":268},[12265],{"type":52,"value":12266}," shopify_customer_id,\n",{"type":46,"tag":250,"props":12268,"children":12269},{"class":252,"line":9344},[12270,12275,12279,12283,12287],{"type":46,"tag":250,"props":12271,"children":12272},{"style":274},[12273],{"type":52,"value":12274},"    st",{"type":46,"tag":250,"props":12276,"children":12277},{"style":268},[12278],{"type":52,"value":106},{"type":46,"tag":250,"props":12280,"children":12281},{"style":274},[12282],{"type":52,"value":9413},{"type":46,"tag":250,"props":12284,"children":12285},{"style":375},[12286],{"type":52,"value":9418},{"type":46,"tag":250,"props":12288,"children":12289},{"style":268},[12290],{"type":52,"value":12291}," stripe_customer_id,\n",{"type":46,"tag":250,"props":12293,"children":12294},{"class":252,"line":9353},[12295,12299,12303,12308],{"type":46,"tag":250,"props":12296,"children":12297},{"style":274},[12298],{"type":52,"value":12249},{"type":46,"tag":250,"props":12300,"children":12301},{"style":268},[12302],{"type":52,"value":106},{"type":46,"tag":250,"props":12304,"children":12305},{"style":274},[12306],{"type":52,"value":12307},"first_name",{"type":46,"tag":250,"props":12309,"children":12310},{"style":268},[12311],{"type":52,"value":9445},{"type":46,"tag":250,"props":12313,"children":12314},{"class":252,"line":9362},[12315,12319,12323,12328],{"type":46,"tag":250,"props":12316,"children":12317},{"style":274},[12318],{"type":52,"value":12249},{"type":46,"tag":250,"props":12320,"children":12321},{"style":268},[12322],{"type":52,"value":106},{"type":46,"tag":250,"props":12324,"children":12325},{"style":274},[12326],{"type":52,"value":12327},"last_name",{"type":46,"tag":250,"props":12329,"children":12330},{"style":268},[12331],{"type":52,"value":9445},{"type":46,"tag":250,"props":12333,"children":12334},{"class":252,"line":9371},[12335,12339,12343,12347,12351],{"type":46,"tag":250,"props":12336,"children":12337},{"style":274},[12338],{"type":52,"value":12249},{"type":46,"tag":250,"props":12340,"children":12341},{"style":268},[12342],{"type":52,"value":106},{"type":46,"tag":250,"props":12344,"children":12345},{"style":274},[12346],{"type":52,"value":9488},{"type":46,"tag":250,"props":12348,"children":12349},{"style":375},[12350],{"type":52,"value":9418},{"type":46,"tag":250,"props":12352,"children":12353},{"style":268},[12354],{"type":52,"value":12355}," shopify_created_at,\n",{"type":46,"tag":250,"props":12357,"children":12358},{"class":252,"line":9380},[12359,12363,12367,12371,12375],{"type":46,"tag":250,"props":12360,"children":12361},{"style":274},[12362],{"type":52,"value":12274},{"type":46,"tag":250,"props":12364,"children":12365},{"style":268},[12366],{"type":52,"value":106},{"type":46,"tag":250,"props":12368,"children":12369},{"style":274},[12370],{"type":52,"value":10109},{"type":46,"tag":250,"props":12372,"children":12373},{"style":375},[12374],{"type":52,"value":9418},{"type":46,"tag":250,"props":12376,"children":12377},{"style":268},[12378],{"type":52,"value":12379}," stripe_created_at,\n",{"type":46,"tag":250,"props":12381,"children":12382},{"class":252,"line":9389},[12383,12388,12392,12396,12400,12404,12408,12412,12416,12420,12424,12428],{"type":46,"tag":250,"props":12384,"children":12385},{"style":274},[12386],{"type":52,"value":12387},"    LEAST",{"type":46,"tag":250,"props":12389,"children":12390},{"style":268},[12391],{"type":52,"value":9557},{"type":46,"tag":250,"props":12393,"children":12394},{"style":274},[12395],{"type":52,"value":12204},{"type":46,"tag":250,"props":12397,"children":12398},{"style":268},[12399],{"type":52,"value":106},{"type":46,"tag":250,"props":12401,"children":12402},{"style":274},[12403],{"type":52,"value":9488},{"type":46,"tag":250,"props":12405,"children":12406},{"style":268},[12407],{"type":52,"value":151},{"type":46,"tag":250,"props":12409,"children":12410},{"style":274},[12411],{"type":52,"value":12221},{"type":46,"tag":250,"props":12413,"children":12414},{"style":268},[12415],{"type":52,"value":106},{"type":46,"tag":250,"props":12417,"children":12418},{"style":274},[12419],{"type":52,"value":10109},{"type":46,"tag":250,"props":12421,"children":12422},{"style":268},[12423],{"type":52,"value":10086},{"type":46,"tag":250,"props":12425,"children":12426},{"style":375},[12427],{"type":52,"value":9608},{"type":46,"tag":250,"props":12429,"children":12430},{"style":268},[12431],{"type":52,"value":12432}," first_seen_at,\n",{"type":46,"tag":250,"props":12434,"children":12435},{"class":252,"line":9398},[12436,12440,12444,12449],{"type":46,"tag":250,"props":12437,"children":12438},{"style":274},[12439],{"type":52,"value":12249},{"type":46,"tag":250,"props":12441,"children":12442},{"style":268},[12443],{"type":52,"value":106},{"type":46,"tag":250,"props":12445,"children":12446},{"style":274},[12447],{"type":52,"value":12448},"orders_count",{"type":46,"tag":250,"props":12450,"children":12451},{"style":268},[12452],{"type":52,"value":9445},{"type":46,"tag":250,"props":12454,"children":12455},{"class":252,"line":9426},[12456,12460,12464,12468,12472,12477,12481,12485,12489,12493,12497,12501,12505,12509],{"type":46,"tag":250,"props":12457,"children":12458},{"style":274},[12459],{"type":52,"value":9552},{"type":46,"tag":250,"props":12461,"children":12462},{"style":268},[12463],{"type":52,"value":9557},{"type":46,"tag":250,"props":12465,"children":12466},{"style":274},[12467],{"type":52,"value":12204},{"type":46,"tag":250,"props":12469,"children":12470},{"style":268},[12471],{"type":52,"value":106},{"type":46,"tag":250,"props":12473,"children":12474},{"style":274},[12475],{"type":52,"value":12476},"total_spent",{"type":46,"tag":250,"props":12478,"children":12479},{"style":375},[12480],{"type":52,"value":9418},{"type":46,"tag":250,"props":12482,"children":12483},{"style":375},[12484],{"type":52,"value":9579},{"type":46,"tag":250,"props":12486,"children":12487},{"style":268},[12488],{"type":52,"value":9557},{"type":46,"tag":250,"props":12490,"children":12491},{"style":274},[12492],{"type":52,"value":9588},{"type":46,"tag":250,"props":12494,"children":12495},{"style":268},[12496],{"type":52,"value":9593},{"type":46,"tag":250,"props":12498,"children":12499},{"style":274},[12500],{"type":52,"value":9598},{"type":46,"tag":250,"props":12502,"children":12503},{"style":268},[12504],{"type":52,"value":9603},{"type":46,"tag":250,"props":12506,"children":12507},{"style":375},[12508],{"type":52,"value":9608},{"type":46,"tag":250,"props":12510,"children":12511},{"style":268},[12512],{"type":52,"value":12513}," shopify_total_spent,\n",{"type":46,"tag":250,"props":12515,"children":12516},{"class":252,"line":9448},[12517,12521,12525,12530,12534],{"type":46,"tag":250,"props":12518,"children":12519},{"style":274},[12520],{"type":52,"value":12249},{"type":46,"tag":250,"props":12522,"children":12523},{"style":268},[12524],{"type":52,"value":106},{"type":46,"tag":250,"props":12526,"children":12527},{"style":274},[12528],{"type":52,"value":12529},"tags",{"type":46,"tag":250,"props":12531,"children":12532},{"style":375},[12533],{"type":52,"value":9418},{"type":46,"tag":250,"props":12535,"children":12536},{"style":268},[12537],{"type":52,"value":12538}," customer_tags,\n",{"type":46,"tag":250,"props":12540,"children":12541},{"class":252,"line":9474},[12542,12546,12550,12555,12559],{"type":46,"tag":250,"props":12543,"children":12544},{"style":274},[12545],{"type":52,"value":12249},{"type":46,"tag":250,"props":12547,"children":12548},{"style":268},[12549],{"type":52,"value":106},{"type":46,"tag":250,"props":12551,"children":12552},{"style":274},[12553],{"type":52,"value":12554},"state",{"type":46,"tag":250,"props":12556,"children":12557},{"style":375},[12558],{"type":52,"value":9418},{"type":46,"tag":250,"props":12560,"children":12561},{"style":268},[12562],{"type":52,"value":12563}," customer_state\n",{"type":46,"tag":250,"props":12565,"children":12566},{"class":252,"line":9500},[12567,12571,12575,12579,12584],{"type":46,"tag":250,"props":12568,"children":12569},{"style":375},[12570],{"type":52,"value":9969},{"type":46,"tag":250,"props":12572,"children":12573},{"style":274},[12574],{"type":52,"value":9974},{"type":46,"tag":250,"props":12576,"children":12577},{"style":268},[12578],{"type":52,"value":106},{"type":46,"tag":250,"props":12580,"children":12581},{"style":274},[12582],{"type":52,"value":12583},"shopify_customers",{"type":46,"tag":250,"props":12585,"children":12586},{"style":268},[12587],{"type":52,"value":12588}," sc\n",{"type":46,"tag":250,"props":12590,"children":12591},{"class":252,"line":9525},[12592,12596,12600,12604,12609],{"type":46,"tag":250,"props":12593,"children":12594},{"style":375},[12595],{"type":52,"value":11964},{"type":46,"tag":250,"props":12597,"children":12598},{"style":274},[12599],{"type":52,"value":9974},{"type":46,"tag":250,"props":12601,"children":12602},{"style":268},[12603],{"type":52,"value":106},{"type":46,"tag":250,"props":12605,"children":12606},{"style":274},[12607],{"type":52,"value":12608},"stripe_customers",{"type":46,"tag":250,"props":12610,"children":12611},{"style":268},[12612],{"type":52,"value":12613}," st\n",{"type":46,"tag":250,"props":12615,"children":12616},{"class":252,"line":9546},[12617,12621,12626,12630,12634,12638,12642,12646,12650,12654,12658,12662,12666,12670],{"type":46,"tag":250,"props":12618,"children":12619},{"style":375},[12620],{"type":52,"value":10023},{"type":46,"tag":250,"props":12622,"children":12623},{"style":274},[12624],{"type":52,"value":12625}," lower",{"type":46,"tag":250,"props":12627,"children":12628},{"style":268},[12629],{"type":52,"value":9557},{"type":46,"tag":250,"props":12631,"children":12632},{"style":274},[12633],{"type":52,"value":12204},{"type":46,"tag":250,"props":12635,"children":12636},{"style":268},[12637],{"type":52,"value":106},{"type":46,"tag":250,"props":12639,"children":12640},{"style":274},[12641],{"type":52,"value":9462},{"type":46,"tag":250,"props":12643,"children":12644},{"style":268},[12645],{"type":52,"value":10086},{"type":46,"tag":250,"props":12647,"children":12648},{"style":375},[12649],{"type":52,"value":10091},{"type":46,"tag":250,"props":12651,"children":12652},{"style":274},[12653],{"type":52,"value":12625},{"type":46,"tag":250,"props":12655,"children":12656},{"style":268},[12657],{"type":52,"value":9557},{"type":46,"tag":250,"props":12659,"children":12660},{"style":274},[12661],{"type":52,"value":12221},{"type":46,"tag":250,"props":12663,"children":12664},{"style":268},[12665],{"type":52,"value":106},{"type":46,"tag":250,"props":12667,"children":12668},{"style":274},[12669],{"type":52,"value":9462},{"type":46,"tag":250,"props":12671,"children":12672},{"style":268},[12673],{"type":52,"value":10114},{"type":46,"tag":250,"props":12675,"children":12676},{"class":252,"line":9616},[12677,12681,12686,12690,12694,12698,12702,12706,12710,12714,12718,12722],{"type":46,"tag":250,"props":12678,"children":12679},{"style":375},[12680],{"type":52,"value":10942},{"type":46,"tag":250,"props":12682,"children":12683},{"style":274},[12684],{"type":52,"value":12685}," COALESCE",{"type":46,"tag":250,"props":12687,"children":12688},{"style":268},[12689],{"type":52,"value":9557},{"type":46,"tag":250,"props":12691,"children":12692},{"style":274},[12693],{"type":52,"value":12204},{"type":46,"tag":250,"props":12695,"children":12696},{"style":268},[12697],{"type":52,"value":106},{"type":46,"tag":250,"props":12699,"children":12700},{"style":274},[12701],{"type":52,"value":9462},{"type":46,"tag":250,"props":12703,"children":12704},{"style":268},[12705],{"type":52,"value":151},{"type":46,"tag":250,"props":12707,"children":12708},{"style":274},[12709],{"type":52,"value":12221},{"type":46,"tag":250,"props":12711,"children":12712},{"style":268},[12713],{"type":52,"value":106},{"type":46,"tag":250,"props":12715,"children":12716},{"style":274},[12717],{"type":52,"value":9462},{"type":46,"tag":250,"props":12719,"children":12720},{"style":268},[12721],{"type":52,"value":10086},{"type":46,"tag":250,"props":12723,"children":12724},{"style":375},[12725],{"type":52,"value":12726},"IS NOT NULL\n",{"type":46,"tag":55,"props":12728,"children":12729},{},[12730,12731,12736,12738,12743],{"type":52,"value":11912},{"type":46,"tag":99,"props":12732,"children":12734},{"className":12733},[],[12735],{"type":52,"value":11964},{"type":52,"value":12737}," catches customers who only exist in one system. ",{"type":46,"tag":99,"props":12739,"children":12741},{"className":12740},[],[12742],{"type":52,"value":11950},{"type":52,"value":12744}," gives priority to Shopify's email since it's the primary ecommerce platform.",{"type":46,"tag":220,"props":12746,"children":12748},{"id":12747},"_3-staged-products-stg_productssql",[12749,12751],{"type":52,"value":12750},"3) Staged products - ",{"type":46,"tag":99,"props":12752,"children":12754},{"className":12753},[],[12755],{"type":52,"value":12756},"stg_products.sql",{"type":46,"tag":55,"props":12758,"children":12759},{},[12760,12762,12768,12769,12774],{"type":52,"value":12761},"A clean product catalog. This query uses only standard SQL (",{"type":46,"tag":99,"props":12763,"children":12765},{"className":12764},[],[12766],{"type":52,"value":12767},"CAST",{"type":52,"value":151},{"type":46,"tag":99,"props":12770,"children":12772},{"className":12771},[],[12773],{"type":52,"value":10942},{"type":52,"value":12775},"), so it works identically on every warehouse.",{"type":46,"tag":198,"props":12777,"children":12779},{"type":12778},"info",[12780],{"type":46,"tag":55,"props":12781,"children":12782},{},[12783,12785,12790,12792,12797,12799,12804],{"type":52,"value":12784},"Shopify product IDs are in GID format (e.g. ",{"type":46,"tag":99,"props":12786,"children":12788},{"className":12787},[],[12789],{"type":52,"value":9004},{"type":52,"value":12791},"). Depending on how your Shopify data lands in the warehouse, the raw ",{"type":46,"tag":99,"props":12793,"children":12795},{"className":12794},[],[12796],{"type":52,"value":9413},{"type":52,"value":12798}," column may need parsing with ",{"type":46,"tag":99,"props":12800,"children":12802},{"className":12801},[],[12803],{"type":52,"value":9012},{"type":52,"value":12805}," to extract the numeric ID.",{"type":46,"tag":55,"props":12807,"children":12808},{},[12809,12810,12819],{"type":52,"value":9155},{"type":46,"tag":80,"props":12811,"children":12812},{},[12813],{"type":46,"tag":99,"props":12814,"children":12816},{"className":12815},[],[12817],{"type":52,"value":12818},"ecommerce\u002Fassets\u002Fstaging\u002Fstg_products.sql",{"type":52,"value":9166},{"type":46,"tag":240,"props":12821,"children":12823},{"className":9175,"code":12822,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_products\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.shopify_products\ncolumns:\n  - name: product_id\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nSELECT\n    id AS product_id,\n    title AS product_name,\n    product_type AS category,\n    vendor,\n    status AS product_status,\n    CAST(price AS DECIMAL(12,2)) AS price,  -- column name depends on how your Shopify data is structured; ask Claude Code to check raw.shopify_products\n    tags,\n    created_at,\n    updated_at\nFROM raw.shopify_products\nWHERE status = 'active'\n",[12824],{"type":46,"tag":99,"props":12825,"children":12826},{"__ignoreMap":7},[12827,12834,12842,12849,12856,12863,12870,12878,12885,12893,12900,12907,12914,12921,12928,12935,12942,12959,12976,12993,13001,13018,13072,13080,13088,13096,13116],{"type":46,"tag":250,"props":12828,"children":12829},{"class":252,"line":23},[12830],{"type":46,"tag":250,"props":12831,"children":12832},{"style":9187},[12833],{"type":52,"value":9190},{"type":46,"tag":250,"props":12835,"children":12836},{"class":252,"line":285},[12837],{"type":46,"tag":250,"props":12838,"children":12839},{"style":9187},[12840],{"type":52,"value":12841},"name: staging.stg_products\n",{"type":46,"tag":250,"props":12843,"children":12844},{"class":252,"line":299},[12845],{"type":46,"tag":250,"props":12846,"children":12847},{"style":9187},[12848],{"type":52,"value":9206},{"type":46,"tag":250,"props":12850,"children":12851},{"class":252,"line":807},[12852],{"type":46,"tag":250,"props":12853,"children":12854},{"style":9187},[12855],{"type":52,"value":9214},{"type":46,"tag":250,"props":12857,"children":12858},{"class":252,"line":820},[12859],{"type":46,"tag":250,"props":12860,"children":12861},{"style":9187},[12862],{"type":52,"value":9222},{"type":46,"tag":250,"props":12864,"children":12865},{"class":252,"line":844},[12866],{"type":46,"tag":250,"props":12867,"children":12868},{"style":9187},[12869],{"type":52,"value":9230},{"type":46,"tag":250,"props":12871,"children":12872},{"class":252,"line":862},[12873],{"type":46,"tag":250,"props":12874,"children":12875},{"style":9187},[12876],{"type":52,"value":12877},"  - raw.shopify_products\n",{"type":46,"tag":250,"props":12879,"children":12880},{"class":252,"line":11},[12881],{"type":46,"tag":250,"props":12882,"children":12883},{"style":9187},[12884],{"type":52,"value":9254},{"type":46,"tag":250,"props":12886,"children":12887},{"class":252,"line":4649},[12888],{"type":46,"tag":250,"props":12889,"children":12890},{"style":9187},[12891],{"type":52,"value":12892},"  - name: product_id\n",{"type":46,"tag":250,"props":12894,"children":12895},{"class":252,"line":9257},[12896],{"type":46,"tag":250,"props":12897,"children":12898},{"style":9187},[12899],{"type":52,"value":9272},{"type":46,"tag":250,"props":12901,"children":12902},{"class":252,"line":9266},[12903],{"type":46,"tag":250,"props":12904,"children":12905},{"style":9187},[12906],{"type":52,"value":9281},{"type":46,"tag":250,"props":12908,"children":12909},{"class":252,"line":9275},[12910],{"type":46,"tag":250,"props":12911,"children":12912},{"style":9187},[12913],{"type":52,"value":9290},{"type":46,"tag":250,"props":12915,"children":12916},{"class":252,"line":9284},[12917],{"type":46,"tag":250,"props":12918,"children":12919},{"style":9187},[12920],{"type":52,"value":9299},{"type":46,"tag":250,"props":12922,"children":12923},{"class":252,"line":9293},[12924],{"type":46,"tag":250,"props":12925,"children":12926},{"style":9187},[12927],{"type":52,"value":9377},{"type":46,"tag":250,"props":12929,"children":12930},{"class":252,"line":4121},[12931],{"type":46,"tag":250,"props":12932,"children":12933},{"emptyLinePlaceholder":22},[12934],{"type":52,"value":9386},{"type":46,"tag":250,"props":12936,"children":12937},{"class":252,"line":9310},[12938],{"type":46,"tag":250,"props":12939,"children":12940},{"style":375},[12941],{"type":52,"value":9395},{"type":46,"tag":250,"props":12943,"children":12944},{"class":252,"line":9319},[12945,12950,12954],{"type":46,"tag":250,"props":12946,"children":12947},{"style":268},[12948],{"type":52,"value":12949},"    id ",{"type":46,"tag":250,"props":12951,"children":12952},{"style":375},[12953],{"type":52,"value":9608},{"type":46,"tag":250,"props":12955,"children":12956},{"style":268},[12957],{"type":52,"value":12958}," product_id,\n",{"type":46,"tag":250,"props":12960,"children":12961},{"class":252,"line":9327},[12962,12967,12971],{"type":46,"tag":250,"props":12963,"children":12964},{"style":268},[12965],{"type":52,"value":12966},"    title ",{"type":46,"tag":250,"props":12968,"children":12969},{"style":375},[12970],{"type":52,"value":9608},{"type":46,"tag":250,"props":12972,"children":12973},{"style":268},[12974],{"type":52,"value":12975}," product_name,\n",{"type":46,"tag":250,"props":12977,"children":12978},{"class":252,"line":9335},[12979,12984,12988],{"type":46,"tag":250,"props":12980,"children":12981},{"style":268},[12982],{"type":52,"value":12983},"    product_type ",{"type":46,"tag":250,"props":12985,"children":12986},{"style":375},[12987],{"type":52,"value":9608},{"type":46,"tag":250,"props":12989,"children":12990},{"style":268},[12991],{"type":52,"value":12992}," category,\n",{"type":46,"tag":250,"props":12994,"children":12995},{"class":252,"line":9344},[12996],{"type":46,"tag":250,"props":12997,"children":12998},{"style":268},[12999],{"type":52,"value":13000},"    vendor,\n",{"type":46,"tag":250,"props":13002,"children":13003},{"class":252,"line":9353},[13004,13009,13013],{"type":46,"tag":250,"props":13005,"children":13006},{"style":375},[13007],{"type":52,"value":13008},"    status",{"type":46,"tag":250,"props":13010,"children":13011},{"style":375},[13012],{"type":52,"value":9418},{"type":46,"tag":250,"props":13014,"children":13015},{"style":268},[13016],{"type":52,"value":13017}," product_status,\n",{"type":46,"tag":250,"props":13019,"children":13020},{"class":252,"line":9362},[13021,13025,13030,13034,13038,13042,13046,13050,13054,13058,13062,13067],{"type":46,"tag":250,"props":13022,"children":13023},{"style":274},[13024],{"type":52,"value":9552},{"type":46,"tag":250,"props":13026,"children":13027},{"style":268},[13028],{"type":52,"value":13029},"(price ",{"type":46,"tag":250,"props":13031,"children":13032},{"style":375},[13033],{"type":52,"value":9608},{"type":46,"tag":250,"props":13035,"children":13036},{"style":375},[13037],{"type":52,"value":9579},{"type":46,"tag":250,"props":13039,"children":13040},{"style":268},[13041],{"type":52,"value":9557},{"type":46,"tag":250,"props":13043,"children":13044},{"style":274},[13045],{"type":52,"value":9588},{"type":46,"tag":250,"props":13047,"children":13048},{"style":268},[13049],{"type":52,"value":9593},{"type":46,"tag":250,"props":13051,"children":13052},{"style":274},[13053],{"type":52,"value":9598},{"type":46,"tag":250,"props":13055,"children":13056},{"style":268},[13057],{"type":52,"value":9603},{"type":46,"tag":250,"props":13059,"children":13060},{"style":375},[13061],{"type":52,"value":9608},{"type":46,"tag":250,"props":13063,"children":13064},{"style":268},[13065],{"type":52,"value":13066}," price,  ",{"type":46,"tag":250,"props":13068,"children":13069},{"style":9187},[13070],{"type":52,"value":13071},"-- column name depends on how your Shopify data is structured; ask Claude Code to check raw.shopify_products\n",{"type":46,"tag":250,"props":13073,"children":13074},{"class":252,"line":9371},[13075],{"type":46,"tag":250,"props":13076,"children":13077},{"style":268},[13078],{"type":52,"value":13079},"    tags,\n",{"type":46,"tag":250,"props":13081,"children":13082},{"class":252,"line":9380},[13083],{"type":46,"tag":250,"props":13084,"children":13085},{"style":268},[13086],{"type":52,"value":13087},"    created_at,\n",{"type":46,"tag":250,"props":13089,"children":13090},{"class":252,"line":9389},[13091],{"type":46,"tag":250,"props":13092,"children":13093},{"style":268},[13094],{"type":52,"value":13095},"    updated_at\n",{"type":46,"tag":250,"props":13097,"children":13098},{"class":252,"line":9398},[13099,13103,13107,13111],{"type":46,"tag":250,"props":13100,"children":13101},{"style":375},[13102],{"type":52,"value":9969},{"type":46,"tag":250,"props":13104,"children":13105},{"style":274},[13106],{"type":52,"value":9974},{"type":46,"tag":250,"props":13108,"children":13109},{"style":268},[13110],{"type":52,"value":106},{"type":46,"tag":250,"props":13112,"children":13113},{"style":274},[13114],{"type":52,"value":13115},"shopify_products\n",{"type":46,"tag":250,"props":13117,"children":13118},{"class":252,"line":9426},[13119,13123,13128,13132],{"type":46,"tag":250,"props":13120,"children":13121},{"style":375},[13122],{"type":52,"value":10942},{"type":46,"tag":250,"props":13124,"children":13125},{"style":375},[13126],{"type":52,"value":13127}," status",{"type":46,"tag":250,"props":13129,"children":13130},{"style":375},[13131],{"type":52,"value":10041},{"type":46,"tag":250,"props":13133,"children":13134},{"style":262},[13135],{"type":52,"value":13136}," 'active'\n",{"type":46,"tag":220,"props":13138,"children":13140},{"id":13139},"_4-staged-marketing-spend-stg_marketing_spendsql",[13141,13143],{"type":52,"value":13142},"4) Staged marketing spend - ",{"type":46,"tag":99,"props":13144,"children":13146},{"className":13145},[],[13147],{"type":52,"value":13148},"stg_marketing_spend.sql",{"type":46,"tag":55,"props":13150,"children":13151},{},[13152],{"type":52,"value":13153},"A unified marketing performance table that combines your ad platform and email marketing data into a common format. This query varies by warehouse (date functions), by marketing tool (email side), and by ads platform (ads side).",{"type":46,"tag":55,"props":13155,"children":13156},{},[13157,13158,13167],{"type":52,"value":9155},{"type":46,"tag":80,"props":13159,"children":13160},{},[13161],{"type":46,"tag":99,"props":13162,"children":13164},{"className":13163},[],[13165],{"type":52,"value":13166},"ecommerce\u002Fassets\u002Fstaging\u002Fstg_marketing_spend.sql",{"type":52,"value":9166},{"type":46,"tag":55,"props":13169,"children":13170},{},[13171,13173,13179,13181,13187,13188,13194],{"type":52,"value":13172},"The ads portion of this query depends on which ad platform you connected in Step 2. Each platform uses its own table name and date column, so select the tab that matches your ad platform. The date casting also differs by warehouse - adjust the ",{"type":46,"tag":99,"props":13174,"children":13176},{"className":13175},[],[13177],{"type":52,"value":13178},"toDate()",{"type":52,"value":13180}," \u002F ",{"type":46,"tag":99,"props":13182,"children":13184},{"className":13183},[],[13185],{"type":52,"value":13186},"DATE()",{"type":52,"value":13180},{"type":46,"tag":99,"props":13189,"children":13191},{"className":13190},[],[13192],{"type":52,"value":13193},"::DATE",{"type":52,"value":13195}," wrapper to match yours (see the warehouse tabs in the web sessions section below for examples).",{"type":46,"tag":4472,"props":13197,"children":13199},{"id":13198},"ads-portion",[13200],{"type":52,"value":13201},"Ads portion",{"type":46,"tag":423,"props":13203,"children":13204},{":variants":6739,"group":6740},[13205,13553,13892],{"type":46,"tag":429,"props":13206,"children":13207},{"v-slot:facebook-ads":7},[13208],{"type":46,"tag":240,"props":13209,"children":13211},{"className":9175,"code":13210,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_marketing_spend\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.facebook_ad_insights\ncolumns:\n  - name: spend_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\n-- Facebook Ads spend\nSELECT\n    DATE(date_start) AS spend_date,       -- use toDate() for ClickHouse, ::DATE for Snowflake\n    'paid_ads' AS channel,\n    campaign_name,\n    CAST(spend AS DECIMAL(12,2)) AS spend,\n    CAST(impressions AS INTEGER) AS impressions,\n    CAST(clicks AS INTEGER) AS clicks,\n    CAST(conversions AS INTEGER) AS conversions\nFROM raw.facebook_ad_insights\n",[13212],{"type":46,"tag":99,"props":13213,"children":13214},{"__ignoreMap":7},[13215,13222,13230,13237,13244,13251,13258,13266,13273,13281,13289,13296,13303,13310,13317,13325,13332,13359,13376,13384,13433,13467,13500,13533],{"type":46,"tag":250,"props":13216,"children":13217},{"class":252,"line":23},[13218],{"type":46,"tag":250,"props":13219,"children":13220},{"style":9187},[13221],{"type":52,"value":9190},{"type":46,"tag":250,"props":13223,"children":13224},{"class":252,"line":285},[13225],{"type":46,"tag":250,"props":13226,"children":13227},{"style":9187},[13228],{"type":52,"value":13229},"name: staging.stg_marketing_spend\n",{"type":46,"tag":250,"props":13231,"children":13232},{"class":252,"line":299},[13233],{"type":46,"tag":250,"props":13234,"children":13235},{"style":9187},[13236],{"type":52,"value":9206},{"type":46,"tag":250,"props":13238,"children":13239},{"class":252,"line":807},[13240],{"type":46,"tag":250,"props":13241,"children":13242},{"style":9187},[13243],{"type":52,"value":9214},{"type":46,"tag":250,"props":13245,"children":13246},{"class":252,"line":820},[13247],{"type":46,"tag":250,"props":13248,"children":13249},{"style":9187},[13250],{"type":52,"value":9222},{"type":46,"tag":250,"props":13252,"children":13253},{"class":252,"line":844},[13254],{"type":46,"tag":250,"props":13255,"children":13256},{"style":9187},[13257],{"type":52,"value":9230},{"type":46,"tag":250,"props":13259,"children":13260},{"class":252,"line":862},[13261],{"type":46,"tag":250,"props":13262,"children":13263},{"style":9187},[13264],{"type":52,"value":13265},"  - raw.facebook_ad_insights\n",{"type":46,"tag":250,"props":13267,"children":13268},{"class":252,"line":11},[13269],{"type":46,"tag":250,"props":13270,"children":13271},{"style":9187},[13272],{"type":52,"value":9254},{"type":46,"tag":250,"props":13274,"children":13275},{"class":252,"line":4649},[13276],{"type":46,"tag":250,"props":13277,"children":13278},{"style":9187},[13279],{"type":52,"value":13280},"  - name: spend_date\n",{"type":46,"tag":250,"props":13282,"children":13283},{"class":252,"line":9257},[13284],{"type":46,"tag":250,"props":13285,"children":13286},{"style":9187},[13287],{"type":52,"value":13288},"    type: date\n",{"type":46,"tag":250,"props":13290,"children":13291},{"class":252,"line":9266},[13292],{"type":46,"tag":250,"props":13293,"children":13294},{"style":9187},[13295],{"type":52,"value":9281},{"type":46,"tag":250,"props":13297,"children":13298},{"class":252,"line":9275},[13299],{"type":46,"tag":250,"props":13300,"children":13301},{"style":9187},[13302],{"type":52,"value":9290},{"type":46,"tag":250,"props":13304,"children":13305},{"class":252,"line":9284},[13306],{"type":46,"tag":250,"props":13307,"children":13308},{"style":9187},[13309],{"type":52,"value":9377},{"type":46,"tag":250,"props":13311,"children":13312},{"class":252,"line":9293},[13313],{"type":46,"tag":250,"props":13314,"children":13315},{"emptyLinePlaceholder":22},[13316],{"type":52,"value":9386},{"type":46,"tag":250,"props":13318,"children":13319},{"class":252,"line":4121},[13320],{"type":46,"tag":250,"props":13321,"children":13322},{"style":9187},[13323],{"type":52,"value":13324},"-- Facebook Ads spend\n",{"type":46,"tag":250,"props":13326,"children":13327},{"class":252,"line":9310},[13328],{"type":46,"tag":250,"props":13329,"children":13330},{"style":375},[13331],{"type":52,"value":9395},{"type":46,"tag":250,"props":13333,"children":13334},{"class":252,"line":9319},[13335,13340,13345,13349,13354],{"type":46,"tag":250,"props":13336,"children":13337},{"style":375},[13338],{"type":52,"value":13339},"    DATE",{"type":46,"tag":250,"props":13341,"children":13342},{"style":268},[13343],{"type":52,"value":13344},"(date_start) ",{"type":46,"tag":250,"props":13346,"children":13347},{"style":375},[13348],{"type":52,"value":9608},{"type":46,"tag":250,"props":13350,"children":13351},{"style":268},[13352],{"type":52,"value":13353}," spend_date,       ",{"type":46,"tag":250,"props":13355,"children":13356},{"style":9187},[13357],{"type":52,"value":13358},"-- use toDate() for ClickHouse, ::DATE for Snowflake\n",{"type":46,"tag":250,"props":13360,"children":13361},{"class":252,"line":9327},[13362,13367,13371],{"type":46,"tag":250,"props":13363,"children":13364},{"style":262},[13365],{"type":52,"value":13366},"    'paid_ads'",{"type":46,"tag":250,"props":13368,"children":13369},{"style":375},[13370],{"type":52,"value":9418},{"type":46,"tag":250,"props":13372,"children":13373},{"style":268},[13374],{"type":52,"value":13375}," channel,\n",{"type":46,"tag":250,"props":13377,"children":13378},{"class":252,"line":9335},[13379],{"type":46,"tag":250,"props":13380,"children":13381},{"style":268},[13382],{"type":52,"value":13383},"    campaign_name,\n",{"type":46,"tag":250,"props":13385,"children":13386},{"class":252,"line":9344},[13387,13391,13396,13400,13404,13408,13412,13416,13420,13424,13428],{"type":46,"tag":250,"props":13388,"children":13389},{"style":274},[13390],{"type":52,"value":9552},{"type":46,"tag":250,"props":13392,"children":13393},{"style":268},[13394],{"type":52,"value":13395},"(spend ",{"type":46,"tag":250,"props":13397,"children":13398},{"style":375},[13399],{"type":52,"value":9608},{"type":46,"tag":250,"props":13401,"children":13402},{"style":375},[13403],{"type":52,"value":9579},{"type":46,"tag":250,"props":13405,"children":13406},{"style":268},[13407],{"type":52,"value":9557},{"type":46,"tag":250,"props":13409,"children":13410},{"style":274},[13411],{"type":52,"value":9588},{"type":46,"tag":250,"props":13413,"children":13414},{"style":268},[13415],{"type":52,"value":9593},{"type":46,"tag":250,"props":13417,"children":13418},{"style":274},[13419],{"type":52,"value":9598},{"type":46,"tag":250,"props":13421,"children":13422},{"style":268},[13423],{"type":52,"value":9603},{"type":46,"tag":250,"props":13425,"children":13426},{"style":375},[13427],{"type":52,"value":9608},{"type":46,"tag":250,"props":13429,"children":13430},{"style":268},[13431],{"type":52,"value":13432}," spend,\n",{"type":46,"tag":250,"props":13434,"children":13435},{"class":252,"line":9353},[13436,13440,13445,13449,13454,13458,13462],{"type":46,"tag":250,"props":13437,"children":13438},{"style":274},[13439],{"type":52,"value":9552},{"type":46,"tag":250,"props":13441,"children":13442},{"style":268},[13443],{"type":52,"value":13444},"(impressions ",{"type":46,"tag":250,"props":13446,"children":13447},{"style":375},[13448],{"type":52,"value":9608},{"type":46,"tag":250,"props":13450,"children":13451},{"style":375},[13452],{"type":52,"value":13453}," INTEGER",{"type":46,"tag":250,"props":13455,"children":13456},{"style":268},[13457],{"type":52,"value":10086},{"type":46,"tag":250,"props":13459,"children":13460},{"style":375},[13461],{"type":52,"value":9608},{"type":46,"tag":250,"props":13463,"children":13464},{"style":268},[13465],{"type":52,"value":13466}," impressions,\n",{"type":46,"tag":250,"props":13468,"children":13469},{"class":252,"line":9362},[13470,13474,13479,13483,13487,13491,13495],{"type":46,"tag":250,"props":13471,"children":13472},{"style":274},[13473],{"type":52,"value":9552},{"type":46,"tag":250,"props":13475,"children":13476},{"style":268},[13477],{"type":52,"value":13478},"(clicks ",{"type":46,"tag":250,"props":13480,"children":13481},{"style":375},[13482],{"type":52,"value":9608},{"type":46,"tag":250,"props":13484,"children":13485},{"style":375},[13486],{"type":52,"value":13453},{"type":46,"tag":250,"props":13488,"children":13489},{"style":268},[13490],{"type":52,"value":10086},{"type":46,"tag":250,"props":13492,"children":13493},{"style":375},[13494],{"type":52,"value":9608},{"type":46,"tag":250,"props":13496,"children":13497},{"style":268},[13498],{"type":52,"value":13499}," clicks,\n",{"type":46,"tag":250,"props":13501,"children":13502},{"class":252,"line":9371},[13503,13507,13512,13516,13520,13524,13528],{"type":46,"tag":250,"props":13504,"children":13505},{"style":274},[13506],{"type":52,"value":9552},{"type":46,"tag":250,"props":13508,"children":13509},{"style":268},[13510],{"type":52,"value":13511},"(conversions ",{"type":46,"tag":250,"props":13513,"children":13514},{"style":375},[13515],{"type":52,"value":9608},{"type":46,"tag":250,"props":13517,"children":13518},{"style":375},[13519],{"type":52,"value":13453},{"type":46,"tag":250,"props":13521,"children":13522},{"style":268},[13523],{"type":52,"value":10086},{"type":46,"tag":250,"props":13525,"children":13526},{"style":375},[13527],{"type":52,"value":9608},{"type":46,"tag":250,"props":13529,"children":13530},{"style":268},[13531],{"type":52,"value":13532}," conversions\n",{"type":46,"tag":250,"props":13534,"children":13535},{"class":252,"line":9380},[13536,13540,13544,13548],{"type":46,"tag":250,"props":13537,"children":13538},{"style":375},[13539],{"type":52,"value":9969},{"type":46,"tag":250,"props":13541,"children":13542},{"style":274},[13543],{"type":52,"value":9974},{"type":46,"tag":250,"props":13545,"children":13546},{"style":268},[13547],{"type":52,"value":106},{"type":46,"tag":250,"props":13549,"children":13550},{"style":274},[13551],{"type":52,"value":13552},"facebook_ad_insights\n",{"type":46,"tag":429,"props":13554,"children":13555},{"v-slot:google-ads":7},[13556],{"type":46,"tag":240,"props":13557,"children":13559},{"className":9175,"code":13558,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_marketing_spend\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.google_ad_insights\ncolumns:\n  - name: spend_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\n-- Google Ads spend\nSELECT\n    DATE(date) AS spend_date,             -- use toDate() for ClickHouse, ::DATE for Snowflake\n    'paid_ads' AS channel,\n    campaign_name,\n    CAST(spend AS DECIMAL(12,2)) AS spend,\n    CAST(impressions AS INTEGER) AS impressions,\n    CAST(clicks AS INTEGER) AS clicks,\n    CAST(conversions AS INTEGER) AS conversions\nFROM raw.google_ad_insights\n",[13560],{"type":46,"tag":99,"props":13561,"children":13562},{"__ignoreMap":7},[13563,13570,13577,13584,13591,13598,13605,13613,13620,13627,13634,13641,13648,13655,13662,13670,13677,13710,13725,13732,13779,13810,13841,13872],{"type":46,"tag":250,"props":13564,"children":13565},{"class":252,"line":23},[13566],{"type":46,"tag":250,"props":13567,"children":13568},{"style":9187},[13569],{"type":52,"value":9190},{"type":46,"tag":250,"props":13571,"children":13572},{"class":252,"line":285},[13573],{"type":46,"tag":250,"props":13574,"children":13575},{"style":9187},[13576],{"type":52,"value":13229},{"type":46,"tag":250,"props":13578,"children":13579},{"class":252,"line":299},[13580],{"type":46,"tag":250,"props":13581,"children":13582},{"style":9187},[13583],{"type":52,"value":9206},{"type":46,"tag":250,"props":13585,"children":13586},{"class":252,"line":807},[13587],{"type":46,"tag":250,"props":13588,"children":13589},{"style":9187},[13590],{"type":52,"value":9214},{"type":46,"tag":250,"props":13592,"children":13593},{"class":252,"line":820},[13594],{"type":46,"tag":250,"props":13595,"children":13596},{"style":9187},[13597],{"type":52,"value":9222},{"type":46,"tag":250,"props":13599,"children":13600},{"class":252,"line":844},[13601],{"type":46,"tag":250,"props":13602,"children":13603},{"style":9187},[13604],{"type":52,"value":9230},{"type":46,"tag":250,"props":13606,"children":13607},{"class":252,"line":862},[13608],{"type":46,"tag":250,"props":13609,"children":13610},{"style":9187},[13611],{"type":52,"value":13612},"  - raw.google_ad_insights\n",{"type":46,"tag":250,"props":13614,"children":13615},{"class":252,"line":11},[13616],{"type":46,"tag":250,"props":13617,"children":13618},{"style":9187},[13619],{"type":52,"value":9254},{"type":46,"tag":250,"props":13621,"children":13622},{"class":252,"line":4649},[13623],{"type":46,"tag":250,"props":13624,"children":13625},{"style":9187},[13626],{"type":52,"value":13280},{"type":46,"tag":250,"props":13628,"children":13629},{"class":252,"line":9257},[13630],{"type":46,"tag":250,"props":13631,"children":13632},{"style":9187},[13633],{"type":52,"value":13288},{"type":46,"tag":250,"props":13635,"children":13636},{"class":252,"line":9266},[13637],{"type":46,"tag":250,"props":13638,"children":13639},{"style":9187},[13640],{"type":52,"value":9281},{"type":46,"tag":250,"props":13642,"children":13643},{"class":252,"line":9275},[13644],{"type":46,"tag":250,"props":13645,"children":13646},{"style":9187},[13647],{"type":52,"value":9290},{"type":46,"tag":250,"props":13649,"children":13650},{"class":252,"line":9284},[13651],{"type":46,"tag":250,"props":13652,"children":13653},{"style":9187},[13654],{"type":52,"value":9377},{"type":46,"tag":250,"props":13656,"children":13657},{"class":252,"line":9293},[13658],{"type":46,"tag":250,"props":13659,"children":13660},{"emptyLinePlaceholder":22},[13661],{"type":52,"value":9386},{"type":46,"tag":250,"props":13663,"children":13664},{"class":252,"line":4121},[13665],{"type":46,"tag":250,"props":13666,"children":13667},{"style":9187},[13668],{"type":52,"value":13669},"-- Google Ads spend\n",{"type":46,"tag":250,"props":13671,"children":13672},{"class":252,"line":9310},[13673],{"type":46,"tag":250,"props":13674,"children":13675},{"style":375},[13676],{"type":52,"value":9395},{"type":46,"tag":250,"props":13678,"children":13679},{"class":252,"line":9319},[13680,13684,13688,13693,13697,13701,13706],{"type":46,"tag":250,"props":13681,"children":13682},{"style":375},[13683],{"type":52,"value":13339},{"type":46,"tag":250,"props":13685,"children":13686},{"style":268},[13687],{"type":52,"value":9557},{"type":46,"tag":250,"props":13689,"children":13690},{"style":375},[13691],{"type":52,"value":13692},"date",{"type":46,"tag":250,"props":13694,"children":13695},{"style":268},[13696],{"type":52,"value":10086},{"type":46,"tag":250,"props":13698,"children":13699},{"style":375},[13700],{"type":52,"value":9608},{"type":46,"tag":250,"props":13702,"children":13703},{"style":268},[13704],{"type":52,"value":13705}," spend_date,             ",{"type":46,"tag":250,"props":13707,"children":13708},{"style":9187},[13709],{"type":52,"value":13358},{"type":46,"tag":250,"props":13711,"children":13712},{"class":252,"line":9327},[13713,13717,13721],{"type":46,"tag":250,"props":13714,"children":13715},{"style":262},[13716],{"type":52,"value":13366},{"type":46,"tag":250,"props":13718,"children":13719},{"style":375},[13720],{"type":52,"value":9418},{"type":46,"tag":250,"props":13722,"children":13723},{"style":268},[13724],{"type":52,"value":13375},{"type":46,"tag":250,"props":13726,"children":13727},{"class":252,"line":9335},[13728],{"type":46,"tag":250,"props":13729,"children":13730},{"style":268},[13731],{"type":52,"value":13383},{"type":46,"tag":250,"props":13733,"children":13734},{"class":252,"line":9344},[13735,13739,13743,13747,13751,13755,13759,13763,13767,13771,13775],{"type":46,"tag":250,"props":13736,"children":13737},{"style":274},[13738],{"type":52,"value":9552},{"type":46,"tag":250,"props":13740,"children":13741},{"style":268},[13742],{"type":52,"value":13395},{"type":46,"tag":250,"props":13744,"children":13745},{"style":375},[13746],{"type":52,"value":9608},{"type":46,"tag":250,"props":13748,"children":13749},{"style":375},[13750],{"type":52,"value":9579},{"type":46,"tag":250,"props":13752,"children":13753},{"style":268},[13754],{"type":52,"value":9557},{"type":46,"tag":250,"props":13756,"children":13757},{"style":274},[13758],{"type":52,"value":9588},{"type":46,"tag":250,"props":13760,"children":13761},{"style":268},[13762],{"type":52,"value":9593},{"type":46,"tag":250,"props":13764,"children":13765},{"style":274},[13766],{"type":52,"value":9598},{"type":46,"tag":250,"props":13768,"children":13769},{"style":268},[13770],{"type":52,"value":9603},{"type":46,"tag":250,"props":13772,"children":13773},{"style":375},[13774],{"type":52,"value":9608},{"type":46,"tag":250,"props":13776,"children":13777},{"style":268},[13778],{"type":52,"value":13432},{"type":46,"tag":250,"props":13780,"children":13781},{"class":252,"line":9353},[13782,13786,13790,13794,13798,13802,13806],{"type":46,"tag":250,"props":13783,"children":13784},{"style":274},[13785],{"type":52,"value":9552},{"type":46,"tag":250,"props":13787,"children":13788},{"style":268},[13789],{"type":52,"value":13444},{"type":46,"tag":250,"props":13791,"children":13792},{"style":375},[13793],{"type":52,"value":9608},{"type":46,"tag":250,"props":13795,"children":13796},{"style":375},[13797],{"type":52,"value":13453},{"type":46,"tag":250,"props":13799,"children":13800},{"style":268},[13801],{"type":52,"value":10086},{"type":46,"tag":250,"props":13803,"children":13804},{"style":375},[13805],{"type":52,"value":9608},{"type":46,"tag":250,"props":13807,"children":13808},{"style":268},[13809],{"type":52,"value":13466},{"type":46,"tag":250,"props":13811,"children":13812},{"class":252,"line":9362},[13813,13817,13821,13825,13829,13833,13837],{"type":46,"tag":250,"props":13814,"children":13815},{"style":274},[13816],{"type":52,"value":9552},{"type":46,"tag":250,"props":13818,"children":13819},{"style":268},[13820],{"type":52,"value":13478},{"type":46,"tag":250,"props":13822,"children":13823},{"style":375},[13824],{"type":52,"value":9608},{"type":46,"tag":250,"props":13826,"children":13827},{"style":375},[13828],{"type":52,"value":13453},{"type":46,"tag":250,"props":13830,"children":13831},{"style":268},[13832],{"type":52,"value":10086},{"type":46,"tag":250,"props":13834,"children":13835},{"style":375},[13836],{"type":52,"value":9608},{"type":46,"tag":250,"props":13838,"children":13839},{"style":268},[13840],{"type":52,"value":13499},{"type":46,"tag":250,"props":13842,"children":13843},{"class":252,"line":9371},[13844,13848,13852,13856,13860,13864,13868],{"type":46,"tag":250,"props":13845,"children":13846},{"style":274},[13847],{"type":52,"value":9552},{"type":46,"tag":250,"props":13849,"children":13850},{"style":268},[13851],{"type":52,"value":13511},{"type":46,"tag":250,"props":13853,"children":13854},{"style":375},[13855],{"type":52,"value":9608},{"type":46,"tag":250,"props":13857,"children":13858},{"style":375},[13859],{"type":52,"value":13453},{"type":46,"tag":250,"props":13861,"children":13862},{"style":268},[13863],{"type":52,"value":10086},{"type":46,"tag":250,"props":13865,"children":13866},{"style":375},[13867],{"type":52,"value":9608},{"type":46,"tag":250,"props":13869,"children":13870},{"style":268},[13871],{"type":52,"value":13532},{"type":46,"tag":250,"props":13873,"children":13874},{"class":252,"line":9380},[13875,13879,13883,13887],{"type":46,"tag":250,"props":13876,"children":13877},{"style":375},[13878],{"type":52,"value":9969},{"type":46,"tag":250,"props":13880,"children":13881},{"style":274},[13882],{"type":52,"value":9974},{"type":46,"tag":250,"props":13884,"children":13885},{"style":268},[13886],{"type":52,"value":106},{"type":46,"tag":250,"props":13888,"children":13889},{"style":274},[13890],{"type":52,"value":13891},"google_ad_insights\n",{"type":46,"tag":429,"props":13893,"children":13894},{"v-slot:tiktok-ads":7},[13895],{"type":46,"tag":240,"props":13896,"children":13898},{"className":9175,"code":13897,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_marketing_spend\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.tiktok_ad_insights\ncolumns:\n  - name: spend_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\n-- TikTok Ads spend\nSELECT\n    DATE(stat_datetime) AS spend_date,    -- use toDate() for ClickHouse, ::DATE for Snowflake\n    'paid_ads' AS channel,\n    campaign_name,\n    CAST(spend AS DECIMAL(12,2)) AS spend,\n    CAST(impressions AS INTEGER) AS impressions,\n    CAST(clicks AS INTEGER) AS clicks,\n    CAST(conversions AS INTEGER) AS conversions\nFROM raw.tiktok_ad_insights\n",[13899],{"type":46,"tag":99,"props":13900,"children":13901},{"__ignoreMap":7},[13902,13909,13916,13923,13930,13937,13944,13952,13959,13966,13973,13980,13987,13994,14001,14009,14016,14041,14056,14063,14110,14141,14172,14203],{"type":46,"tag":250,"props":13903,"children":13904},{"class":252,"line":23},[13905],{"type":46,"tag":250,"props":13906,"children":13907},{"style":9187},[13908],{"type":52,"value":9190},{"type":46,"tag":250,"props":13910,"children":13911},{"class":252,"line":285},[13912],{"type":46,"tag":250,"props":13913,"children":13914},{"style":9187},[13915],{"type":52,"value":13229},{"type":46,"tag":250,"props":13917,"children":13918},{"class":252,"line":299},[13919],{"type":46,"tag":250,"props":13920,"children":13921},{"style":9187},[13922],{"type":52,"value":9206},{"type":46,"tag":250,"props":13924,"children":13925},{"class":252,"line":807},[13926],{"type":46,"tag":250,"props":13927,"children":13928},{"style":9187},[13929],{"type":52,"value":9214},{"type":46,"tag":250,"props":13931,"children":13932},{"class":252,"line":820},[13933],{"type":46,"tag":250,"props":13934,"children":13935},{"style":9187},[13936],{"type":52,"value":9222},{"type":46,"tag":250,"props":13938,"children":13939},{"class":252,"line":844},[13940],{"type":46,"tag":250,"props":13941,"children":13942},{"style":9187},[13943],{"type":52,"value":9230},{"type":46,"tag":250,"props":13945,"children":13946},{"class":252,"line":862},[13947],{"type":46,"tag":250,"props":13948,"children":13949},{"style":9187},[13950],{"type":52,"value":13951},"  - raw.tiktok_ad_insights\n",{"type":46,"tag":250,"props":13953,"children":13954},{"class":252,"line":11},[13955],{"type":46,"tag":250,"props":13956,"children":13957},{"style":9187},[13958],{"type":52,"value":9254},{"type":46,"tag":250,"props":13960,"children":13961},{"class":252,"line":4649},[13962],{"type":46,"tag":250,"props":13963,"children":13964},{"style":9187},[13965],{"type":52,"value":13280},{"type":46,"tag":250,"props":13967,"children":13968},{"class":252,"line":9257},[13969],{"type":46,"tag":250,"props":13970,"children":13971},{"style":9187},[13972],{"type":52,"value":13288},{"type":46,"tag":250,"props":13974,"children":13975},{"class":252,"line":9266},[13976],{"type":46,"tag":250,"props":13977,"children":13978},{"style":9187},[13979],{"type":52,"value":9281},{"type":46,"tag":250,"props":13981,"children":13982},{"class":252,"line":9275},[13983],{"type":46,"tag":250,"props":13984,"children":13985},{"style":9187},[13986],{"type":52,"value":9290},{"type":46,"tag":250,"props":13988,"children":13989},{"class":252,"line":9284},[13990],{"type":46,"tag":250,"props":13991,"children":13992},{"style":9187},[13993],{"type":52,"value":9377},{"type":46,"tag":250,"props":13995,"children":13996},{"class":252,"line":9293},[13997],{"type":46,"tag":250,"props":13998,"children":13999},{"emptyLinePlaceholder":22},[14000],{"type":52,"value":9386},{"type":46,"tag":250,"props":14002,"children":14003},{"class":252,"line":4121},[14004],{"type":46,"tag":250,"props":14005,"children":14006},{"style":9187},[14007],{"type":52,"value":14008},"-- TikTok Ads spend\n",{"type":46,"tag":250,"props":14010,"children":14011},{"class":252,"line":9310},[14012],{"type":46,"tag":250,"props":14013,"children":14014},{"style":375},[14015],{"type":52,"value":9395},{"type":46,"tag":250,"props":14017,"children":14018},{"class":252,"line":9319},[14019,14023,14028,14032,14037],{"type":46,"tag":250,"props":14020,"children":14021},{"style":375},[14022],{"type":52,"value":13339},{"type":46,"tag":250,"props":14024,"children":14025},{"style":268},[14026],{"type":52,"value":14027},"(stat_datetime) ",{"type":46,"tag":250,"props":14029,"children":14030},{"style":375},[14031],{"type":52,"value":9608},{"type":46,"tag":250,"props":14033,"children":14034},{"style":268},[14035],{"type":52,"value":14036}," spend_date,    ",{"type":46,"tag":250,"props":14038,"children":14039},{"style":9187},[14040],{"type":52,"value":13358},{"type":46,"tag":250,"props":14042,"children":14043},{"class":252,"line":9327},[14044,14048,14052],{"type":46,"tag":250,"props":14045,"children":14046},{"style":262},[14047],{"type":52,"value":13366},{"type":46,"tag":250,"props":14049,"children":14050},{"style":375},[14051],{"type":52,"value":9418},{"type":46,"tag":250,"props":14053,"children":14054},{"style":268},[14055],{"type":52,"value":13375},{"type":46,"tag":250,"props":14057,"children":14058},{"class":252,"line":9335},[14059],{"type":46,"tag":250,"props":14060,"children":14061},{"style":268},[14062],{"type":52,"value":13383},{"type":46,"tag":250,"props":14064,"children":14065},{"class":252,"line":9344},[14066,14070,14074,14078,14082,14086,14090,14094,14098,14102,14106],{"type":46,"tag":250,"props":14067,"children":14068},{"style":274},[14069],{"type":52,"value":9552},{"type":46,"tag":250,"props":14071,"children":14072},{"style":268},[14073],{"type":52,"value":13395},{"type":46,"tag":250,"props":14075,"children":14076},{"style":375},[14077],{"type":52,"value":9608},{"type":46,"tag":250,"props":14079,"children":14080},{"style":375},[14081],{"type":52,"value":9579},{"type":46,"tag":250,"props":14083,"children":14084},{"style":268},[14085],{"type":52,"value":9557},{"type":46,"tag":250,"props":14087,"children":14088},{"style":274},[14089],{"type":52,"value":9588},{"type":46,"tag":250,"props":14091,"children":14092},{"style":268},[14093],{"type":52,"value":9593},{"type":46,"tag":250,"props":14095,"children":14096},{"style":274},[14097],{"type":52,"value":9598},{"type":46,"tag":250,"props":14099,"children":14100},{"style":268},[14101],{"type":52,"value":9603},{"type":46,"tag":250,"props":14103,"children":14104},{"style":375},[14105],{"type":52,"value":9608},{"type":46,"tag":250,"props":14107,"children":14108},{"style":268},[14109],{"type":52,"value":13432},{"type":46,"tag":250,"props":14111,"children":14112},{"class":252,"line":9353},[14113,14117,14121,14125,14129,14133,14137],{"type":46,"tag":250,"props":14114,"children":14115},{"style":274},[14116],{"type":52,"value":9552},{"type":46,"tag":250,"props":14118,"children":14119},{"style":268},[14120],{"type":52,"value":13444},{"type":46,"tag":250,"props":14122,"children":14123},{"style":375},[14124],{"type":52,"value":9608},{"type":46,"tag":250,"props":14126,"children":14127},{"style":375},[14128],{"type":52,"value":13453},{"type":46,"tag":250,"props":14130,"children":14131},{"style":268},[14132],{"type":52,"value":10086},{"type":46,"tag":250,"props":14134,"children":14135},{"style":375},[14136],{"type":52,"value":9608},{"type":46,"tag":250,"props":14138,"children":14139},{"style":268},[14140],{"type":52,"value":13466},{"type":46,"tag":250,"props":14142,"children":14143},{"class":252,"line":9362},[14144,14148,14152,14156,14160,14164,14168],{"type":46,"tag":250,"props":14145,"children":14146},{"style":274},[14147],{"type":52,"value":9552},{"type":46,"tag":250,"props":14149,"children":14150},{"style":268},[14151],{"type":52,"value":13478},{"type":46,"tag":250,"props":14153,"children":14154},{"style":375},[14155],{"type":52,"value":9608},{"type":46,"tag":250,"props":14157,"children":14158},{"style":375},[14159],{"type":52,"value":13453},{"type":46,"tag":250,"props":14161,"children":14162},{"style":268},[14163],{"type":52,"value":10086},{"type":46,"tag":250,"props":14165,"children":14166},{"style":375},[14167],{"type":52,"value":9608},{"type":46,"tag":250,"props":14169,"children":14170},{"style":268},[14171],{"type":52,"value":13499},{"type":46,"tag":250,"props":14173,"children":14174},{"class":252,"line":9371},[14175,14179,14183,14187,14191,14195,14199],{"type":46,"tag":250,"props":14176,"children":14177},{"style":274},[14178],{"type":52,"value":9552},{"type":46,"tag":250,"props":14180,"children":14181},{"style":268},[14182],{"type":52,"value":13511},{"type":46,"tag":250,"props":14184,"children":14185},{"style":375},[14186],{"type":52,"value":9608},{"type":46,"tag":250,"props":14188,"children":14189},{"style":375},[14190],{"type":52,"value":13453},{"type":46,"tag":250,"props":14192,"children":14193},{"style":268},[14194],{"type":52,"value":10086},{"type":46,"tag":250,"props":14196,"children":14197},{"style":375},[14198],{"type":52,"value":9608},{"type":46,"tag":250,"props":14200,"children":14201},{"style":268},[14202],{"type":52,"value":13532},{"type":46,"tag":250,"props":14204,"children":14205},{"class":252,"line":9380},[14206,14210,14214,14218],{"type":46,"tag":250,"props":14207,"children":14208},{"style":375},[14209],{"type":52,"value":9969},{"type":46,"tag":250,"props":14211,"children":14212},{"style":274},[14213],{"type":52,"value":9974},{"type":46,"tag":250,"props":14215,"children":14216},{"style":268},[14217],{"type":52,"value":106},{"type":46,"tag":250,"props":14219,"children":14220},{"style":274},[14221],{"type":52,"value":14222},"tiktok_ad_insights\n",{"type":46,"tag":4472,"props":14224,"children":14226},{"id":14225},"email-marketing-portion",[14227],{"type":52,"value":14228},"Email marketing portion",{"type":46,"tag":55,"props":14230,"children":14231},{},[14232,14234,14240],{"type":52,"value":14233},"The email side of the query uses ",{"type":46,"tag":99,"props":14235,"children":14237},{"className":14236},[],[14238],{"type":52,"value":14239},"UNION ALL",{"type":52,"value":14241}," to append email campaign data below the ads data. The columns and table names differ by email platform:",{"type":46,"tag":423,"props":14243,"children":14244},{":variants":5885,"group":5886},[14245,14591],{"type":46,"tag":429,"props":14246,"children":14247},{"v-slot:klaviyo":7},[14248,14259,14564],{"type":46,"tag":55,"props":14249,"children":14250},{},[14251,14253,14258],{"type":52,"value":14252},"Append this to the ads query above with ",{"type":46,"tag":99,"props":14254,"children":14256},{"className":14255},[],[14257],{"type":52,"value":14239},{"type":52,"value":9166},{"type":46,"tag":240,"props":14260,"children":14262},{"className":9175,"code":14261,"language":9177,"meta":7,"style":7},"UNION ALL\n\n-- Klaviyo email campaigns (no direct spend, but track engagement)\nSELECT\n    send_time::date AS spend_date,   -- adjust cast for your warehouse\n    'email' AS channel,\n    name AS campaign_name,\n    0.00 AS spend,\n    num_recipients AS impressions,\n    CAST(click_count AS INTEGER) AS clicks,\n    CAST(conversion_count AS INTEGER) AS conversions\nFROM raw.klaviyo_campaigns kc\nLEFT JOIN raw.klaviyo_metrics km\n    ON kc.id = km.campaign_id\nWHERE send_time IS NOT NULL\n",[14263],{"type":46,"tag":99,"props":14264,"children":14265},{"__ignoreMap":7},[14266,14274,14281,14289,14296,14322,14338,14355,14380,14396,14428,14460,14485,14510,14548],{"type":46,"tag":250,"props":14267,"children":14268},{"class":252,"line":23},[14269],{"type":46,"tag":250,"props":14270,"children":14271},{"style":375},[14272],{"type":52,"value":14273},"UNION ALL\n",{"type":46,"tag":250,"props":14275,"children":14276},{"class":252,"line":285},[14277],{"type":46,"tag":250,"props":14278,"children":14279},{"emptyLinePlaceholder":22},[14280],{"type":52,"value":9386},{"type":46,"tag":250,"props":14282,"children":14283},{"class":252,"line":299},[14284],{"type":46,"tag":250,"props":14285,"children":14286},{"style":9187},[14287],{"type":52,"value":14288},"-- Klaviyo email campaigns (no direct spend, but track engagement)\n",{"type":46,"tag":250,"props":14290,"children":14291},{"class":252,"line":807},[14292],{"type":46,"tag":250,"props":14293,"children":14294},{"style":375},[14295],{"type":52,"value":9395},{"type":46,"tag":250,"props":14297,"children":14298},{"class":252,"line":820},[14299,14304,14308,14312,14317],{"type":46,"tag":250,"props":14300,"children":14301},{"style":268},[14302],{"type":52,"value":14303},"    send_time::",{"type":46,"tag":250,"props":14305,"children":14306},{"style":375},[14307],{"type":52,"value":13692},{"type":46,"tag":250,"props":14309,"children":14310},{"style":375},[14311],{"type":52,"value":9418},{"type":46,"tag":250,"props":14313,"children":14314},{"style":268},[14315],{"type":52,"value":14316}," spend_date,   ",{"type":46,"tag":250,"props":14318,"children":14319},{"style":9187},[14320],{"type":52,"value":14321},"-- adjust cast for your warehouse\n",{"type":46,"tag":250,"props":14323,"children":14324},{"class":252,"line":844},[14325,14330,14334],{"type":46,"tag":250,"props":14326,"children":14327},{"style":262},[14328],{"type":52,"value":14329},"    'email'",{"type":46,"tag":250,"props":14331,"children":14332},{"style":375},[14333],{"type":52,"value":9418},{"type":46,"tag":250,"props":14335,"children":14336},{"style":268},[14337],{"type":52,"value":13375},{"type":46,"tag":250,"props":14339,"children":14340},{"class":252,"line":862},[14341,14346,14350],{"type":46,"tag":250,"props":14342,"children":14343},{"style":375},[14344],{"type":52,"value":14345},"    name",{"type":46,"tag":250,"props":14347,"children":14348},{"style":375},[14349],{"type":52,"value":9418},{"type":46,"tag":250,"props":14351,"children":14352},{"style":268},[14353],{"type":52,"value":14354}," campaign_name,\n",{"type":46,"tag":250,"props":14356,"children":14357},{"class":252,"line":11},[14358,14363,14367,14372,14376],{"type":46,"tag":250,"props":14359,"children":14360},{"style":274},[14361],{"type":52,"value":14362},"    0",{"type":46,"tag":250,"props":14364,"children":14365},{"style":268},[14366],{"type":52,"value":106},{"type":46,"tag":250,"props":14368,"children":14369},{"style":274},[14370],{"type":52,"value":14371},"00",{"type":46,"tag":250,"props":14373,"children":14374},{"style":375},[14375],{"type":52,"value":9418},{"type":46,"tag":250,"props":14377,"children":14378},{"style":268},[14379],{"type":52,"value":13432},{"type":46,"tag":250,"props":14381,"children":14382},{"class":252,"line":4649},[14383,14388,14392],{"type":46,"tag":250,"props":14384,"children":14385},{"style":268},[14386],{"type":52,"value":14387},"    num_recipients ",{"type":46,"tag":250,"props":14389,"children":14390},{"style":375},[14391],{"type":52,"value":9608},{"type":46,"tag":250,"props":14393,"children":14394},{"style":268},[14395],{"type":52,"value":13466},{"type":46,"tag":250,"props":14397,"children":14398},{"class":252,"line":9257},[14399,14403,14408,14412,14416,14420,14424],{"type":46,"tag":250,"props":14400,"children":14401},{"style":274},[14402],{"type":52,"value":9552},{"type":46,"tag":250,"props":14404,"children":14405},{"style":268},[14406],{"type":52,"value":14407},"(click_count ",{"type":46,"tag":250,"props":14409,"children":14410},{"style":375},[14411],{"type":52,"value":9608},{"type":46,"tag":250,"props":14413,"children":14414},{"style":375},[14415],{"type":52,"value":13453},{"type":46,"tag":250,"props":14417,"children":14418},{"style":268},[14419],{"type":52,"value":10086},{"type":46,"tag":250,"props":14421,"children":14422},{"style":375},[14423],{"type":52,"value":9608},{"type":46,"tag":250,"props":14425,"children":14426},{"style":268},[14427],{"type":52,"value":13499},{"type":46,"tag":250,"props":14429,"children":14430},{"class":252,"line":9266},[14431,14435,14440,14444,14448,14452,14456],{"type":46,"tag":250,"props":14432,"children":14433},{"style":274},[14434],{"type":52,"value":9552},{"type":46,"tag":250,"props":14436,"children":14437},{"style":268},[14438],{"type":52,"value":14439},"(conversion_count ",{"type":46,"tag":250,"props":14441,"children":14442},{"style":375},[14443],{"type":52,"value":9608},{"type":46,"tag":250,"props":14445,"children":14446},{"style":375},[14447],{"type":52,"value":13453},{"type":46,"tag":250,"props":14449,"children":14450},{"style":268},[14451],{"type":52,"value":10086},{"type":46,"tag":250,"props":14453,"children":14454},{"style":375},[14455],{"type":52,"value":9608},{"type":46,"tag":250,"props":14457,"children":14458},{"style":268},[14459],{"type":52,"value":13532},{"type":46,"tag":250,"props":14461,"children":14462},{"class":252,"line":9275},[14463,14467,14471,14475,14480],{"type":46,"tag":250,"props":14464,"children":14465},{"style":375},[14466],{"type":52,"value":9969},{"type":46,"tag":250,"props":14468,"children":14469},{"style":274},[14470],{"type":52,"value":9974},{"type":46,"tag":250,"props":14472,"children":14473},{"style":268},[14474],{"type":52,"value":106},{"type":46,"tag":250,"props":14476,"children":14477},{"style":274},[14478],{"type":52,"value":14479},"klaviyo_campaigns",{"type":46,"tag":250,"props":14481,"children":14482},{"style":268},[14483],{"type":52,"value":14484}," kc\n",{"type":46,"tag":250,"props":14486,"children":14487},{"class":252,"line":9284},[14488,14492,14496,14500,14505],{"type":46,"tag":250,"props":14489,"children":14490},{"style":375},[14491],{"type":52,"value":9077},{"type":46,"tag":250,"props":14493,"children":14494},{"style":274},[14495],{"type":52,"value":9974},{"type":46,"tag":250,"props":14497,"children":14498},{"style":268},[14499],{"type":52,"value":106},{"type":46,"tag":250,"props":14501,"children":14502},{"style":274},[14503],{"type":52,"value":14504},"klaviyo_metrics",{"type":46,"tag":250,"props":14506,"children":14507},{"style":268},[14508],{"type":52,"value":14509}," km\n",{"type":46,"tag":250,"props":14511,"children":14512},{"class":252,"line":9293},[14513,14517,14522,14526,14530,14534,14539,14543],{"type":46,"tag":250,"props":14514,"children":14515},{"style":375},[14516],{"type":52,"value":10023},{"type":46,"tag":250,"props":14518,"children":14519},{"style":274},[14520],{"type":52,"value":14521}," kc",{"type":46,"tag":250,"props":14523,"children":14524},{"style":268},[14525],{"type":52,"value":106},{"type":46,"tag":250,"props":14527,"children":14528},{"style":274},[14529],{"type":52,"value":9413},{"type":46,"tag":250,"props":14531,"children":14532},{"style":375},[14533],{"type":52,"value":10041},{"type":46,"tag":250,"props":14535,"children":14536},{"style":274},[14537],{"type":52,"value":14538}," km",{"type":46,"tag":250,"props":14540,"children":14541},{"style":268},[14542],{"type":52,"value":106},{"type":46,"tag":250,"props":14544,"children":14545},{"style":274},[14546],{"type":52,"value":14547},"campaign_id\n",{"type":46,"tag":250,"props":14549,"children":14550},{"class":252,"line":4121},[14551,14555,14560],{"type":46,"tag":250,"props":14552,"children":14553},{"style":375},[14554],{"type":52,"value":10942},{"type":46,"tag":250,"props":14556,"children":14557},{"style":268},[14558],{"type":52,"value":14559}," send_time ",{"type":46,"tag":250,"props":14561,"children":14562},{"style":375},[14563],{"type":52,"value":12726},{"type":46,"tag":55,"props":14565,"children":14566},{},[14567,14569,14575,14576,14582,14584,14589],{"type":52,"value":14568},"Add ",{"type":46,"tag":99,"props":14570,"children":14572},{"className":14571},[],[14573],{"type":52,"value":14574},"raw.klaviyo_campaigns",{"type":52,"value":8572},{"type":46,"tag":99,"props":14577,"children":14579},{"className":14578},[],[14580],{"type":52,"value":14581},"raw.klaviyo_metrics",{"type":52,"value":14583}," to the ",{"type":46,"tag":99,"props":14585,"children":14587},{"className":14586},[],[14588],{"type":52,"value":9093},{"type":52,"value":14590}," list in the Bruin asset header.",{"type":46,"tag":429,"props":14592,"children":14593},{"v-slot:hubspot":7},[14594,14604,14832],{"type":46,"tag":55,"props":14595,"children":14596},{},[14597,14598,14603],{"type":52,"value":14252},{"type":46,"tag":99,"props":14599,"children":14601},{"className":14600},[],[14602],{"type":52,"value":14239},{"type":52,"value":9166},{"type":46,"tag":240,"props":14605,"children":14607},{"className":9175,"code":14606,"language":9177,"meta":7,"style":7},"UNION ALL\n\n-- HubSpot email campaigns (no direct spend, but track engagement)\nSELECT\n    updated_at::date AS spend_date,   -- adjust cast for your warehouse\n    'email' AS channel,\n    name AS campaign_name,\n    0.00 AS spend,\n    CAST(num_included AS INTEGER) AS impressions,\n    CAST(num_clicks AS INTEGER) AS clicks,\n    0 AS conversions\nFROM raw.hubspot_campaigns\nWHERE name IS NOT NULL\n",[14608],{"type":46,"tag":99,"props":14609,"children":14610},{"__ignoreMap":7},[14611,14618,14625,14633,14640,14664,14679,14694,14717,14749,14781,14796,14816],{"type":46,"tag":250,"props":14612,"children":14613},{"class":252,"line":23},[14614],{"type":46,"tag":250,"props":14615,"children":14616},{"style":375},[14617],{"type":52,"value":14273},{"type":46,"tag":250,"props":14619,"children":14620},{"class":252,"line":285},[14621],{"type":46,"tag":250,"props":14622,"children":14623},{"emptyLinePlaceholder":22},[14624],{"type":52,"value":9386},{"type":46,"tag":250,"props":14626,"children":14627},{"class":252,"line":299},[14628],{"type":46,"tag":250,"props":14629,"children":14630},{"style":9187},[14631],{"type":52,"value":14632},"-- HubSpot email campaigns (no direct spend, but track engagement)\n",{"type":46,"tag":250,"props":14634,"children":14635},{"class":252,"line":807},[14636],{"type":46,"tag":250,"props":14637,"children":14638},{"style":375},[14639],{"type":52,"value":9395},{"type":46,"tag":250,"props":14641,"children":14642},{"class":252,"line":820},[14643,14648,14652,14656,14660],{"type":46,"tag":250,"props":14644,"children":14645},{"style":268},[14646],{"type":52,"value":14647},"    updated_at::",{"type":46,"tag":250,"props":14649,"children":14650},{"style":375},[14651],{"type":52,"value":13692},{"type":46,"tag":250,"props":14653,"children":14654},{"style":375},[14655],{"type":52,"value":9418},{"type":46,"tag":250,"props":14657,"children":14658},{"style":268},[14659],{"type":52,"value":14316},{"type":46,"tag":250,"props":14661,"children":14662},{"style":9187},[14663],{"type":52,"value":14321},{"type":46,"tag":250,"props":14665,"children":14666},{"class":252,"line":844},[14667,14671,14675],{"type":46,"tag":250,"props":14668,"children":14669},{"style":262},[14670],{"type":52,"value":14329},{"type":46,"tag":250,"props":14672,"children":14673},{"style":375},[14674],{"type":52,"value":9418},{"type":46,"tag":250,"props":14676,"children":14677},{"style":268},[14678],{"type":52,"value":13375},{"type":46,"tag":250,"props":14680,"children":14681},{"class":252,"line":862},[14682,14686,14690],{"type":46,"tag":250,"props":14683,"children":14684},{"style":375},[14685],{"type":52,"value":14345},{"type":46,"tag":250,"props":14687,"children":14688},{"style":375},[14689],{"type":52,"value":9418},{"type":46,"tag":250,"props":14691,"children":14692},{"style":268},[14693],{"type":52,"value":14354},{"type":46,"tag":250,"props":14695,"children":14696},{"class":252,"line":11},[14697,14701,14705,14709,14713],{"type":46,"tag":250,"props":14698,"children":14699},{"style":274},[14700],{"type":52,"value":14362},{"type":46,"tag":250,"props":14702,"children":14703},{"style":268},[14704],{"type":52,"value":106},{"type":46,"tag":250,"props":14706,"children":14707},{"style":274},[14708],{"type":52,"value":14371},{"type":46,"tag":250,"props":14710,"children":14711},{"style":375},[14712],{"type":52,"value":9418},{"type":46,"tag":250,"props":14714,"children":14715},{"style":268},[14716],{"type":52,"value":13432},{"type":46,"tag":250,"props":14718,"children":14719},{"class":252,"line":4649},[14720,14724,14729,14733,14737,14741,14745],{"type":46,"tag":250,"props":14721,"children":14722},{"style":274},[14723],{"type":52,"value":9552},{"type":46,"tag":250,"props":14725,"children":14726},{"style":268},[14727],{"type":52,"value":14728},"(num_included ",{"type":46,"tag":250,"props":14730,"children":14731},{"style":375},[14732],{"type":52,"value":9608},{"type":46,"tag":250,"props":14734,"children":14735},{"style":375},[14736],{"type":52,"value":13453},{"type":46,"tag":250,"props":14738,"children":14739},{"style":268},[14740],{"type":52,"value":10086},{"type":46,"tag":250,"props":14742,"children":14743},{"style":375},[14744],{"type":52,"value":9608},{"type":46,"tag":250,"props":14746,"children":14747},{"style":268},[14748],{"type":52,"value":13466},{"type":46,"tag":250,"props":14750,"children":14751},{"class":252,"line":9257},[14752,14756,14761,14765,14769,14773,14777],{"type":46,"tag":250,"props":14753,"children":14754},{"style":274},[14755],{"type":52,"value":9552},{"type":46,"tag":250,"props":14757,"children":14758},{"style":268},[14759],{"type":52,"value":14760},"(num_clicks ",{"type":46,"tag":250,"props":14762,"children":14763},{"style":375},[14764],{"type":52,"value":9608},{"type":46,"tag":250,"props":14766,"children":14767},{"style":375},[14768],{"type":52,"value":13453},{"type":46,"tag":250,"props":14770,"children":14771},{"style":268},[14772],{"type":52,"value":10086},{"type":46,"tag":250,"props":14774,"children":14775},{"style":375},[14776],{"type":52,"value":9608},{"type":46,"tag":250,"props":14778,"children":14779},{"style":268},[14780],{"type":52,"value":13499},{"type":46,"tag":250,"props":14782,"children":14783},{"class":252,"line":9266},[14784,14788,14792],{"type":46,"tag":250,"props":14785,"children":14786},{"style":274},[14787],{"type":52,"value":14362},{"type":46,"tag":250,"props":14789,"children":14790},{"style":375},[14791],{"type":52,"value":9418},{"type":46,"tag":250,"props":14793,"children":14794},{"style":268},[14795],{"type":52,"value":13532},{"type":46,"tag":250,"props":14797,"children":14798},{"class":252,"line":9275},[14799,14803,14807,14811],{"type":46,"tag":250,"props":14800,"children":14801},{"style":375},[14802],{"type":52,"value":9969},{"type":46,"tag":250,"props":14804,"children":14805},{"style":274},[14806],{"type":52,"value":9974},{"type":46,"tag":250,"props":14808,"children":14809},{"style":268},[14810],{"type":52,"value":106},{"type":46,"tag":250,"props":14812,"children":14813},{"style":274},[14814],{"type":52,"value":14815},"hubspot_campaigns\n",{"type":46,"tag":250,"props":14817,"children":14818},{"class":252,"line":9284},[14819,14823,14828],{"type":46,"tag":250,"props":14820,"children":14821},{"style":375},[14822],{"type":52,"value":10942},{"type":46,"tag":250,"props":14824,"children":14825},{"style":375},[14826],{"type":52,"value":14827}," name",{"type":46,"tag":250,"props":14829,"children":14830},{"style":375},[14831],{"type":52,"value":10992},{"type":46,"tag":55,"props":14833,"children":14834},{},[14835,14836,14842,14843,14848],{"type":52,"value":14568},{"type":46,"tag":99,"props":14837,"children":14839},{"className":14838},[],[14840],{"type":52,"value":14841},"raw.hubspot_campaigns",{"type":52,"value":14583},{"type":46,"tag":99,"props":14844,"children":14846},{"className":14845},[],[14847],{"type":52,"value":9093},{"type":52,"value":14590},{"type":46,"tag":198,"props":14850,"children":14851},{},[14852],{"type":46,"tag":55,"props":14853,"children":14854},{},[14855,14857,14863,14865,14870,14872,14877],{"type":52,"value":14856},"The email portion needs both the right source columns (Klaviyo vs HubSpot) and the right date cast for your warehouse. The ",{"type":46,"tag":99,"props":14858,"children":14860},{"className":14859},[],[14861],{"type":52,"value":14862},"::date",{"type":52,"value":14864}," cast above is Snowflake syntax - ClickHouse uses ",{"type":46,"tag":99,"props":14866,"children":14868},{"className":14867},[],[14869],{"type":52,"value":13178},{"type":52,"value":14871},", BigQuery uses ",{"type":46,"tag":99,"props":14873,"children":14875},{"className":14874},[],[14876],{"type":52,"value":13186},{"type":52,"value":14878},". Ask Claude Code to generate the combined SQL for your specific stack.",{"type":46,"tag":220,"props":14880,"children":14882},{"id":14881},"_5-staged-web-sessions-stg_web_sessionssql",[14883,14885],{"type":52,"value":14884},"5) Staged web sessions - ",{"type":46,"tag":99,"props":14886,"children":14888},{"className":14887},[],[14889],{"type":52,"value":14890},"stg_web_sessions.sql",{"type":46,"tag":55,"props":14892,"children":14893},{},[14894],{"type":52,"value":14895},"Clean session data with traffic source mapping. The column names differ depending on whether you use GA4 or Mixpanel, and the date functions differ by warehouse.",{"type":46,"tag":55,"props":14897,"children":14898},{},[14899,14900,14909],{"type":52,"value":9155},{"type":46,"tag":80,"props":14901,"children":14902},{},[14903],{"type":46,"tag":99,"props":14904,"children":14906},{"className":14905},[],[14907],{"type":52,"value":14908},"ecommerce\u002Fassets\u002Fstaging\u002Fstg_web_sessions.sql",{"type":52,"value":9166},{"type":46,"tag":4472,"props":14911,"children":14913},{"id":14912},"source-specific-columns",[14914],{"type":52,"value":14915},"Source-specific columns",{"type":46,"tag":55,"props":14917,"children":14918},{},[14919,14921,14927,14928,14934,14936,14942],{"type":52,"value":14920},"The raw table names differ by analytics tool. GA4 creates ",{"type":46,"tag":99,"props":14922,"children":14924},{"className":14923},[],[14925],{"type":52,"value":14926},"raw.ga4_sessions",{"type":52,"value":8572},{"type":46,"tag":99,"props":14929,"children":14931},{"className":14930},[],[14932],{"type":52,"value":14933},"raw.ga4_events",{"type":52,"value":14935},"; Mixpanel creates ",{"type":46,"tag":99,"props":14937,"children":14939},{"className":14938},[],[14940],{"type":52,"value":14941},"raw.mixpanel_events",{"type":52,"value":14943}," (no separate sessions table). Select the tab that matches your analytics tool:",{"type":46,"tag":423,"props":14945,"children":14946},{":variants":7762,"group":7763},[14947,15449],{"type":46,"tag":429,"props":14948,"children":14949},{"v-slot:ga4":7},[14950,14971],{"type":46,"tag":55,"props":14951,"children":14952},{},[14953,14955,14961,14963,14969],{"type":52,"value":14954},"GA4 gives you sessions and events as separate tables. The ",{"type":46,"tag":99,"props":14956,"children":14958},{"className":14957},[],[14959],{"type":52,"value":14960},"CASE",{"type":52,"value":14962}," statement maps GA4 traffic sources to the same channel names used in ",{"type":46,"tag":99,"props":14964,"children":14966},{"className":14965},[],[14967],{"type":52,"value":14968},"stg_marketing_spend",{"type":52,"value":14970},", so you can join them later for attribution.",{"type":46,"tag":240,"props":14972,"children":14974},{"className":9175,"code":14973,"language":9177,"meta":7,"style":7},"SELECT\n    s.date AS session_raw_date,       -- cast with your warehouse's date function\n    s.sessions AS total_sessions,\n    s.new_users,\n    s.engaged_sessions,\n    e.event_count AS purchase_events,\n    CASE\n        WHEN s.source = 'facebook' THEN 'paid_ads'\n        WHEN s.medium = 'email' THEN 'email'\n        WHEN s.medium = 'organic' THEN 'organic_search'\n        WHEN s.medium = 'cpc' THEN 'paid_search'\n        WHEN s.source = '(direct)' THEN 'direct'\n        ELSE 'other'\n    END AS channel\nFROM raw.ga4_sessions s\nLEFT JOIN raw.ga4_events e\n    ON s.date = e.date\n    AND e.event_name = 'purchase'\n",[14975],{"type":46,"tag":99,"props":14976,"children":14977},{"__ignoreMap":7},[14978,14985,15015,15040,15060,15080,15106,15114,15155,15193,15230,15267,15304,15317,15334,15359,15384,15420],{"type":46,"tag":250,"props":14979,"children":14980},{"class":252,"line":23},[14981],{"type":46,"tag":250,"props":14982,"children":14983},{"style":375},[14984],{"type":52,"value":9395},{"type":46,"tag":250,"props":14986,"children":14987},{"class":252,"line":285},[14988,14993,14997,15001,15005,15010],{"type":46,"tag":250,"props":14989,"children":14990},{"style":274},[14991],{"type":52,"value":14992},"    s",{"type":46,"tag":250,"props":14994,"children":14995},{"style":268},[14996],{"type":52,"value":106},{"type":46,"tag":250,"props":14998,"children":14999},{"style":274},[15000],{"type":52,"value":13692},{"type":46,"tag":250,"props":15002,"children":15003},{"style":375},[15004],{"type":52,"value":9418},{"type":46,"tag":250,"props":15006,"children":15007},{"style":268},[15008],{"type":52,"value":15009}," session_raw_date,       ",{"type":46,"tag":250,"props":15011,"children":15012},{"style":9187},[15013],{"type":52,"value":15014},"-- cast with your warehouse's date function\n",{"type":46,"tag":250,"props":15016,"children":15017},{"class":252,"line":299},[15018,15022,15026,15031,15035],{"type":46,"tag":250,"props":15019,"children":15020},{"style":274},[15021],{"type":52,"value":14992},{"type":46,"tag":250,"props":15023,"children":15024},{"style":268},[15025],{"type":52,"value":106},{"type":46,"tag":250,"props":15027,"children":15028},{"style":274},[15029],{"type":52,"value":15030},"sessions",{"type":46,"tag":250,"props":15032,"children":15033},{"style":375},[15034],{"type":52,"value":9418},{"type":46,"tag":250,"props":15036,"children":15037},{"style":268},[15038],{"type":52,"value":15039}," total_sessions,\n",{"type":46,"tag":250,"props":15041,"children":15042},{"class":252,"line":807},[15043,15047,15051,15056],{"type":46,"tag":250,"props":15044,"children":15045},{"style":274},[15046],{"type":52,"value":14992},{"type":46,"tag":250,"props":15048,"children":15049},{"style":268},[15050],{"type":52,"value":106},{"type":46,"tag":250,"props":15052,"children":15053},{"style":274},[15054],{"type":52,"value":15055},"new_users",{"type":46,"tag":250,"props":15057,"children":15058},{"style":268},[15059],{"type":52,"value":9445},{"type":46,"tag":250,"props":15061,"children":15062},{"class":252,"line":820},[15063,15067,15071,15076],{"type":46,"tag":250,"props":15064,"children":15065},{"style":274},[15066],{"type":52,"value":14992},{"type":46,"tag":250,"props":15068,"children":15069},{"style":268},[15070],{"type":52,"value":106},{"type":46,"tag":250,"props":15072,"children":15073},{"style":274},[15074],{"type":52,"value":15075},"engaged_sessions",{"type":46,"tag":250,"props":15077,"children":15078},{"style":268},[15079],{"type":52,"value":9445},{"type":46,"tag":250,"props":15081,"children":15082},{"class":252,"line":844},[15083,15088,15092,15097,15101],{"type":46,"tag":250,"props":15084,"children":15085},{"style":274},[15086],{"type":52,"value":15087},"    e",{"type":46,"tag":250,"props":15089,"children":15090},{"style":268},[15091],{"type":52,"value":106},{"type":46,"tag":250,"props":15093,"children":15094},{"style":274},[15095],{"type":52,"value":15096},"event_count",{"type":46,"tag":250,"props":15098,"children":15099},{"style":375},[15100],{"type":52,"value":9418},{"type":46,"tag":250,"props":15102,"children":15103},{"style":268},[15104],{"type":52,"value":15105}," purchase_events,\n",{"type":46,"tag":250,"props":15107,"children":15108},{"class":252,"line":862},[15109],{"type":46,"tag":250,"props":15110,"children":15111},{"style":375},[15112],{"type":52,"value":15113},"    CASE\n",{"type":46,"tag":250,"props":15115,"children":15116},{"class":252,"line":11},[15117,15122,15127,15131,15136,15140,15145,15150],{"type":46,"tag":250,"props":15118,"children":15119},{"style":375},[15120],{"type":52,"value":15121},"        WHEN",{"type":46,"tag":250,"props":15123,"children":15124},{"style":274},[15125],{"type":52,"value":15126}," s",{"type":46,"tag":250,"props":15128,"children":15129},{"style":268},[15130],{"type":52,"value":106},{"type":46,"tag":250,"props":15132,"children":15133},{"style":274},[15134],{"type":52,"value":15135},"source",{"type":46,"tag":250,"props":15137,"children":15138},{"style":375},[15139],{"type":52,"value":10041},{"type":46,"tag":250,"props":15141,"children":15142},{"style":262},[15143],{"type":52,"value":15144}," 'facebook'",{"type":46,"tag":250,"props":15146,"children":15147},{"style":375},[15148],{"type":52,"value":15149}," THEN",{"type":46,"tag":250,"props":15151,"children":15152},{"style":262},[15153],{"type":52,"value":15154}," 'paid_ads'\n",{"type":46,"tag":250,"props":15156,"children":15157},{"class":252,"line":4649},[15158,15162,15166,15170,15175,15179,15184,15188],{"type":46,"tag":250,"props":15159,"children":15160},{"style":375},[15161],{"type":52,"value":15121},{"type":46,"tag":250,"props":15163,"children":15164},{"style":274},[15165],{"type":52,"value":15126},{"type":46,"tag":250,"props":15167,"children":15168},{"style":268},[15169],{"type":52,"value":106},{"type":46,"tag":250,"props":15171,"children":15172},{"style":274},[15173],{"type":52,"value":15174},"medium",{"type":46,"tag":250,"props":15176,"children":15177},{"style":375},[15178],{"type":52,"value":10041},{"type":46,"tag":250,"props":15180,"children":15181},{"style":262},[15182],{"type":52,"value":15183}," 'email'",{"type":46,"tag":250,"props":15185,"children":15186},{"style":375},[15187],{"type":52,"value":15149},{"type":46,"tag":250,"props":15189,"children":15190},{"style":262},[15191],{"type":52,"value":15192}," 'email'\n",{"type":46,"tag":250,"props":15194,"children":15195},{"class":252,"line":9257},[15196,15200,15204,15208,15212,15216,15221,15225],{"type":46,"tag":250,"props":15197,"children":15198},{"style":375},[15199],{"type":52,"value":15121},{"type":46,"tag":250,"props":15201,"children":15202},{"style":274},[15203],{"type":52,"value":15126},{"type":46,"tag":250,"props":15205,"children":15206},{"style":268},[15207],{"type":52,"value":106},{"type":46,"tag":250,"props":15209,"children":15210},{"style":274},[15211],{"type":52,"value":15174},{"type":46,"tag":250,"props":15213,"children":15214},{"style":375},[15215],{"type":52,"value":10041},{"type":46,"tag":250,"props":15217,"children":15218},{"style":262},[15219],{"type":52,"value":15220}," 'organic'",{"type":46,"tag":250,"props":15222,"children":15223},{"style":375},[15224],{"type":52,"value":15149},{"type":46,"tag":250,"props":15226,"children":15227},{"style":262},[15228],{"type":52,"value":15229}," 'organic_search'\n",{"type":46,"tag":250,"props":15231,"children":15232},{"class":252,"line":9266},[15233,15237,15241,15245,15249,15253,15258,15262],{"type":46,"tag":250,"props":15234,"children":15235},{"style":375},[15236],{"type":52,"value":15121},{"type":46,"tag":250,"props":15238,"children":15239},{"style":274},[15240],{"type":52,"value":15126},{"type":46,"tag":250,"props":15242,"children":15243},{"style":268},[15244],{"type":52,"value":106},{"type":46,"tag":250,"props":15246,"children":15247},{"style":274},[15248],{"type":52,"value":15174},{"type":46,"tag":250,"props":15250,"children":15251},{"style":375},[15252],{"type":52,"value":10041},{"type":46,"tag":250,"props":15254,"children":15255},{"style":262},[15256],{"type":52,"value":15257}," 'cpc'",{"type":46,"tag":250,"props":15259,"children":15260},{"style":375},[15261],{"type":52,"value":15149},{"type":46,"tag":250,"props":15263,"children":15264},{"style":262},[15265],{"type":52,"value":15266}," 'paid_search'\n",{"type":46,"tag":250,"props":15268,"children":15269},{"class":252,"line":9275},[15270,15274,15278,15282,15286,15290,15295,15299],{"type":46,"tag":250,"props":15271,"children":15272},{"style":375},[15273],{"type":52,"value":15121},{"type":46,"tag":250,"props":15275,"children":15276},{"style":274},[15277],{"type":52,"value":15126},{"type":46,"tag":250,"props":15279,"children":15280},{"style":268},[15281],{"type":52,"value":106},{"type":46,"tag":250,"props":15283,"children":15284},{"style":274},[15285],{"type":52,"value":15135},{"type":46,"tag":250,"props":15287,"children":15288},{"style":375},[15289],{"type":52,"value":10041},{"type":46,"tag":250,"props":15291,"children":15292},{"style":262},[15293],{"type":52,"value":15294}," '(direct)'",{"type":46,"tag":250,"props":15296,"children":15297},{"style":375},[15298],{"type":52,"value":15149},{"type":46,"tag":250,"props":15300,"children":15301},{"style":262},[15302],{"type":52,"value":15303}," 'direct'\n",{"type":46,"tag":250,"props":15305,"children":15306},{"class":252,"line":9284},[15307,15312],{"type":46,"tag":250,"props":15308,"children":15309},{"style":375},[15310],{"type":52,"value":15311},"        ELSE",{"type":46,"tag":250,"props":15313,"children":15314},{"style":262},[15315],{"type":52,"value":15316}," 'other'\n",{"type":46,"tag":250,"props":15318,"children":15319},{"class":252,"line":9293},[15320,15325,15329],{"type":46,"tag":250,"props":15321,"children":15322},{"style":375},[15323],{"type":52,"value":15324},"    END",{"type":46,"tag":250,"props":15326,"children":15327},{"style":375},[15328],{"type":52,"value":9418},{"type":46,"tag":250,"props":15330,"children":15331},{"style":268},[15332],{"type":52,"value":15333}," channel\n",{"type":46,"tag":250,"props":15335,"children":15336},{"class":252,"line":4121},[15337,15341,15345,15349,15354],{"type":46,"tag":250,"props":15338,"children":15339},{"style":375},[15340],{"type":52,"value":9969},{"type":46,"tag":250,"props":15342,"children":15343},{"style":274},[15344],{"type":52,"value":9974},{"type":46,"tag":250,"props":15346,"children":15347},{"style":268},[15348],{"type":52,"value":106},{"type":46,"tag":250,"props":15350,"children":15351},{"style":274},[15352],{"type":52,"value":15353},"ga4_sessions",{"type":46,"tag":250,"props":15355,"children":15356},{"style":268},[15357],{"type":52,"value":15358}," s\n",{"type":46,"tag":250,"props":15360,"children":15361},{"class":252,"line":9310},[15362,15366,15370,15374,15379],{"type":46,"tag":250,"props":15363,"children":15364},{"style":375},[15365],{"type":52,"value":9077},{"type":46,"tag":250,"props":15367,"children":15368},{"style":274},[15369],{"type":52,"value":9974},{"type":46,"tag":250,"props":15371,"children":15372},{"style":268},[15373],{"type":52,"value":106},{"type":46,"tag":250,"props":15375,"children":15376},{"style":274},[15377],{"type":52,"value":15378},"ga4_events",{"type":46,"tag":250,"props":15380,"children":15381},{"style":268},[15382],{"type":52,"value":15383}," e\n",{"type":46,"tag":250,"props":15385,"children":15386},{"class":252,"line":9319},[15387,15391,15395,15399,15403,15407,15412,15416],{"type":46,"tag":250,"props":15388,"children":15389},{"style":375},[15390],{"type":52,"value":10023},{"type":46,"tag":250,"props":15392,"children":15393},{"style":274},[15394],{"type":52,"value":15126},{"type":46,"tag":250,"props":15396,"children":15397},{"style":268},[15398],{"type":52,"value":106},{"type":46,"tag":250,"props":15400,"children":15401},{"style":274},[15402],{"type":52,"value":13692},{"type":46,"tag":250,"props":15404,"children":15405},{"style":375},[15406],{"type":52,"value":10041},{"type":46,"tag":250,"props":15408,"children":15409},{"style":274},[15410],{"type":52,"value":15411}," e",{"type":46,"tag":250,"props":15413,"children":15414},{"style":268},[15415],{"type":52,"value":106},{"type":46,"tag":250,"props":15417,"children":15418},{"style":274},[15419],{"type":52,"value":7401},{"type":46,"tag":250,"props":15421,"children":15422},{"class":252,"line":9327},[15423,15427,15431,15435,15440,15444],{"type":46,"tag":250,"props":15424,"children":15425},{"style":375},[15426],{"type":52,"value":10064},{"type":46,"tag":250,"props":15428,"children":15429},{"style":274},[15430],{"type":52,"value":15411},{"type":46,"tag":250,"props":15432,"children":15433},{"style":268},[15434],{"type":52,"value":106},{"type":46,"tag":250,"props":15436,"children":15437},{"style":274},[15438],{"type":52,"value":15439},"event_name",{"type":46,"tag":250,"props":15441,"children":15442},{"style":375},[15443],{"type":52,"value":10041},{"type":46,"tag":250,"props":15445,"children":15446},{"style":262},[15447],{"type":52,"value":15448}," 'purchase'\n",{"type":46,"tag":429,"props":15450,"children":15451},{"v-slot:mixpanel":7},[15452,15464],{"type":46,"tag":55,"props":15453,"children":15454},{},[15455,15457,15462],{"type":52,"value":15456},"Mixpanel stores everything as events - there is no separate sessions table. You aggregate session-like metrics from ",{"type":46,"tag":99,"props":15458,"children":15460},{"className":15459},[],[15461],{"type":52,"value":14941},{"type":52,"value":15463}," directly.",{"type":46,"tag":240,"props":15465,"children":15467},{"className":9175,"code":15466,"language":9177,"meta":7,"style":7},"SELECT\n    e.time AS session_raw_date,       -- cast with your warehouse's date function\n    COUNT(*) AS total_sessions,\n    COUNT(CASE WHEN e.is_new_user = true THEN 1 END) AS new_users,\n    COUNT(CASE WHEN e.session_duration > 10 THEN 1 END) AS engaged_sessions,\n    COUNT(CASE WHEN e.event_name = 'purchase' THEN 1 END) AS purchase_events,\n    CASE\n        WHEN e.utm_source = 'facebook' THEN 'paid_ads'\n        WHEN e.utm_medium = 'email' THEN 'email'\n        WHEN e.utm_medium = 'organic' THEN 'organic_search'\n        WHEN e.utm_medium = 'cpc' THEN 'paid_search'\n        ELSE 'other'\n    END AS channel\nFROM raw.mixpanel_events e\nWHERE e.event_name = 'session_start'\nGROUP BY session_raw_date, channel\n",[15468],{"type":46,"tag":99,"props":15469,"children":15470},{"__ignoreMap":7},[15471,15478,15506,15535,15605,15672,15736,15743,15779,15815,15850,15885,15896,15911,15935,15963],{"type":46,"tag":250,"props":15472,"children":15473},{"class":252,"line":23},[15474],{"type":46,"tag":250,"props":15475,"children":15476},{"style":375},[15477],{"type":52,"value":9395},{"type":46,"tag":250,"props":15479,"children":15480},{"class":252,"line":285},[15481,15485,15489,15494,15498,15502],{"type":46,"tag":250,"props":15482,"children":15483},{"style":274},[15484],{"type":52,"value":15087},{"type":46,"tag":250,"props":15486,"children":15487},{"style":268},[15488],{"type":52,"value":106},{"type":46,"tag":250,"props":15490,"children":15491},{"style":274},[15492],{"type":52,"value":15493},"time",{"type":46,"tag":250,"props":15495,"children":15496},{"style":375},[15497],{"type":52,"value":9418},{"type":46,"tag":250,"props":15499,"children":15500},{"style":268},[15501],{"type":52,"value":15009},{"type":46,"tag":250,"props":15503,"children":15504},{"style":9187},[15505],{"type":52,"value":15014},{"type":46,"tag":250,"props":15507,"children":15508},{"class":252,"line":299},[15509,15514,15518,15523,15527,15531],{"type":46,"tag":250,"props":15510,"children":15511},{"style":274},[15512],{"type":52,"value":15513},"    COUNT",{"type":46,"tag":250,"props":15515,"children":15516},{"style":268},[15517],{"type":52,"value":9557},{"type":46,"tag":250,"props":15519,"children":15520},{"style":375},[15521],{"type":52,"value":15522},"*",{"type":46,"tag":250,"props":15524,"children":15525},{"style":268},[15526],{"type":52,"value":10086},{"type":46,"tag":250,"props":15528,"children":15529},{"style":375},[15530],{"type":52,"value":9608},{"type":46,"tag":250,"props":15532,"children":15533},{"style":268},[15534],{"type":52,"value":15039},{"type":46,"tag":250,"props":15536,"children":15537},{"class":252,"line":807},[15538,15542,15546,15550,15555,15559,15563,15568,15572,15577,15582,15587,15592,15596,15600],{"type":46,"tag":250,"props":15539,"children":15540},{"style":274},[15541],{"type":52,"value":15513},{"type":46,"tag":250,"props":15543,"children":15544},{"style":268},[15545],{"type":52,"value":9557},{"type":46,"tag":250,"props":15547,"children":15548},{"style":375},[15549],{"type":52,"value":14960},{"type":46,"tag":250,"props":15551,"children":15552},{"style":375},[15553],{"type":52,"value":15554}," WHEN",{"type":46,"tag":250,"props":15556,"children":15557},{"style":274},[15558],{"type":52,"value":15411},{"type":46,"tag":250,"props":15560,"children":15561},{"style":268},[15562],{"type":52,"value":106},{"type":46,"tag":250,"props":15564,"children":15565},{"style":274},[15566],{"type":52,"value":15567},"is_new_user",{"type":46,"tag":250,"props":15569,"children":15570},{"style":375},[15571],{"type":52,"value":10041},{"type":46,"tag":250,"props":15573,"children":15574},{"style":268},[15575],{"type":52,"value":15576}," true ",{"type":46,"tag":250,"props":15578,"children":15579},{"style":375},[15580],{"type":52,"value":15581},"THEN",{"type":46,"tag":250,"props":15583,"children":15584},{"style":274},[15585],{"type":52,"value":15586}," 1",{"type":46,"tag":250,"props":15588,"children":15589},{"style":375},[15590],{"type":52,"value":15591}," END",{"type":46,"tag":250,"props":15593,"children":15594},{"style":268},[15595],{"type":52,"value":10086},{"type":46,"tag":250,"props":15597,"children":15598},{"style":375},[15599],{"type":52,"value":9608},{"type":46,"tag":250,"props":15601,"children":15602},{"style":268},[15603],{"type":52,"value":15604}," new_users,\n",{"type":46,"tag":250,"props":15606,"children":15607},{"class":252,"line":820},[15608,15612,15616,15620,15624,15628,15632,15637,15642,15647,15651,15655,15659,15663,15667],{"type":46,"tag":250,"props":15609,"children":15610},{"style":274},[15611],{"type":52,"value":15513},{"type":46,"tag":250,"props":15613,"children":15614},{"style":268},[15615],{"type":52,"value":9557},{"type":46,"tag":250,"props":15617,"children":15618},{"style":375},[15619],{"type":52,"value":14960},{"type":46,"tag":250,"props":15621,"children":15622},{"style":375},[15623],{"type":52,"value":15554},{"type":46,"tag":250,"props":15625,"children":15626},{"style":274},[15627],{"type":52,"value":15411},{"type":46,"tag":250,"props":15629,"children":15630},{"style":268},[15631],{"type":52,"value":106},{"type":46,"tag":250,"props":15633,"children":15634},{"style":274},[15635],{"type":52,"value":15636},"session_duration",{"type":46,"tag":250,"props":15638,"children":15639},{"style":375},[15640],{"type":52,"value":15641}," >",{"type":46,"tag":250,"props":15643,"children":15644},{"style":274},[15645],{"type":52,"value":15646}," 10",{"type":46,"tag":250,"props":15648,"children":15649},{"style":375},[15650],{"type":52,"value":15149},{"type":46,"tag":250,"props":15652,"children":15653},{"style":274},[15654],{"type":52,"value":15586},{"type":46,"tag":250,"props":15656,"children":15657},{"style":375},[15658],{"type":52,"value":15591},{"type":46,"tag":250,"props":15660,"children":15661},{"style":268},[15662],{"type":52,"value":10086},{"type":46,"tag":250,"props":15664,"children":15665},{"style":375},[15666],{"type":52,"value":9608},{"type":46,"tag":250,"props":15668,"children":15669},{"style":268},[15670],{"type":52,"value":15671}," engaged_sessions,\n",{"type":46,"tag":250,"props":15673,"children":15674},{"class":252,"line":844},[15675,15679,15683,15687,15691,15695,15699,15703,15707,15712,15716,15720,15724,15728,15732],{"type":46,"tag":250,"props":15676,"children":15677},{"style":274},[15678],{"type":52,"value":15513},{"type":46,"tag":250,"props":15680,"children":15681},{"style":268},[15682],{"type":52,"value":9557},{"type":46,"tag":250,"props":15684,"children":15685},{"style":375},[15686],{"type":52,"value":14960},{"type":46,"tag":250,"props":15688,"children":15689},{"style":375},[15690],{"type":52,"value":15554},{"type":46,"tag":250,"props":15692,"children":15693},{"style":274},[15694],{"type":52,"value":15411},{"type":46,"tag":250,"props":15696,"children":15697},{"style":268},[15698],{"type":52,"value":106},{"type":46,"tag":250,"props":15700,"children":15701},{"style":274},[15702],{"type":52,"value":15439},{"type":46,"tag":250,"props":15704,"children":15705},{"style":375},[15706],{"type":52,"value":10041},{"type":46,"tag":250,"props":15708,"children":15709},{"style":262},[15710],{"type":52,"value":15711}," 'purchase'",{"type":46,"tag":250,"props":15713,"children":15714},{"style":375},[15715],{"type":52,"value":15149},{"type":46,"tag":250,"props":15717,"children":15718},{"style":274},[15719],{"type":52,"value":15586},{"type":46,"tag":250,"props":15721,"children":15722},{"style":375},[15723],{"type":52,"value":15591},{"type":46,"tag":250,"props":15725,"children":15726},{"style":268},[15727],{"type":52,"value":10086},{"type":46,"tag":250,"props":15729,"children":15730},{"style":375},[15731],{"type":52,"value":9608},{"type":46,"tag":250,"props":15733,"children":15734},{"style":268},[15735],{"type":52,"value":15105},{"type":46,"tag":250,"props":15737,"children":15738},{"class":252,"line":862},[15739],{"type":46,"tag":250,"props":15740,"children":15741},{"style":375},[15742],{"type":52,"value":15113},{"type":46,"tag":250,"props":15744,"children":15745},{"class":252,"line":11},[15746,15750,15754,15758,15763,15767,15771,15775],{"type":46,"tag":250,"props":15747,"children":15748},{"style":375},[15749],{"type":52,"value":15121},{"type":46,"tag":250,"props":15751,"children":15752},{"style":274},[15753],{"type":52,"value":15411},{"type":46,"tag":250,"props":15755,"children":15756},{"style":268},[15757],{"type":52,"value":106},{"type":46,"tag":250,"props":15759,"children":15760},{"style":274},[15761],{"type":52,"value":15762},"utm_source",{"type":46,"tag":250,"props":15764,"children":15765},{"style":375},[15766],{"type":52,"value":10041},{"type":46,"tag":250,"props":15768,"children":15769},{"style":262},[15770],{"type":52,"value":15144},{"type":46,"tag":250,"props":15772,"children":15773},{"style":375},[15774],{"type":52,"value":15149},{"type":46,"tag":250,"props":15776,"children":15777},{"style":262},[15778],{"type":52,"value":15154},{"type":46,"tag":250,"props":15780,"children":15781},{"class":252,"line":4649},[15782,15786,15790,15794,15799,15803,15807,15811],{"type":46,"tag":250,"props":15783,"children":15784},{"style":375},[15785],{"type":52,"value":15121},{"type":46,"tag":250,"props":15787,"children":15788},{"style":274},[15789],{"type":52,"value":15411},{"type":46,"tag":250,"props":15791,"children":15792},{"style":268},[15793],{"type":52,"value":106},{"type":46,"tag":250,"props":15795,"children":15796},{"style":274},[15797],{"type":52,"value":15798},"utm_medium",{"type":46,"tag":250,"props":15800,"children":15801},{"style":375},[15802],{"type":52,"value":10041},{"type":46,"tag":250,"props":15804,"children":15805},{"style":262},[15806],{"type":52,"value":15183},{"type":46,"tag":250,"props":15808,"children":15809},{"style":375},[15810],{"type":52,"value":15149},{"type":46,"tag":250,"props":15812,"children":15813},{"style":262},[15814],{"type":52,"value":15192},{"type":46,"tag":250,"props":15816,"children":15817},{"class":252,"line":9257},[15818,15822,15826,15830,15834,15838,15842,15846],{"type":46,"tag":250,"props":15819,"children":15820},{"style":375},[15821],{"type":52,"value":15121},{"type":46,"tag":250,"props":15823,"children":15824},{"style":274},[15825],{"type":52,"value":15411},{"type":46,"tag":250,"props":15827,"children":15828},{"style":268},[15829],{"type":52,"value":106},{"type":46,"tag":250,"props":15831,"children":15832},{"style":274},[15833],{"type":52,"value":15798},{"type":46,"tag":250,"props":15835,"children":15836},{"style":375},[15837],{"type":52,"value":10041},{"type":46,"tag":250,"props":15839,"children":15840},{"style":262},[15841],{"type":52,"value":15220},{"type":46,"tag":250,"props":15843,"children":15844},{"style":375},[15845],{"type":52,"value":15149},{"type":46,"tag":250,"props":15847,"children":15848},{"style":262},[15849],{"type":52,"value":15229},{"type":46,"tag":250,"props":15851,"children":15852},{"class":252,"line":9266},[15853,15857,15861,15865,15869,15873,15877,15881],{"type":46,"tag":250,"props":15854,"children":15855},{"style":375},[15856],{"type":52,"value":15121},{"type":46,"tag":250,"props":15858,"children":15859},{"style":274},[15860],{"type":52,"value":15411},{"type":46,"tag":250,"props":15862,"children":15863},{"style":268},[15864],{"type":52,"value":106},{"type":46,"tag":250,"props":15866,"children":15867},{"style":274},[15868],{"type":52,"value":15798},{"type":46,"tag":250,"props":15870,"children":15871},{"style":375},[15872],{"type":52,"value":10041},{"type":46,"tag":250,"props":15874,"children":15875},{"style":262},[15876],{"type":52,"value":15257},{"type":46,"tag":250,"props":15878,"children":15879},{"style":375},[15880],{"type":52,"value":15149},{"type":46,"tag":250,"props":15882,"children":15883},{"style":262},[15884],{"type":52,"value":15266},{"type":46,"tag":250,"props":15886,"children":15887},{"class":252,"line":9275},[15888,15892],{"type":46,"tag":250,"props":15889,"children":15890},{"style":375},[15891],{"type":52,"value":15311},{"type":46,"tag":250,"props":15893,"children":15894},{"style":262},[15895],{"type":52,"value":15316},{"type":46,"tag":250,"props":15897,"children":15898},{"class":252,"line":9284},[15899,15903,15907],{"type":46,"tag":250,"props":15900,"children":15901},{"style":375},[15902],{"type":52,"value":15324},{"type":46,"tag":250,"props":15904,"children":15905},{"style":375},[15906],{"type":52,"value":9418},{"type":46,"tag":250,"props":15908,"children":15909},{"style":268},[15910],{"type":52,"value":15333},{"type":46,"tag":250,"props":15912,"children":15913},{"class":252,"line":9293},[15914,15918,15922,15926,15931],{"type":46,"tag":250,"props":15915,"children":15916},{"style":375},[15917],{"type":52,"value":9969},{"type":46,"tag":250,"props":15919,"children":15920},{"style":274},[15921],{"type":52,"value":9974},{"type":46,"tag":250,"props":15923,"children":15924},{"style":268},[15925],{"type":52,"value":106},{"type":46,"tag":250,"props":15927,"children":15928},{"style":274},[15929],{"type":52,"value":15930},"mixpanel_events",{"type":46,"tag":250,"props":15932,"children":15933},{"style":268},[15934],{"type":52,"value":15383},{"type":46,"tag":250,"props":15936,"children":15937},{"class":252,"line":4121},[15938,15942,15946,15950,15954,15958],{"type":46,"tag":250,"props":15939,"children":15940},{"style":375},[15941],{"type":52,"value":10942},{"type":46,"tag":250,"props":15943,"children":15944},{"style":274},[15945],{"type":52,"value":15411},{"type":46,"tag":250,"props":15947,"children":15948},{"style":268},[15949],{"type":52,"value":106},{"type":46,"tag":250,"props":15951,"children":15952},{"style":274},[15953],{"type":52,"value":15439},{"type":46,"tag":250,"props":15955,"children":15956},{"style":375},[15957],{"type":52,"value":10041},{"type":46,"tag":250,"props":15959,"children":15960},{"style":262},[15961],{"type":52,"value":15962}," 'session_start'\n",{"type":46,"tag":250,"props":15964,"children":15965},{"class":252,"line":9310},[15966,15971],{"type":46,"tag":250,"props":15967,"children":15968},{"style":375},[15969],{"type":52,"value":15970},"GROUP BY",{"type":46,"tag":250,"props":15972,"children":15973},{"style":268},[15974],{"type":52,"value":15975}," session_raw_date, channel\n",{"type":46,"tag":4472,"props":15977,"children":15979},{"id":15978},"warehouse-date-casting",[15980],{"type":52,"value":15981},"Warehouse date casting",{"type":46,"tag":55,"props":15983,"children":15984},{},[15985,15987,15993,15995,16000,16001,16006,16008,16013],{"type":52,"value":15986},"Wrap the source query above in the Bruin asset header and apply the correct date function for your warehouse. Update the ",{"type":46,"tag":99,"props":15988,"children":15990},{"className":15989},[],[15991],{"type":52,"value":15992},"depends:",{"type":52,"value":15994}," list to match the analytics tool you chose above (GA4 uses ",{"type":46,"tag":99,"props":15996,"children":15998},{"className":15997},[],[15999],{"type":52,"value":14926},{"type":52,"value":8572},{"type":46,"tag":99,"props":16002,"children":16004},{"className":16003},[],[16005],{"type":52,"value":14933},{"type":52,"value":16007},"; Mixpanel uses ",{"type":46,"tag":99,"props":16009,"children":16011},{"className":16010},[],[16012],{"type":52,"value":14941},{"type":52,"value":16014},"):",{"type":46,"tag":423,"props":16016,"children":16017},{":variants":425,"group":426},[16018,16181,16340],{"type":46,"tag":429,"props":16019,"children":16020},{"v-slot:clickhouse":7},[16021,16033],{"type":46,"tag":55,"props":16022,"children":16023},{},[16024,16026,16031],{"type":52,"value":16025},"Use ",{"type":46,"tag":99,"props":16027,"children":16029},{"className":16028},[],[16030],{"type":52,"value":13178},{"type":52,"value":16032}," for the date column:",{"type":46,"tag":240,"props":16034,"children":16036},{"className":9175,"code":16035,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_web_sessions\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.ga4_sessions       -- GA4: use raw.ga4_sessions and raw.ga4_events\n  - raw.ga4_events         -- Mixpanel: replace both with raw.mixpanel_events\ncolumns:\n  - name: session_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nSELECT\n    toDate(session_raw_date) AS session_date,\n    -- ... rest of columns from source query above\n",[16037],{"type":46,"tag":99,"props":16038,"children":16039},{"__ignoreMap":7},[16040,16047,16055,16062,16069,16076,16083,16091,16099,16106,16114,16121,16128,16135,16142,16149,16156,16173],{"type":46,"tag":250,"props":16041,"children":16042},{"class":252,"line":23},[16043],{"type":46,"tag":250,"props":16044,"children":16045},{"style":9187},[16046],{"type":52,"value":9190},{"type":46,"tag":250,"props":16048,"children":16049},{"class":252,"line":285},[16050],{"type":46,"tag":250,"props":16051,"children":16052},{"style":9187},[16053],{"type":52,"value":16054},"name: staging.stg_web_sessions\n",{"type":46,"tag":250,"props":16056,"children":16057},{"class":252,"line":299},[16058],{"type":46,"tag":250,"props":16059,"children":16060},{"style":9187},[16061],{"type":52,"value":9206},{"type":46,"tag":250,"props":16063,"children":16064},{"class":252,"line":807},[16065],{"type":46,"tag":250,"props":16066,"children":16067},{"style":9187},[16068],{"type":52,"value":9214},{"type":46,"tag":250,"props":16070,"children":16071},{"class":252,"line":820},[16072],{"type":46,"tag":250,"props":16073,"children":16074},{"style":9187},[16075],{"type":52,"value":9222},{"type":46,"tag":250,"props":16077,"children":16078},{"class":252,"line":844},[16079],{"type":46,"tag":250,"props":16080,"children":16081},{"style":9187},[16082],{"type":52,"value":9230},{"type":46,"tag":250,"props":16084,"children":16085},{"class":252,"line":862},[16086],{"type":46,"tag":250,"props":16087,"children":16088},{"style":9187},[16089],{"type":52,"value":16090},"  - raw.ga4_sessions       -- GA4: use raw.ga4_sessions and raw.ga4_events\n",{"type":46,"tag":250,"props":16092,"children":16093},{"class":252,"line":11},[16094],{"type":46,"tag":250,"props":16095,"children":16096},{"style":9187},[16097],{"type":52,"value":16098},"  - raw.ga4_events         -- Mixpanel: replace both with raw.mixpanel_events\n",{"type":46,"tag":250,"props":16100,"children":16101},{"class":252,"line":4649},[16102],{"type":46,"tag":250,"props":16103,"children":16104},{"style":9187},[16105],{"type":52,"value":9254},{"type":46,"tag":250,"props":16107,"children":16108},{"class":252,"line":9257},[16109],{"type":46,"tag":250,"props":16110,"children":16111},{"style":9187},[16112],{"type":52,"value":16113},"  - name: session_date\n",{"type":46,"tag":250,"props":16115,"children":16116},{"class":252,"line":9266},[16117],{"type":46,"tag":250,"props":16118,"children":16119},{"style":9187},[16120],{"type":52,"value":13288},{"type":46,"tag":250,"props":16122,"children":16123},{"class":252,"line":9275},[16124],{"type":46,"tag":250,"props":16125,"children":16126},{"style":9187},[16127],{"type":52,"value":9281},{"type":46,"tag":250,"props":16129,"children":16130},{"class":252,"line":9284},[16131],{"type":46,"tag":250,"props":16132,"children":16133},{"style":9187},[16134],{"type":52,"value":9290},{"type":46,"tag":250,"props":16136,"children":16137},{"class":252,"line":9293},[16138],{"type":46,"tag":250,"props":16139,"children":16140},{"style":9187},[16141],{"type":52,"value":9377},{"type":46,"tag":250,"props":16143,"children":16144},{"class":252,"line":4121},[16145],{"type":46,"tag":250,"props":16146,"children":16147},{"emptyLinePlaceholder":22},[16148],{"type":52,"value":9386},{"type":46,"tag":250,"props":16150,"children":16151},{"class":252,"line":9310},[16152],{"type":46,"tag":250,"props":16153,"children":16154},{"style":375},[16155],{"type":52,"value":9395},{"type":46,"tag":250,"props":16157,"children":16158},{"class":252,"line":9319},[16159,16164,16168],{"type":46,"tag":250,"props":16160,"children":16161},{"style":268},[16162],{"type":52,"value":16163},"    toDate(session_raw_date) ",{"type":46,"tag":250,"props":16165,"children":16166},{"style":375},[16167],{"type":52,"value":9608},{"type":46,"tag":250,"props":16169,"children":16170},{"style":268},[16171],{"type":52,"value":16172}," session_date,\n",{"type":46,"tag":250,"props":16174,"children":16175},{"class":252,"line":9327},[16176],{"type":46,"tag":250,"props":16177,"children":16178},{"style":9187},[16179],{"type":52,"value":16180},"    -- ... rest of columns from source query above\n",{"type":46,"tag":429,"props":16182,"children":16183},{"v-slot:bigquery":7},[16184,16194],{"type":46,"tag":55,"props":16185,"children":16186},{},[16187,16188,16193],{"type":52,"value":16025},{"type":46,"tag":99,"props":16189,"children":16191},{"className":16190},[],[16192],{"type":52,"value":13186},{"type":52,"value":16032},{"type":46,"tag":240,"props":16195,"children":16197},{"className":9175,"code":16196,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_web_sessions\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.ga4_sessions       -- GA4: use raw.ga4_sessions and raw.ga4_events\n  - raw.ga4_events         -- Mixpanel: replace both with raw.mixpanel_events\ncolumns:\n  - name: session_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nSELECT\n    DATE(session_raw_date) AS session_date,\n    -- ... rest of columns from source query above\n",[16198],{"type":46,"tag":99,"props":16199,"children":16200},{"__ignoreMap":7},[16201,16208,16215,16222,16229,16236,16243,16250,16257,16264,16271,16278,16285,16292,16299,16306,16313,16333],{"type":46,"tag":250,"props":16202,"children":16203},{"class":252,"line":23},[16204],{"type":46,"tag":250,"props":16205,"children":16206},{"style":9187},[16207],{"type":52,"value":9190},{"type":46,"tag":250,"props":16209,"children":16210},{"class":252,"line":285},[16211],{"type":46,"tag":250,"props":16212,"children":16213},{"style":9187},[16214],{"type":52,"value":16054},{"type":46,"tag":250,"props":16216,"children":16217},{"class":252,"line":299},[16218],{"type":46,"tag":250,"props":16219,"children":16220},{"style":9187},[16221],{"type":52,"value":9206},{"type":46,"tag":250,"props":16223,"children":16224},{"class":252,"line":807},[16225],{"type":46,"tag":250,"props":16226,"children":16227},{"style":9187},[16228],{"type":52,"value":9214},{"type":46,"tag":250,"props":16230,"children":16231},{"class":252,"line":820},[16232],{"type":46,"tag":250,"props":16233,"children":16234},{"style":9187},[16235],{"type":52,"value":9222},{"type":46,"tag":250,"props":16237,"children":16238},{"class":252,"line":844},[16239],{"type":46,"tag":250,"props":16240,"children":16241},{"style":9187},[16242],{"type":52,"value":9230},{"type":46,"tag":250,"props":16244,"children":16245},{"class":252,"line":862},[16246],{"type":46,"tag":250,"props":16247,"children":16248},{"style":9187},[16249],{"type":52,"value":16090},{"type":46,"tag":250,"props":16251,"children":16252},{"class":252,"line":11},[16253],{"type":46,"tag":250,"props":16254,"children":16255},{"style":9187},[16256],{"type":52,"value":16098},{"type":46,"tag":250,"props":16258,"children":16259},{"class":252,"line":4649},[16260],{"type":46,"tag":250,"props":16261,"children":16262},{"style":9187},[16263],{"type":52,"value":9254},{"type":46,"tag":250,"props":16265,"children":16266},{"class":252,"line":9257},[16267],{"type":46,"tag":250,"props":16268,"children":16269},{"style":9187},[16270],{"type":52,"value":16113},{"type":46,"tag":250,"props":16272,"children":16273},{"class":252,"line":9266},[16274],{"type":46,"tag":250,"props":16275,"children":16276},{"style":9187},[16277],{"type":52,"value":13288},{"type":46,"tag":250,"props":16279,"children":16280},{"class":252,"line":9275},[16281],{"type":46,"tag":250,"props":16282,"children":16283},{"style":9187},[16284],{"type":52,"value":9281},{"type":46,"tag":250,"props":16286,"children":16287},{"class":252,"line":9284},[16288],{"type":46,"tag":250,"props":16289,"children":16290},{"style":9187},[16291],{"type":52,"value":9290},{"type":46,"tag":250,"props":16293,"children":16294},{"class":252,"line":9293},[16295],{"type":46,"tag":250,"props":16296,"children":16297},{"style":9187},[16298],{"type":52,"value":9377},{"type":46,"tag":250,"props":16300,"children":16301},{"class":252,"line":4121},[16302],{"type":46,"tag":250,"props":16303,"children":16304},{"emptyLinePlaceholder":22},[16305],{"type":52,"value":9386},{"type":46,"tag":250,"props":16307,"children":16308},{"class":252,"line":9310},[16309],{"type":46,"tag":250,"props":16310,"children":16311},{"style":375},[16312],{"type":52,"value":9395},{"type":46,"tag":250,"props":16314,"children":16315},{"class":252,"line":9319},[16316,16320,16325,16329],{"type":46,"tag":250,"props":16317,"children":16318},{"style":375},[16319],{"type":52,"value":13339},{"type":46,"tag":250,"props":16321,"children":16322},{"style":268},[16323],{"type":52,"value":16324},"(session_raw_date) ",{"type":46,"tag":250,"props":16326,"children":16327},{"style":375},[16328],{"type":52,"value":9608},{"type":46,"tag":250,"props":16330,"children":16331},{"style":268},[16332],{"type":52,"value":16172},{"type":46,"tag":250,"props":16334,"children":16335},{"class":252,"line":9327},[16336],{"type":46,"tag":250,"props":16337,"children":16338},{"style":9187},[16339],{"type":52,"value":16180},{"type":46,"tag":429,"props":16341,"children":16342},{"v-slot:snowflake":7},[16343,16353],{"type":46,"tag":55,"props":16344,"children":16345},{},[16346,16347,16352],{"type":52,"value":16025},{"type":46,"tag":99,"props":16348,"children":16350},{"className":16349},[],[16351],{"type":52,"value":13193},{"type":52,"value":16032},{"type":46,"tag":240,"props":16354,"children":16356},{"className":9175,"code":16355,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: staging.stg_web_sessions\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - raw.ga4_sessions       -- GA4: use raw.ga4_sessions and raw.ga4_events\n  - raw.ga4_events         -- Mixpanel: replace both with raw.mixpanel_events\ncolumns:\n  - name: session_date\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nSELECT\n    session_raw_date::DATE AS session_date,\n    -- ... rest of columns from source query above\n",[16357],{"type":46,"tag":99,"props":16358,"children":16359},{"__ignoreMap":7},[16360,16367,16374,16381,16388,16395,16402,16409,16416,16423,16430,16437,16444,16451,16458,16465,16472,16492],{"type":46,"tag":250,"props":16361,"children":16362},{"class":252,"line":23},[16363],{"type":46,"tag":250,"props":16364,"children":16365},{"style":9187},[16366],{"type":52,"value":9190},{"type":46,"tag":250,"props":16368,"children":16369},{"class":252,"line":285},[16370],{"type":46,"tag":250,"props":16371,"children":16372},{"style":9187},[16373],{"type":52,"value":16054},{"type":46,"tag":250,"props":16375,"children":16376},{"class":252,"line":299},[16377],{"type":46,"tag":250,"props":16378,"children":16379},{"style":9187},[16380],{"type":52,"value":9206},{"type":46,"tag":250,"props":16382,"children":16383},{"class":252,"line":807},[16384],{"type":46,"tag":250,"props":16385,"children":16386},{"style":9187},[16387],{"type":52,"value":9214},{"type":46,"tag":250,"props":16389,"children":16390},{"class":252,"line":820},[16391],{"type":46,"tag":250,"props":16392,"children":16393},{"style":9187},[16394],{"type":52,"value":9222},{"type":46,"tag":250,"props":16396,"children":16397},{"class":252,"line":844},[16398],{"type":46,"tag":250,"props":16399,"children":16400},{"style":9187},[16401],{"type":52,"value":9230},{"type":46,"tag":250,"props":16403,"children":16404},{"class":252,"line":862},[16405],{"type":46,"tag":250,"props":16406,"children":16407},{"style":9187},[16408],{"type":52,"value":16090},{"type":46,"tag":250,"props":16410,"children":16411},{"class":252,"line":11},[16412],{"type":46,"tag":250,"props":16413,"children":16414},{"style":9187},[16415],{"type":52,"value":16098},{"type":46,"tag":250,"props":16417,"children":16418},{"class":252,"line":4649},[16419],{"type":46,"tag":250,"props":16420,"children":16421},{"style":9187},[16422],{"type":52,"value":9254},{"type":46,"tag":250,"props":16424,"children":16425},{"class":252,"line":9257},[16426],{"type":46,"tag":250,"props":16427,"children":16428},{"style":9187},[16429],{"type":52,"value":16113},{"type":46,"tag":250,"props":16431,"children":16432},{"class":252,"line":9266},[16433],{"type":46,"tag":250,"props":16434,"children":16435},{"style":9187},[16436],{"type":52,"value":13288},{"type":46,"tag":250,"props":16438,"children":16439},{"class":252,"line":9275},[16440],{"type":46,"tag":250,"props":16441,"children":16442},{"style":9187},[16443],{"type":52,"value":9281},{"type":46,"tag":250,"props":16445,"children":16446},{"class":252,"line":9284},[16447],{"type":46,"tag":250,"props":16448,"children":16449},{"style":9187},[16450],{"type":52,"value":9290},{"type":46,"tag":250,"props":16452,"children":16453},{"class":252,"line":9293},[16454],{"type":46,"tag":250,"props":16455,"children":16456},{"style":9187},[16457],{"type":52,"value":9377},{"type":46,"tag":250,"props":16459,"children":16460},{"class":252,"line":4121},[16461],{"type":46,"tag":250,"props":16462,"children":16463},{"emptyLinePlaceholder":22},[16464],{"type":52,"value":9386},{"type":46,"tag":250,"props":16466,"children":16467},{"class":252,"line":9310},[16468],{"type":46,"tag":250,"props":16469,"children":16470},{"style":375},[16471],{"type":52,"value":9395},{"type":46,"tag":250,"props":16473,"children":16474},{"class":252,"line":9319},[16475,16480,16484,16488],{"type":46,"tag":250,"props":16476,"children":16477},{"style":268},[16478],{"type":52,"value":16479},"    session_raw_date::",{"type":46,"tag":250,"props":16481,"children":16482},{"style":375},[16483],{"type":52,"value":11882},{"type":46,"tag":250,"props":16485,"children":16486},{"style":375},[16487],{"type":52,"value":9418},{"type":46,"tag":250,"props":16489,"children":16490},{"style":268},[16491],{"type":52,"value":16172},{"type":46,"tag":250,"props":16493,"children":16494},{"class":252,"line":9327},[16495],{"type":46,"tag":250,"props":16496,"children":16497},{"style":9187},[16498],{"type":52,"value":16180},{"type":46,"tag":198,"props":16500,"children":16501},{},[16502],{"type":46,"tag":55,"props":16503,"children":16504},{},[16505],{"type":52,"value":16506},"The web sessions query needs both the right source columns (GA4 vs Mixpanel) and the right date cast for your warehouse. Ask Claude Code to generate the combined SQL for your specific stack - it will inspect your raw tables and write the correct query.",{"type":46,"tag":220,"props":16508,"children":16510},{"id":16509},"validate-and-run-the-staging-layer",[16511],{"type":52,"value":16512},"Validate and run the staging layer",{"type":46,"tag":240,"props":16514,"children":16515},{"className":242,"code":1489,"language":244,"meta":7,"style":7},[16516],{"type":46,"tag":99,"props":16517,"children":16518},{"__ignoreMap":7},[16519],{"type":46,"tag":250,"props":16520,"children":16521},{"class":252,"line":23},[16522,16526,16530],{"type":46,"tag":250,"props":16523,"children":16524},{"style":256},[16525],{"type":52,"value":305},{"type":46,"tag":250,"props":16527,"children":16528},{"style":262},[16529],{"type":52,"value":1505},{"type":46,"tag":250,"props":16531,"children":16532},{"style":262},[16533],{"type":52,"value":1510},{"type":46,"tag":55,"props":16535,"children":16536},{},[16537],{"type":52,"value":16538},"Fix any errors, then run with the same small date range you used in Step 2:",{"type":46,"tag":240,"props":16540,"children":16541},{"className":242,"code":8519,"language":244,"meta":7,"style":7},[16542],{"type":46,"tag":99,"props":16543,"children":16544},{"__ignoreMap":7},[16545],{"type":46,"tag":250,"props":16546,"children":16547},{"class":252,"line":23},[16548,16552,16556,16560,16564,16568,16572],{"type":46,"tag":250,"props":16549,"children":16550},{"style":256},[16551],{"type":52,"value":305},{"type":46,"tag":250,"props":16553,"children":16554},{"style":262},[16555],{"type":52,"value":8535},{"type":46,"tag":250,"props":16557,"children":16558},{"style":274},[16559],{"type":52,"value":8540},{"type":46,"tag":250,"props":16561,"children":16562},{"style":262},[16563],{"type":52,"value":8545},{"type":46,"tag":250,"props":16565,"children":16566},{"style":274},[16567],{"type":52,"value":8550},{"type":46,"tag":250,"props":16569,"children":16570},{"style":262},[16571],{"type":52,"value":8555},{"type":46,"tag":250,"props":16573,"children":16574},{"style":262},[16575],{"type":52,"value":1510},{"type":46,"tag":55,"props":16577,"children":16578},{},[16579,16581,16585],{"type":52,"value":16580},"Bruin executes ",{"type":46,"tag":88,"props":16582,"children":16583},{"href":161},[16584],{"type":52,"value":164},{"type":52,"value":16586}," in dependency order - ingestors first, then staging. You can also run just one asset to test it:",{"type":46,"tag":240,"props":16588,"children":16590},{"className":242,"code":16589,"language":244,"meta":7,"style":7},"bruin run --start-date 2025-01-01 --end-date 2025-02-01 ecommerce\u002Fassets\u002Fstaging\u002Fstg_orders.sql\n",[16591],{"type":46,"tag":99,"props":16592,"children":16593},{"__ignoreMap":7},[16594],{"type":46,"tag":250,"props":16595,"children":16596},{"class":252,"line":23},[16597,16601,16605,16609,16613,16617,16621],{"type":46,"tag":250,"props":16598,"children":16599},{"style":256},[16600],{"type":52,"value":305},{"type":46,"tag":250,"props":16602,"children":16603},{"style":262},[16604],{"type":52,"value":8535},{"type":46,"tag":250,"props":16606,"children":16607},{"style":274},[16608],{"type":52,"value":8540},{"type":46,"tag":250,"props":16610,"children":16611},{"style":262},[16612],{"type":52,"value":8545},{"type":46,"tag":250,"props":16614,"children":16615},{"style":274},[16616],{"type":52,"value":8550},{"type":46,"tag":250,"props":16618,"children":16619},{"style":262},[16620],{"type":52,"value":8555},{"type":46,"tag":250,"props":16622,"children":16623},{"style":262},[16624],{"type":52,"value":16625}," ecommerce\u002Fassets\u002Fstaging\u002Fstg_orders.sql\n",{"type":46,"tag":220,"props":16627,"children":16629},{"id":16628},"ask-claude-code-to-validate-and-troubleshoot",[16630],{"type":52,"value":16631},"Ask Claude Code to validate and troubleshoot",{"type":46,"tag":55,"props":16633,"children":16634},{},[16635],{"type":52,"value":16636},"After creating the staging assets, ask Claude Code to check everything:",{"type":46,"tag":1434,"props":16638,"children":16639},{},[16640],{"type":46,"tag":55,"props":16641,"children":16642},{},[16643],{"type":52,"value":16644},"Run bruin validate on the project. If there are errors in the staging SQL files, look at the raw table schemas and fix the column names.",{"type":46,"tag":55,"props":16646,"children":16647},{},[16648],{"type":52,"value":16649},"If a query fails at runtime, Claude Code can inspect the error and the actual table data:",{"type":46,"tag":1434,"props":16651,"children":16652},{},[16653],{"type":46,"tag":55,"props":16654,"children":16655},{},[16656],{"type":52,"value":16657},"The stg_customers asset failed. Query the raw.shopify_customers table to check what columns are actually available, and fix the SQL.",{"type":46,"tag":47,"props":16659,"children":16660},{"id":1531},[16661],{"type":52,"value":1534},{"type":46,"tag":72,"props":16663,"children":16664},{},[16665,16675,16708,16718],{"type":46,"tag":76,"props":16666,"children":16667},{},[16668,16673],{"type":46,"tag":80,"props":16669,"children":16670},{},[16671],{"type":52,"value":16672},"5 staging tables",{"type":52,"value":16674}," normalize data from your connected SaaS tools into a consistent format",{"type":46,"tag":76,"props":16676,"children":16677},{},[16678,16685,16686,16692,16693,16699,16700,16706],{"type":46,"tag":80,"props":16679,"children":16680},{},[16681],{"type":46,"tag":88,"props":16682,"children":16683},{"href":161},[16684],{"type":52,"value":8796},{"type":52,"value":11021},{"type":46,"tag":99,"props":16687,"children":16689},{"className":16688},[],[16690],{"type":52,"value":16691},"not_null",{"type":52,"value":151},{"type":46,"tag":99,"props":16694,"children":16696},{"className":16695},[],[16697],{"type":52,"value":16698},"unique",{"type":52,"value":151},{"type":46,"tag":99,"props":16701,"children":16703},{"className":16702},[],[16704],{"type":52,"value":16705},"has_rows",{"type":52,"value":16707},") run automatically after each asset",{"type":46,"tag":76,"props":16709,"children":16710},{},[16711,16716],{"type":46,"tag":80,"props":16712,"children":16713},{},[16714],{"type":52,"value":16715},"Dependencies",{"type":52,"value":16717}," make sure staging assets wait for their source ingestors to finish",{"type":46,"tag":76,"props":16719,"children":16720},{},[16721,16729,16731,16737],{"type":46,"tag":80,"props":16722,"children":16723},{},[16724],{"type":46,"tag":88,"props":16725,"children":16726},{"href":161},[16727],{"type":52,"value":16728},"Materialization",{"type":52,"value":16730}," is set to ",{"type":46,"tag":99,"props":16732,"children":16734},{"className":16733},[],[16735],{"type":52,"value":16736},"table",{"type":52,"value":16738}," - each run rebuilds the staging tables from scratch for consistency",{"type":46,"tag":55,"props":16740,"children":16741},{},[16742,16744,16749],{"type":52,"value":16743},"Your ",{"type":46,"tag":88,"props":16745,"children":16746},{"href":154},[16747],{"type":52,"value":16748},"pipeline",{"type":52,"value":16750}," now has two layers: ingestion and staging. Next, you'll add the report layer on top.",{"type":46,"tag":1541,"props":16752,"children":16753},{},[16754],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":16756},[16757,16758,16759,16774],{"id":49,"depth":285,"text":53},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":16760},[16761,16762,16764,16766,16768,16770,16772,16773],{"id":8870,"depth":299,"text":8873},{"id":9048,"depth":299,"text":16763},"1) Staged orders - stg_orders.sql",{"id":11930,"depth":299,"text":16765},"2) Staged customers - stg_customers.sql",{"id":12747,"depth":299,"text":16767},"3) Staged products - stg_products.sql",{"id":13139,"depth":299,"text":16769},"4) Staged marketing spend - stg_marketing_spend.sql",{"id":14881,"depth":299,"text":16771},"5) Staged web sessions - stg_web_sessions.sql",{"id":16509,"depth":299,"text":16512},{"id":16628,"depth":299,"text":16631},{"id":1531,"depth":285,"text":1534},"content:tutorials:ecommerce-pipeline:data-preparation.md","tutorials\u002Fecommerce-pipeline\u002Fdata-preparation.md","tutorials\u002Fecommerce-pipeline\u002Fdata-preparation",{"_path":16779,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":16780,"description":16781,"date":10,"readingTime":4121,"category":12,"tags":16782,"difficulty":8788,"module":5,"subSteps":22,"step":807,"journeys":16784,"variants":16785,"learnMore":16786,"author":16789,"body":16790,"_type":1560,"_id":30081,"_source":1562,"_file":30082,"_stem":30083,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fbuild-reports","Build Ecommerce Reports","Create report tables for daily revenue, customer cohorts, product performance, marketing ROI, and a unified KPI dashboard.",[14,15,8787,17,18,19,16783,20],"Analytics",[26,27],[17,18,19],[16787,16788],{"label":8793,"url":8794},{"label":8796,"url":8797},{"name":39,"role":40,"image":41},{"type":43,"children":16791,"toc":30061},[16792,16796,16801,16805,16810,16814,16826,16849,16855,16860,16868,16873,16881,16886,16898,16903,16917,18862,18874,18879,18893,21705,21717,21722,21744,21758,21972,21984,21989,22003,25945,25957,25962,25976,29767,29773,29778,29815,29833,29838,29877,29890,29933,29938,29959,29965,29970,29978,29986,29994,29999,30007,30011,30052,30057],{"type":46,"tag":47,"props":16793,"children":16794},{"id":49},[16795],{"type":52,"value":53},{"type":46,"tag":55,"props":16797,"children":16798},{},[16799],{"type":52,"value":16800},"Build five report tables on top of the staging layer: daily revenue, customer cohorts, product performance, marketing ROI, and a unified daily KPI dashboard.",{"type":46,"tag":47,"props":16802,"children":16803},{"id":183},[16804],{"type":52,"value":186},{"type":46,"tag":55,"props":16806,"children":16807},{},[16808],{"type":52,"value":16809},"Staging tables are clean but they're not answers. They tell you \"what happened\" but not \"how is the business doing.\" Report tables compute the metrics teams actually care about - revenue trends, retention rates, ROAS, and the daily numbers that inform decisions.",{"type":46,"tag":47,"props":16811,"children":16812},{"id":215},[16813],{"type":52,"value":218},{"type":46,"tag":55,"props":16815,"children":16816},{},[16817,16818,16824],{"type":52,"value":8835},{"type":46,"tag":99,"props":16819,"children":16821},{"className":16820},[],[16822],{"type":52,"value":16823},"reports\u002F",{"type":52,"value":16825}," subfolder:",{"type":46,"tag":240,"props":16827,"children":16829},{"className":242,"code":16828,"language":244,"meta":7,"style":7},"mkdir -p ecommerce\u002Fassets\u002Freports\n",[16830],{"type":46,"tag":99,"props":16831,"children":16832},{"__ignoreMap":7},[16833],{"type":46,"tag":250,"props":16834,"children":16835},{"class":252,"line":23},[16836,16840,16844],{"type":46,"tag":250,"props":16837,"children":16838},{"style":256},[16839],{"type":52,"value":259},{"type":46,"tag":250,"props":16841,"children":16842},{"style":274},[16843],{"type":52,"value":8862},{"type":46,"tag":250,"props":16845,"children":16846},{"style":262},[16847],{"type":52,"value":16848}," ecommerce\u002Fassets\u002Freports\n",{"type":46,"tag":220,"props":16850,"children":16852},{"id":16851},"let-claude-code-help-with-report-sql",[16853],{"type":52,"value":16854},"Let Claude Code help with report SQL",{"type":46,"tag":55,"props":16856,"children":16857},{},[16858],{"type":52,"value":16859},"Report queries can get complex, especially cohort retention and marketing attribution. You can ask Claude Code to generate any of these:",{"type":46,"tag":1434,"props":16861,"children":16862},{},[16863],{"type":46,"tag":55,"props":16864,"children":16865},{},[16866],{"type":52,"value":16867},"Create a Bruin SQL asset for a daily revenue report. It should read from staging.stg_orders and compute total orders, paid orders, gross and net revenue, AOV, and cancellation rate grouped by day. Add quality checks. Put it in ecommerce\u002Fassets\u002Freports\u002Frpt_daily_revenue.sql.",{"type":46,"tag":55,"props":16869,"children":16870},{},[16871],{"type":52,"value":16872},"For the harder reports:",{"type":46,"tag":1434,"props":16874,"children":16875},{},[16876],{"type":46,"tag":55,"props":16877,"children":16878},{},[16879],{"type":52,"value":16880},"Write a monthly customer cohort retention query using staging.stg_orders and staging.stg_customers. Group by the month of first purchase, compute retention rate and revenue per customer for each month since first order.",{"type":46,"tag":55,"props":16882,"children":16883},{},[16884],{"type":52,"value":16885},"The examples below show what each report should look like. Select the tab that matches your warehouse.",{"type":46,"tag":220,"props":16887,"children":16889},{"id":16888},"_1-daily-revenue-rpt_daily_revenuesql",[16890,16892],{"type":52,"value":16891},"1) Daily revenue - ",{"type":46,"tag":99,"props":16893,"children":16895},{"className":16894},[],[16896],{"type":52,"value":16897},"rpt_daily_revenue.sql",{"type":46,"tag":55,"props":16899,"children":16900},{},[16901],{"type":52,"value":16902},"The most basic ecommerce report: daily revenue, order count, average order value, and cancellation rate.",{"type":46,"tag":55,"props":16904,"children":16905},{},[16906,16907,16916],{"type":52,"value":9155},{"type":46,"tag":80,"props":16908,"children":16909},{},[16910],{"type":46,"tag":99,"props":16911,"children":16913},{"className":16912},[],[16914],{"type":52,"value":16915},"ecommerce\u002Fassets\u002Freports\u002Frpt_daily_revenue.sql",{"type":52,"value":9166},{"type":46,"tag":423,"props":16918,"children":16919},{":variants":425,"group":426},[16920,17468,18133],{"type":46,"tag":429,"props":16921,"children":16922},{"v-slot:clickhouse":7},[16923],{"type":46,"tag":240,"props":16924,"children":16926},{"className":9175,"code":16925,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_revenue\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\ncolumns:\n  - name: order_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM reports.rpt_daily_revenue\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    toDate(order_date) AS order_date,\n    count(*) AS total_orders,\n    countIf(payment_status = 'paid') AS paid_orders,\n    countIf(cancel_reason IS NOT NULL) AS cancelled_orders,\n    sum(order_total) AS gross_revenue,\n    sum(CASE WHEN payment_status = 'paid' THEN order_total ELSE 0 END) AS net_revenue,\n    sum(discount_amount) AS total_discounts,\n    sum(tax_amount) AS total_tax,\n    round(net_revenue \u002F nullIf(paid_orders, 0), 2) AS avg_order_value,\n    round(cancelled_orders \u002F nullIf(total_orders, 0) * 100, 2) AS cancellation_rate\nFROM staging.stg_orders\nGROUP BY toDate(order_date)\nORDER BY order_date\n",[16927],{"type":46,"tag":99,"props":16928,"children":16929},{"__ignoreMap":7},[16930,16937,16945,16952,16959,16966,16973,16981,16988,16995,17002,17009,17016,17023,17030,17037,17045,17052,17059,17066,17073,17089,17118,17148,17174,17196,17264,17285,17306,17360,17422,17443,17455],{"type":46,"tag":250,"props":16931,"children":16932},{"class":252,"line":23},[16933],{"type":46,"tag":250,"props":16934,"children":16935},{"style":9187},[16936],{"type":52,"value":9190},{"type":46,"tag":250,"props":16938,"children":16939},{"class":252,"line":285},[16940],{"type":46,"tag":250,"props":16941,"children":16942},{"style":9187},[16943],{"type":52,"value":16944},"name: reports.rpt_daily_revenue\n",{"type":46,"tag":250,"props":16946,"children":16947},{"class":252,"line":299},[16948],{"type":46,"tag":250,"props":16949,"children":16950},{"style":9187},[16951],{"type":52,"value":9206},{"type":46,"tag":250,"props":16953,"children":16954},{"class":252,"line":807},[16955],{"type":46,"tag":250,"props":16956,"children":16957},{"style":9187},[16958],{"type":52,"value":9214},{"type":46,"tag":250,"props":16960,"children":16961},{"class":252,"line":820},[16962],{"type":46,"tag":250,"props":16963,"children":16964},{"style":9187},[16965],{"type":52,"value":9222},{"type":46,"tag":250,"props":16967,"children":16968},{"class":252,"line":844},[16969],{"type":46,"tag":250,"props":16970,"children":16971},{"style":9187},[16972],{"type":52,"value":9230},{"type":46,"tag":250,"props":16974,"children":16975},{"class":252,"line":862},[16976],{"type":46,"tag":250,"props":16977,"children":16978},{"style":9187},[16979],{"type":52,"value":16980},"  - staging.stg_orders\n",{"type":46,"tag":250,"props":16982,"children":16983},{"class":252,"line":11},[16984],{"type":46,"tag":250,"props":16985,"children":16986},{"style":9187},[16987],{"type":52,"value":9254},{"type":46,"tag":250,"props":16989,"children":16990},{"class":252,"line":4649},[16991],{"type":46,"tag":250,"props":16992,"children":16993},{"style":9187},[16994],{"type":52,"value":9307},{"type":46,"tag":250,"props":16996,"children":16997},{"class":252,"line":9257},[16998],{"type":46,"tag":250,"props":16999,"children":17000},{"style":9187},[17001],{"type":52,"value":13288},{"type":46,"tag":250,"props":17003,"children":17004},{"class":252,"line":9266},[17005],{"type":46,"tag":250,"props":17006,"children":17007},{"style":9187},[17008],{"type":52,"value":9281},{"type":46,"tag":250,"props":17010,"children":17011},{"class":252,"line":9275},[17012],{"type":46,"tag":250,"props":17013,"children":17014},{"style":9187},[17015],{"type":52,"value":9290},{"type":46,"tag":250,"props":17017,"children":17018},{"class":252,"line":9284},[17019],{"type":46,"tag":250,"props":17020,"children":17021},{"style":9187},[17022],{"type":52,"value":9299},{"type":46,"tag":250,"props":17024,"children":17025},{"class":252,"line":9293},[17026],{"type":46,"tag":250,"props":17027,"children":17028},{"style":9187},[17029],{"type":52,"value":9341},{"type":46,"tag":250,"props":17031,"children":17032},{"class":252,"line":4121},[17033],{"type":46,"tag":250,"props":17034,"children":17035},{"style":9187},[17036],{"type":52,"value":9350},{"type":46,"tag":250,"props":17038,"children":17039},{"class":252,"line":9310},[17040],{"type":46,"tag":250,"props":17041,"children":17042},{"style":9187},[17043],{"type":52,"value":17044},"    query: \"SELECT count(*) > 0 FROM reports.rpt_daily_revenue\"\n",{"type":46,"tag":250,"props":17046,"children":17047},{"class":252,"line":9319},[17048],{"type":46,"tag":250,"props":17049,"children":17050},{"style":9187},[17051],{"type":52,"value":9368},{"type":46,"tag":250,"props":17053,"children":17054},{"class":252,"line":9327},[17055],{"type":46,"tag":250,"props":17056,"children":17057},{"style":9187},[17058],{"type":52,"value":9377},{"type":46,"tag":250,"props":17060,"children":17061},{"class":252,"line":9335},[17062],{"type":46,"tag":250,"props":17063,"children":17064},{"emptyLinePlaceholder":22},[17065],{"type":52,"value":9386},{"type":46,"tag":250,"props":17067,"children":17068},{"class":252,"line":9344},[17069],{"type":46,"tag":250,"props":17070,"children":17071},{"style":375},[17072],{"type":52,"value":9395},{"type":46,"tag":250,"props":17074,"children":17075},{"class":252,"line":9353},[17076,17081,17085],{"type":46,"tag":250,"props":17077,"children":17078},{"style":268},[17079],{"type":52,"value":17080},"    toDate(order_date) ",{"type":46,"tag":250,"props":17082,"children":17083},{"style":375},[17084],{"type":52,"value":9608},{"type":46,"tag":250,"props":17086,"children":17087},{"style":268},[17088],{"type":52,"value":9497},{"type":46,"tag":250,"props":17090,"children":17091},{"class":252,"line":9362},[17092,17097,17101,17105,17109,17113],{"type":46,"tag":250,"props":17093,"children":17094},{"style":274},[17095],{"type":52,"value":17096},"    count",{"type":46,"tag":250,"props":17098,"children":17099},{"style":268},[17100],{"type":52,"value":9557},{"type":46,"tag":250,"props":17102,"children":17103},{"style":375},[17104],{"type":52,"value":15522},{"type":46,"tag":250,"props":17106,"children":17107},{"style":268},[17108],{"type":52,"value":10086},{"type":46,"tag":250,"props":17110,"children":17111},{"style":375},[17112],{"type":52,"value":9608},{"type":46,"tag":250,"props":17114,"children":17115},{"style":268},[17116],{"type":52,"value":17117}," total_orders,\n",{"type":46,"tag":250,"props":17119,"children":17120},{"class":252,"line":9371},[17121,17126,17130,17135,17139,17143],{"type":46,"tag":250,"props":17122,"children":17123},{"style":268},[17124],{"type":52,"value":17125},"    countIf(payment_status ",{"type":46,"tag":250,"props":17127,"children":17128},{"style":375},[17129],{"type":52,"value":10091},{"type":46,"tag":250,"props":17131,"children":17132},{"style":262},[17133],{"type":52,"value":17134}," 'paid'",{"type":46,"tag":250,"props":17136,"children":17137},{"style":268},[17138],{"type":52,"value":10086},{"type":46,"tag":250,"props":17140,"children":17141},{"style":375},[17142],{"type":52,"value":9608},{"type":46,"tag":250,"props":17144,"children":17145},{"style":268},[17146],{"type":52,"value":17147}," paid_orders,\n",{"type":46,"tag":250,"props":17149,"children":17150},{"class":252,"line":9380},[17151,17156,17161,17165,17169],{"type":46,"tag":250,"props":17152,"children":17153},{"style":268},[17154],{"type":52,"value":17155},"    countIf(cancel_reason ",{"type":46,"tag":250,"props":17157,"children":17158},{"style":375},[17159],{"type":52,"value":17160},"IS NOT NULL",{"type":46,"tag":250,"props":17162,"children":17163},{"style":268},[17164],{"type":52,"value":10086},{"type":46,"tag":250,"props":17166,"children":17167},{"style":375},[17168],{"type":52,"value":9608},{"type":46,"tag":250,"props":17170,"children":17171},{"style":268},[17172],{"type":52,"value":17173}," cancelled_orders,\n",{"type":46,"tag":250,"props":17175,"children":17176},{"class":252,"line":9389},[17177,17182,17187,17191],{"type":46,"tag":250,"props":17178,"children":17179},{"style":274},[17180],{"type":52,"value":17181},"    sum",{"type":46,"tag":250,"props":17183,"children":17184},{"style":268},[17185],{"type":52,"value":17186},"(order_total) ",{"type":46,"tag":250,"props":17188,"children":17189},{"style":375},[17190],{"type":52,"value":9608},{"type":46,"tag":250,"props":17192,"children":17193},{"style":268},[17194],{"type":52,"value":17195}," gross_revenue,\n",{"type":46,"tag":250,"props":17197,"children":17198},{"class":252,"line":9398},[17199,17203,17207,17211,17215,17220,17224,17228,17232,17237,17242,17247,17251,17255,17259],{"type":46,"tag":250,"props":17200,"children":17201},{"style":274},[17202],{"type":52,"value":17181},{"type":46,"tag":250,"props":17204,"children":17205},{"style":268},[17206],{"type":52,"value":9557},{"type":46,"tag":250,"props":17208,"children":17209},{"style":375},[17210],{"type":52,"value":14960},{"type":46,"tag":250,"props":17212,"children":17213},{"style":375},[17214],{"type":52,"value":15554},{"type":46,"tag":250,"props":17216,"children":17217},{"style":268},[17218],{"type":52,"value":17219}," payment_status ",{"type":46,"tag":250,"props":17221,"children":17222},{"style":375},[17223],{"type":52,"value":10091},{"type":46,"tag":250,"props":17225,"children":17226},{"style":262},[17227],{"type":52,"value":17134},{"type":46,"tag":250,"props":17229,"children":17230},{"style":375},[17231],{"type":52,"value":15149},{"type":46,"tag":250,"props":17233,"children":17234},{"style":268},[17235],{"type":52,"value":17236}," order_total ",{"type":46,"tag":250,"props":17238,"children":17239},{"style":375},[17240],{"type":52,"value":17241},"ELSE",{"type":46,"tag":250,"props":17243,"children":17244},{"style":274},[17245],{"type":52,"value":17246}," 0",{"type":46,"tag":250,"props":17248,"children":17249},{"style":375},[17250],{"type":52,"value":15591},{"type":46,"tag":250,"props":17252,"children":17253},{"style":268},[17254],{"type":52,"value":10086},{"type":46,"tag":250,"props":17256,"children":17257},{"style":375},[17258],{"type":52,"value":9608},{"type":46,"tag":250,"props":17260,"children":17261},{"style":268},[17262],{"type":52,"value":17263}," net_revenue,\n",{"type":46,"tag":250,"props":17265,"children":17266},{"class":252,"line":9426},[17267,17271,17276,17280],{"type":46,"tag":250,"props":17268,"children":17269},{"style":274},[17270],{"type":52,"value":17181},{"type":46,"tag":250,"props":17272,"children":17273},{"style":268},[17274],{"type":52,"value":17275},"(discount_amount) ",{"type":46,"tag":250,"props":17277,"children":17278},{"style":375},[17279],{"type":52,"value":9608},{"type":46,"tag":250,"props":17281,"children":17282},{"style":268},[17283],{"type":52,"value":17284}," total_discounts,\n",{"type":46,"tag":250,"props":17286,"children":17287},{"class":252,"line":9448},[17288,17292,17297,17301],{"type":46,"tag":250,"props":17289,"children":17290},{"style":274},[17291],{"type":52,"value":17181},{"type":46,"tag":250,"props":17293,"children":17294},{"style":268},[17295],{"type":52,"value":17296},"(tax_amount) ",{"type":46,"tag":250,"props":17298,"children":17299},{"style":375},[17300],{"type":52,"value":9608},{"type":46,"tag":250,"props":17302,"children":17303},{"style":268},[17304],{"type":52,"value":17305}," total_tax,\n",{"type":46,"tag":250,"props":17307,"children":17308},{"class":252,"line":9474},[17309,17314,17319,17324,17329,17334,17338,17343,17347,17351,17355],{"type":46,"tag":250,"props":17310,"children":17311},{"style":274},[17312],{"type":52,"value":17313},"    round",{"type":46,"tag":250,"props":17315,"children":17316},{"style":268},[17317],{"type":52,"value":17318},"(net_revenue ",{"type":46,"tag":250,"props":17320,"children":17321},{"style":375},[17322],{"type":52,"value":17323},"\u002F",{"type":46,"tag":250,"props":17325,"children":17326},{"style":274},[17327],{"type":52,"value":17328}," nullIf",{"type":46,"tag":250,"props":17330,"children":17331},{"style":268},[17332],{"type":52,"value":17333},"(paid_orders, ",{"type":46,"tag":250,"props":17335,"children":17336},{"style":274},[17337],{"type":52,"value":9899},{"type":46,"tag":250,"props":17339,"children":17340},{"style":268},[17341],{"type":52,"value":17342},"), ",{"type":46,"tag":250,"props":17344,"children":17345},{"style":274},[17346],{"type":52,"value":9598},{"type":46,"tag":250,"props":17348,"children":17349},{"style":268},[17350],{"type":52,"value":10086},{"type":46,"tag":250,"props":17352,"children":17353},{"style":375},[17354],{"type":52,"value":9608},{"type":46,"tag":250,"props":17356,"children":17357},{"style":268},[17358],{"type":52,"value":17359}," avg_order_value,\n",{"type":46,"tag":250,"props":17361,"children":17362},{"class":252,"line":9500},[17363,17367,17372,17376,17380,17385,17389,17393,17397,17401,17405,17409,17413,17417],{"type":46,"tag":250,"props":17364,"children":17365},{"style":274},[17366],{"type":52,"value":17313},{"type":46,"tag":250,"props":17368,"children":17369},{"style":268},[17370],{"type":52,"value":17371},"(cancelled_orders ",{"type":46,"tag":250,"props":17373,"children":17374},{"style":375},[17375],{"type":52,"value":17323},{"type":46,"tag":250,"props":17377,"children":17378},{"style":274},[17379],{"type":52,"value":17328},{"type":46,"tag":250,"props":17381,"children":17382},{"style":268},[17383],{"type":52,"value":17384},"(total_orders, ",{"type":46,"tag":250,"props":17386,"children":17387},{"style":274},[17388],{"type":52,"value":9899},{"type":46,"tag":250,"props":17390,"children":17391},{"style":268},[17392],{"type":52,"value":10086},{"type":46,"tag":250,"props":17394,"children":17395},{"style":375},[17396],{"type":52,"value":15522},{"type":46,"tag":250,"props":17398,"children":17399},{"style":274},[17400],{"type":52,"value":9890},{"type":46,"tag":250,"props":17402,"children":17403},{"style":268},[17404],{"type":52,"value":151},{"type":46,"tag":250,"props":17406,"children":17407},{"style":274},[17408],{"type":52,"value":9598},{"type":46,"tag":250,"props":17410,"children":17411},{"style":268},[17412],{"type":52,"value":10086},{"type":46,"tag":250,"props":17414,"children":17415},{"style":375},[17416],{"type":52,"value":9608},{"type":46,"tag":250,"props":17418,"children":17419},{"style":268},[17420],{"type":52,"value":17421}," cancellation_rate\n",{"type":46,"tag":250,"props":17423,"children":17424},{"class":252,"line":9525},[17425,17429,17434,17438],{"type":46,"tag":250,"props":17426,"children":17427},{"style":375},[17428],{"type":52,"value":9969},{"type":46,"tag":250,"props":17430,"children":17431},{"style":274},[17432],{"type":52,"value":17433}," staging",{"type":46,"tag":250,"props":17435,"children":17436},{"style":268},[17437],{"type":52,"value":106},{"type":46,"tag":250,"props":17439,"children":17440},{"style":274},[17441],{"type":52,"value":17442},"stg_orders\n",{"type":46,"tag":250,"props":17444,"children":17445},{"class":252,"line":9546},[17446,17450],{"type":46,"tag":250,"props":17447,"children":17448},{"style":375},[17449],{"type":52,"value":15970},{"type":46,"tag":250,"props":17451,"children":17452},{"style":268},[17453],{"type":52,"value":17454}," toDate(order_date)\n",{"type":46,"tag":250,"props":17456,"children":17457},{"class":252,"line":9616},[17458,17463],{"type":46,"tag":250,"props":17459,"children":17460},{"style":375},[17461],{"type":52,"value":17462},"ORDER BY",{"type":46,"tag":250,"props":17464,"children":17465},{"style":268},[17466],{"type":52,"value":17467}," order_date\n",{"type":46,"tag":429,"props":17469,"children":17470},{"v-slot:bigquery":7},[17471],{"type":46,"tag":240,"props":17472,"children":17474},{"className":9175,"code":17473,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_revenue\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\ncolumns:\n  - name: order_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM reports.rpt_daily_revenue\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    DATE(order_date) AS order_date,\n    count(*) AS total_orders,\n    COUNTIF(payment_status = 'paid') AS paid_orders,\n    COUNTIF(cancel_reason IS NOT NULL) AS cancelled_orders,\n    sum(order_total) AS gross_revenue,\n    sum(CASE WHEN payment_status = 'paid' THEN order_total ELSE 0 END) AS net_revenue,\n    sum(discount_amount) AS total_discounts,\n    sum(tax_amount) AS total_tax,\n    round(sum(CASE WHEN payment_status = 'paid' THEN order_total ELSE 0 END) \u002F NULLIF(COUNTIF(payment_status = 'paid'), 0), 2) AS avg_order_value,\n    round(COUNTIF(cancel_reason IS NOT NULL) \u002F NULLIF(count(*), 0) * 100, 2) AS cancellation_rate\nFROM staging.stg_orders o\nWHERE o.financial_status IN ('paid', 'partially_refunded')\nGROUP BY DATE(order_date)\nORDER BY order_date\n",[17475],{"type":46,"tag":99,"props":17476,"children":17477},{"__ignoreMap":7},[17478,17485,17492,17499,17506,17513,17520,17527,17534,17541,17548,17555,17562,17569,17576,17583,17590,17597,17604,17611,17618,17638,17665,17693,17717,17736,17799,17818,17837,17951,18036,18060,18106,18122],{"type":46,"tag":250,"props":17479,"children":17480},{"class":252,"line":23},[17481],{"type":46,"tag":250,"props":17482,"children":17483},{"style":9187},[17484],{"type":52,"value":9190},{"type":46,"tag":250,"props":17486,"children":17487},{"class":252,"line":285},[17488],{"type":46,"tag":250,"props":17489,"children":17490},{"style":9187},[17491],{"type":52,"value":16944},{"type":46,"tag":250,"props":17493,"children":17494},{"class":252,"line":299},[17495],{"type":46,"tag":250,"props":17496,"children":17497},{"style":9187},[17498],{"type":52,"value":9206},{"type":46,"tag":250,"props":17500,"children":17501},{"class":252,"line":807},[17502],{"type":46,"tag":250,"props":17503,"children":17504},{"style":9187},[17505],{"type":52,"value":9214},{"type":46,"tag":250,"props":17507,"children":17508},{"class":252,"line":820},[17509],{"type":46,"tag":250,"props":17510,"children":17511},{"style":9187},[17512],{"type":52,"value":9222},{"type":46,"tag":250,"props":17514,"children":17515},{"class":252,"line":844},[17516],{"type":46,"tag":250,"props":17517,"children":17518},{"style":9187},[17519],{"type":52,"value":9230},{"type":46,"tag":250,"props":17521,"children":17522},{"class":252,"line":862},[17523],{"type":46,"tag":250,"props":17524,"children":17525},{"style":9187},[17526],{"type":52,"value":16980},{"type":46,"tag":250,"props":17528,"children":17529},{"class":252,"line":11},[17530],{"type":46,"tag":250,"props":17531,"children":17532},{"style":9187},[17533],{"type":52,"value":9254},{"type":46,"tag":250,"props":17535,"children":17536},{"class":252,"line":4649},[17537],{"type":46,"tag":250,"props":17538,"children":17539},{"style":9187},[17540],{"type":52,"value":9307},{"type":46,"tag":250,"props":17542,"children":17543},{"class":252,"line":9257},[17544],{"type":46,"tag":250,"props":17545,"children":17546},{"style":9187},[17547],{"type":52,"value":13288},{"type":46,"tag":250,"props":17549,"children":17550},{"class":252,"line":9266},[17551],{"type":46,"tag":250,"props":17552,"children":17553},{"style":9187},[17554],{"type":52,"value":9281},{"type":46,"tag":250,"props":17556,"children":17557},{"class":252,"line":9275},[17558],{"type":46,"tag":250,"props":17559,"children":17560},{"style":9187},[17561],{"type":52,"value":9290},{"type":46,"tag":250,"props":17563,"children":17564},{"class":252,"line":9284},[17565],{"type":46,"tag":250,"props":17566,"children":17567},{"style":9187},[17568],{"type":52,"value":9299},{"type":46,"tag":250,"props":17570,"children":17571},{"class":252,"line":9293},[17572],{"type":46,"tag":250,"props":17573,"children":17574},{"style":9187},[17575],{"type":52,"value":9341},{"type":46,"tag":250,"props":17577,"children":17578},{"class":252,"line":4121},[17579],{"type":46,"tag":250,"props":17580,"children":17581},{"style":9187},[17582],{"type":52,"value":9350},{"type":46,"tag":250,"props":17584,"children":17585},{"class":252,"line":9310},[17586],{"type":46,"tag":250,"props":17587,"children":17588},{"style":9187},[17589],{"type":52,"value":17044},{"type":46,"tag":250,"props":17591,"children":17592},{"class":252,"line":9319},[17593],{"type":46,"tag":250,"props":17594,"children":17595},{"style":9187},[17596],{"type":52,"value":9368},{"type":46,"tag":250,"props":17598,"children":17599},{"class":252,"line":9327},[17600],{"type":46,"tag":250,"props":17601,"children":17602},{"style":9187},[17603],{"type":52,"value":9377},{"type":46,"tag":250,"props":17605,"children":17606},{"class":252,"line":9335},[17607],{"type":46,"tag":250,"props":17608,"children":17609},{"emptyLinePlaceholder":22},[17610],{"type":52,"value":9386},{"type":46,"tag":250,"props":17612,"children":17613},{"class":252,"line":9344},[17614],{"type":46,"tag":250,"props":17615,"children":17616},{"style":375},[17617],{"type":52,"value":9395},{"type":46,"tag":250,"props":17619,"children":17620},{"class":252,"line":9353},[17621,17625,17630,17634],{"type":46,"tag":250,"props":17622,"children":17623},{"style":375},[17624],{"type":52,"value":13339},{"type":46,"tag":250,"props":17626,"children":17627},{"style":268},[17628],{"type":52,"value":17629},"(order_date) ",{"type":46,"tag":250,"props":17631,"children":17632},{"style":375},[17633],{"type":52,"value":9608},{"type":46,"tag":250,"props":17635,"children":17636},{"style":268},[17637],{"type":52,"value":9497},{"type":46,"tag":250,"props":17639,"children":17640},{"class":252,"line":9362},[17641,17645,17649,17653,17657,17661],{"type":46,"tag":250,"props":17642,"children":17643},{"style":274},[17644],{"type":52,"value":17096},{"type":46,"tag":250,"props":17646,"children":17647},{"style":268},[17648],{"type":52,"value":9557},{"type":46,"tag":250,"props":17650,"children":17651},{"style":375},[17652],{"type":52,"value":15522},{"type":46,"tag":250,"props":17654,"children":17655},{"style":268},[17656],{"type":52,"value":10086},{"type":46,"tag":250,"props":17658,"children":17659},{"style":375},[17660],{"type":52,"value":9608},{"type":46,"tag":250,"props":17662,"children":17663},{"style":268},[17664],{"type":52,"value":17117},{"type":46,"tag":250,"props":17666,"children":17667},{"class":252,"line":9371},[17668,17673,17677,17681,17685,17689],{"type":46,"tag":250,"props":17669,"children":17670},{"style":268},[17671],{"type":52,"value":17672},"    COUNTIF(payment_status ",{"type":46,"tag":250,"props":17674,"children":17675},{"style":375},[17676],{"type":52,"value":10091},{"type":46,"tag":250,"props":17678,"children":17679},{"style":262},[17680],{"type":52,"value":17134},{"type":46,"tag":250,"props":17682,"children":17683},{"style":268},[17684],{"type":52,"value":10086},{"type":46,"tag":250,"props":17686,"children":17687},{"style":375},[17688],{"type":52,"value":9608},{"type":46,"tag":250,"props":17690,"children":17691},{"style":268},[17692],{"type":52,"value":17147},{"type":46,"tag":250,"props":17694,"children":17695},{"class":252,"line":9380},[17696,17701,17705,17709,17713],{"type":46,"tag":250,"props":17697,"children":17698},{"style":268},[17699],{"type":52,"value":17700},"    COUNTIF(cancel_reason ",{"type":46,"tag":250,"props":17702,"children":17703},{"style":375},[17704],{"type":52,"value":17160},{"type":46,"tag":250,"props":17706,"children":17707},{"style":268},[17708],{"type":52,"value":10086},{"type":46,"tag":250,"props":17710,"children":17711},{"style":375},[17712],{"type":52,"value":9608},{"type":46,"tag":250,"props":17714,"children":17715},{"style":268},[17716],{"type":52,"value":17173},{"type":46,"tag":250,"props":17718,"children":17719},{"class":252,"line":9389},[17720,17724,17728,17732],{"type":46,"tag":250,"props":17721,"children":17722},{"style":274},[17723],{"type":52,"value":17181},{"type":46,"tag":250,"props":17725,"children":17726},{"style":268},[17727],{"type":52,"value":17186},{"type":46,"tag":250,"props":17729,"children":17730},{"style":375},[17731],{"type":52,"value":9608},{"type":46,"tag":250,"props":17733,"children":17734},{"style":268},[17735],{"type":52,"value":17195},{"type":46,"tag":250,"props":17737,"children":17738},{"class":252,"line":9398},[17739,17743,17747,17751,17755,17759,17763,17767,17771,17775,17779,17783,17787,17791,17795],{"type":46,"tag":250,"props":17740,"children":17741},{"style":274},[17742],{"type":52,"value":17181},{"type":46,"tag":250,"props":17744,"children":17745},{"style":268},[17746],{"type":52,"value":9557},{"type":46,"tag":250,"props":17748,"children":17749},{"style":375},[17750],{"type":52,"value":14960},{"type":46,"tag":250,"props":17752,"children":17753},{"style":375},[17754],{"type":52,"value":15554},{"type":46,"tag":250,"props":17756,"children":17757},{"style":268},[17758],{"type":52,"value":17219},{"type":46,"tag":250,"props":17760,"children":17761},{"style":375},[17762],{"type":52,"value":10091},{"type":46,"tag":250,"props":17764,"children":17765},{"style":262},[17766],{"type":52,"value":17134},{"type":46,"tag":250,"props":17768,"children":17769},{"style":375},[17770],{"type":52,"value":15149},{"type":46,"tag":250,"props":17772,"children":17773},{"style":268},[17774],{"type":52,"value":17236},{"type":46,"tag":250,"props":17776,"children":17777},{"style":375},[17778],{"type":52,"value":17241},{"type":46,"tag":250,"props":17780,"children":17781},{"style":274},[17782],{"type":52,"value":17246},{"type":46,"tag":250,"props":17784,"children":17785},{"style":375},[17786],{"type":52,"value":15591},{"type":46,"tag":250,"props":17788,"children":17789},{"style":268},[17790],{"type":52,"value":10086},{"type":46,"tag":250,"props":17792,"children":17793},{"style":375},[17794],{"type":52,"value":9608},{"type":46,"tag":250,"props":17796,"children":17797},{"style":268},[17798],{"type":52,"value":17263},{"type":46,"tag":250,"props":17800,"children":17801},{"class":252,"line":9426},[17802,17806,17810,17814],{"type":46,"tag":250,"props":17803,"children":17804},{"style":274},[17805],{"type":52,"value":17181},{"type":46,"tag":250,"props":17807,"children":17808},{"style":268},[17809],{"type":52,"value":17275},{"type":46,"tag":250,"props":17811,"children":17812},{"style":375},[17813],{"type":52,"value":9608},{"type":46,"tag":250,"props":17815,"children":17816},{"style":268},[17817],{"type":52,"value":17284},{"type":46,"tag":250,"props":17819,"children":17820},{"class":252,"line":9448},[17821,17825,17829,17833],{"type":46,"tag":250,"props":17822,"children":17823},{"style":274},[17824],{"type":52,"value":17181},{"type":46,"tag":250,"props":17826,"children":17827},{"style":268},[17828],{"type":52,"value":17296},{"type":46,"tag":250,"props":17830,"children":17831},{"style":375},[17832],{"type":52,"value":9608},{"type":46,"tag":250,"props":17834,"children":17835},{"style":268},[17836],{"type":52,"value":17305},{"type":46,"tag":250,"props":17838,"children":17839},{"class":252,"line":9474},[17840,17844,17848,17853,17857,17861,17865,17869,17873,17877,17881,17885,17889,17893,17897,17901,17905,17910,17915,17919,17923,17927,17931,17935,17939,17943,17947],{"type":46,"tag":250,"props":17841,"children":17842},{"style":274},[17843],{"type":52,"value":17313},{"type":46,"tag":250,"props":17845,"children":17846},{"style":268},[17847],{"type":52,"value":9557},{"type":46,"tag":250,"props":17849,"children":17850},{"style":274},[17851],{"type":52,"value":17852},"sum",{"type":46,"tag":250,"props":17854,"children":17855},{"style":268},[17856],{"type":52,"value":9557},{"type":46,"tag":250,"props":17858,"children":17859},{"style":375},[17860],{"type":52,"value":14960},{"type":46,"tag":250,"props":17862,"children":17863},{"style":375},[17864],{"type":52,"value":15554},{"type":46,"tag":250,"props":17866,"children":17867},{"style":268},[17868],{"type":52,"value":17219},{"type":46,"tag":250,"props":17870,"children":17871},{"style":375},[17872],{"type":52,"value":10091},{"type":46,"tag":250,"props":17874,"children":17875},{"style":262},[17876],{"type":52,"value":17134},{"type":46,"tag":250,"props":17878,"children":17879},{"style":375},[17880],{"type":52,"value":15149},{"type":46,"tag":250,"props":17882,"children":17883},{"style":268},[17884],{"type":52,"value":17236},{"type":46,"tag":250,"props":17886,"children":17887},{"style":375},[17888],{"type":52,"value":17241},{"type":46,"tag":250,"props":17890,"children":17891},{"style":274},[17892],{"type":52,"value":17246},{"type":46,"tag":250,"props":17894,"children":17895},{"style":375},[17896],{"type":52,"value":15591},{"type":46,"tag":250,"props":17898,"children":17899},{"style":268},[17900],{"type":52,"value":10086},{"type":46,"tag":250,"props":17902,"children":17903},{"style":375},[17904],{"type":52,"value":17323},{"type":46,"tag":250,"props":17906,"children":17907},{"style":274},[17908],{"type":52,"value":17909}," NULLIF",{"type":46,"tag":250,"props":17911,"children":17912},{"style":268},[17913],{"type":52,"value":17914},"(COUNTIF(payment_status ",{"type":46,"tag":250,"props":17916,"children":17917},{"style":375},[17918],{"type":52,"value":10091},{"type":46,"tag":250,"props":17920,"children":17921},{"style":262},[17922],{"type":52,"value":17134},{"type":46,"tag":250,"props":17924,"children":17925},{"style":268},[17926],{"type":52,"value":17342},{"type":46,"tag":250,"props":17928,"children":17929},{"style":274},[17930],{"type":52,"value":9899},{"type":46,"tag":250,"props":17932,"children":17933},{"style":268},[17934],{"type":52,"value":17342},{"type":46,"tag":250,"props":17936,"children":17937},{"style":274},[17938],{"type":52,"value":9598},{"type":46,"tag":250,"props":17940,"children":17941},{"style":268},[17942],{"type":52,"value":10086},{"type":46,"tag":250,"props":17944,"children":17945},{"style":375},[17946],{"type":52,"value":9608},{"type":46,"tag":250,"props":17948,"children":17949},{"style":268},[17950],{"type":52,"value":17359},{"type":46,"tag":250,"props":17952,"children":17953},{"class":252,"line":9500},[17954,17958,17963,17967,17971,17975,17979,17983,17988,17992,17996,18000,18004,18008,18012,18016,18020,18024,18028,18032],{"type":46,"tag":250,"props":17955,"children":17956},{"style":274},[17957],{"type":52,"value":17313},{"type":46,"tag":250,"props":17959,"children":17960},{"style":268},[17961],{"type":52,"value":17962},"(COUNTIF(cancel_reason ",{"type":46,"tag":250,"props":17964,"children":17965},{"style":375},[17966],{"type":52,"value":17160},{"type":46,"tag":250,"props":17968,"children":17969},{"style":268},[17970],{"type":52,"value":10086},{"type":46,"tag":250,"props":17972,"children":17973},{"style":375},[17974],{"type":52,"value":17323},{"type":46,"tag":250,"props":17976,"children":17977},{"style":274},[17978],{"type":52,"value":17909},{"type":46,"tag":250,"props":17980,"children":17981},{"style":268},[17982],{"type":52,"value":9557},{"type":46,"tag":250,"props":17984,"children":17985},{"style":274},[17986],{"type":52,"value":17987},"count",{"type":46,"tag":250,"props":17989,"children":17990},{"style":268},[17991],{"type":52,"value":9557},{"type":46,"tag":250,"props":17993,"children":17994},{"style":375},[17995],{"type":52,"value":15522},{"type":46,"tag":250,"props":17997,"children":17998},{"style":268},[17999],{"type":52,"value":17342},{"type":46,"tag":250,"props":18001,"children":18002},{"style":274},[18003],{"type":52,"value":9899},{"type":46,"tag":250,"props":18005,"children":18006},{"style":268},[18007],{"type":52,"value":10086},{"type":46,"tag":250,"props":18009,"children":18010},{"style":375},[18011],{"type":52,"value":15522},{"type":46,"tag":250,"props":18013,"children":18014},{"style":274},[18015],{"type":52,"value":9890},{"type":46,"tag":250,"props":18017,"children":18018},{"style":268},[18019],{"type":52,"value":151},{"type":46,"tag":250,"props":18021,"children":18022},{"style":274},[18023],{"type":52,"value":9598},{"type":46,"tag":250,"props":18025,"children":18026},{"style":268},[18027],{"type":52,"value":10086},{"type":46,"tag":250,"props":18029,"children":18030},{"style":375},[18031],{"type":52,"value":9608},{"type":46,"tag":250,"props":18033,"children":18034},{"style":268},[18035],{"type":52,"value":17421},{"type":46,"tag":250,"props":18037,"children":18038},{"class":252,"line":9525},[18039,18043,18047,18051,18056],{"type":46,"tag":250,"props":18040,"children":18041},{"style":375},[18042],{"type":52,"value":9969},{"type":46,"tag":250,"props":18044,"children":18045},{"style":274},[18046],{"type":52,"value":17433},{"type":46,"tag":250,"props":18048,"children":18049},{"style":268},[18050],{"type":52,"value":106},{"type":46,"tag":250,"props":18052,"children":18053},{"style":274},[18054],{"type":52,"value":18055},"stg_orders",{"type":46,"tag":250,"props":18057,"children":18058},{"style":268},[18059],{"type":52,"value":9988},{"type":46,"tag":250,"props":18061,"children":18062},{"class":252,"line":9546},[18063,18067,18071,18075,18079,18084,18088,18093,18097,18102],{"type":46,"tag":250,"props":18064,"children":18065},{"style":375},[18066],{"type":52,"value":10942},{"type":46,"tag":250,"props":18068,"children":18069},{"style":274},[18070],{"type":52,"value":10028},{"type":46,"tag":250,"props":18072,"children":18073},{"style":268},[18074],{"type":52,"value":106},{"type":46,"tag":250,"props":18076,"children":18077},{"style":274},[18078],{"type":52,"value":5157},{"type":46,"tag":250,"props":18080,"children":18081},{"style":375},[18082],{"type":52,"value":18083}," IN",{"type":46,"tag":250,"props":18085,"children":18086},{"style":268},[18087],{"type":52,"value":11021},{"type":46,"tag":250,"props":18089,"children":18090},{"style":262},[18091],{"type":52,"value":18092},"'paid'",{"type":46,"tag":250,"props":18094,"children":18095},{"style":268},[18096],{"type":52,"value":151},{"type":46,"tag":250,"props":18098,"children":18099},{"style":262},[18100],{"type":52,"value":18101},"'partially_refunded'",{"type":46,"tag":250,"props":18103,"children":18104},{"style":268},[18105],{"type":52,"value":10114},{"type":46,"tag":250,"props":18107,"children":18108},{"class":252,"line":9616},[18109,18113,18117],{"type":46,"tag":250,"props":18110,"children":18111},{"style":375},[18112],{"type":52,"value":15970},{"type":46,"tag":250,"props":18114,"children":18115},{"style":375},[18116],{"type":52,"value":10885},{"type":46,"tag":250,"props":18118,"children":18119},{"style":268},[18120],{"type":52,"value":18121},"(order_date)\n",{"type":46,"tag":250,"props":18123,"children":18124},{"class":252,"line":9678},[18125,18129],{"type":46,"tag":250,"props":18126,"children":18127},{"style":375},[18128],{"type":52,"value":17462},{"type":46,"tag":250,"props":18130,"children":18131},{"style":268},[18132],{"type":52,"value":17467},{"type":46,"tag":429,"props":18134,"children":18135},{"v-slot:snowflake":7},[18136],{"type":46,"tag":240,"props":18137,"children":18139},{"className":9175,"code":18138,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_revenue\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\ncolumns:\n  - name: order_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\ncustom_checks:\n  - name: has_rows\n    query: \"SELECT count(*) > 0 FROM reports.rpt_daily_revenue\"\n    value: 1\n@bruin *\u002F\n\nSELECT\n    order_date::DATE AS order_date,\n    count(*) AS total_orders,\n    COUNT(CASE WHEN payment_status = 'paid' THEN 1 END) AS paid_orders,\n    COUNT(CASE WHEN cancel_reason IS NOT NULL THEN 1 END) AS cancelled_orders,\n    sum(order_total) AS gross_revenue,\n    sum(CASE WHEN payment_status = 'paid' THEN order_total ELSE 0 END) AS net_revenue,\n    sum(discount_amount) AS total_discounts,\n    sum(tax_amount) AS total_tax,\n    round(sum(CASE WHEN payment_status = 'paid' THEN order_total ELSE 0 END) \u002F NULLIF(COUNT(CASE WHEN payment_status = 'paid' THEN 1 END), 0), 2) AS avg_order_value,\n    round(COUNT(CASE WHEN cancel_reason IS NOT NULL THEN 1 END) \u002F NULLIF(count(*), 0) * 100, 2) AS cancellation_rate\nFROM staging.stg_orders\nGROUP BY order_date::DATE\nORDER BY order_date\n",[18140],{"type":46,"tag":99,"props":18141,"children":18142},{"__ignoreMap":7},[18143,18150,18157,18164,18171,18178,18185,18192,18199,18206,18213,18220,18227,18234,18241,18248,18255,18262,18269,18276,18283,18303,18330,18385,18437,18456,18519,18538,18557,18701,18816,18835,18851],{"type":46,"tag":250,"props":18144,"children":18145},{"class":252,"line":23},[18146],{"type":46,"tag":250,"props":18147,"children":18148},{"style":9187},[18149],{"type":52,"value":9190},{"type":46,"tag":250,"props":18151,"children":18152},{"class":252,"line":285},[18153],{"type":46,"tag":250,"props":18154,"children":18155},{"style":9187},[18156],{"type":52,"value":16944},{"type":46,"tag":250,"props":18158,"children":18159},{"class":252,"line":299},[18160],{"type":46,"tag":250,"props":18161,"children":18162},{"style":9187},[18163],{"type":52,"value":9206},{"type":46,"tag":250,"props":18165,"children":18166},{"class":252,"line":807},[18167],{"type":46,"tag":250,"props":18168,"children":18169},{"style":9187},[18170],{"type":52,"value":9214},{"type":46,"tag":250,"props":18172,"children":18173},{"class":252,"line":820},[18174],{"type":46,"tag":250,"props":18175,"children":18176},{"style":9187},[18177],{"type":52,"value":9222},{"type":46,"tag":250,"props":18179,"children":18180},{"class":252,"line":844},[18181],{"type":46,"tag":250,"props":18182,"children":18183},{"style":9187},[18184],{"type":52,"value":9230},{"type":46,"tag":250,"props":18186,"children":18187},{"class":252,"line":862},[18188],{"type":46,"tag":250,"props":18189,"children":18190},{"style":9187},[18191],{"type":52,"value":16980},{"type":46,"tag":250,"props":18193,"children":18194},{"class":252,"line":11},[18195],{"type":46,"tag":250,"props":18196,"children":18197},{"style":9187},[18198],{"type":52,"value":9254},{"type":46,"tag":250,"props":18200,"children":18201},{"class":252,"line":4649},[18202],{"type":46,"tag":250,"props":18203,"children":18204},{"style":9187},[18205],{"type":52,"value":9307},{"type":46,"tag":250,"props":18207,"children":18208},{"class":252,"line":9257},[18209],{"type":46,"tag":250,"props":18210,"children":18211},{"style":9187},[18212],{"type":52,"value":13288},{"type":46,"tag":250,"props":18214,"children":18215},{"class":252,"line":9266},[18216],{"type":46,"tag":250,"props":18217,"children":18218},{"style":9187},[18219],{"type":52,"value":9281},{"type":46,"tag":250,"props":18221,"children":18222},{"class":252,"line":9275},[18223],{"type":46,"tag":250,"props":18224,"children":18225},{"style":9187},[18226],{"type":52,"value":9290},{"type":46,"tag":250,"props":18228,"children":18229},{"class":252,"line":9284},[18230],{"type":46,"tag":250,"props":18231,"children":18232},{"style":9187},[18233],{"type":52,"value":9299},{"type":46,"tag":250,"props":18235,"children":18236},{"class":252,"line":9293},[18237],{"type":46,"tag":250,"props":18238,"children":18239},{"style":9187},[18240],{"type":52,"value":9341},{"type":46,"tag":250,"props":18242,"children":18243},{"class":252,"line":4121},[18244],{"type":46,"tag":250,"props":18245,"children":18246},{"style":9187},[18247],{"type":52,"value":9350},{"type":46,"tag":250,"props":18249,"children":18250},{"class":252,"line":9310},[18251],{"type":46,"tag":250,"props":18252,"children":18253},{"style":9187},[18254],{"type":52,"value":17044},{"type":46,"tag":250,"props":18256,"children":18257},{"class":252,"line":9319},[18258],{"type":46,"tag":250,"props":18259,"children":18260},{"style":9187},[18261],{"type":52,"value":9368},{"type":46,"tag":250,"props":18263,"children":18264},{"class":252,"line":9327},[18265],{"type":46,"tag":250,"props":18266,"children":18267},{"style":9187},[18268],{"type":52,"value":9377},{"type":46,"tag":250,"props":18270,"children":18271},{"class":252,"line":9335},[18272],{"type":46,"tag":250,"props":18273,"children":18274},{"emptyLinePlaceholder":22},[18275],{"type":52,"value":9386},{"type":46,"tag":250,"props":18277,"children":18278},{"class":252,"line":9344},[18279],{"type":46,"tag":250,"props":18280,"children":18281},{"style":375},[18282],{"type":52,"value":9395},{"type":46,"tag":250,"props":18284,"children":18285},{"class":252,"line":9353},[18286,18291,18295,18299],{"type":46,"tag":250,"props":18287,"children":18288},{"style":268},[18289],{"type":52,"value":18290},"    order_date::",{"type":46,"tag":250,"props":18292,"children":18293},{"style":375},[18294],{"type":52,"value":11882},{"type":46,"tag":250,"props":18296,"children":18297},{"style":375},[18298],{"type":52,"value":9418},{"type":46,"tag":250,"props":18300,"children":18301},{"style":268},[18302],{"type":52,"value":9497},{"type":46,"tag":250,"props":18304,"children":18305},{"class":252,"line":9362},[18306,18310,18314,18318,18322,18326],{"type":46,"tag":250,"props":18307,"children":18308},{"style":274},[18309],{"type":52,"value":17096},{"type":46,"tag":250,"props":18311,"children":18312},{"style":268},[18313],{"type":52,"value":9557},{"type":46,"tag":250,"props":18315,"children":18316},{"style":375},[18317],{"type":52,"value":15522},{"type":46,"tag":250,"props":18319,"children":18320},{"style":268},[18321],{"type":52,"value":10086},{"type":46,"tag":250,"props":18323,"children":18324},{"style":375},[18325],{"type":52,"value":9608},{"type":46,"tag":250,"props":18327,"children":18328},{"style":268},[18329],{"type":52,"value":17117},{"type":46,"tag":250,"props":18331,"children":18332},{"class":252,"line":9371},[18333,18337,18341,18345,18349,18353,18357,18361,18365,18369,18373,18377,18381],{"type":46,"tag":250,"props":18334,"children":18335},{"style":274},[18336],{"type":52,"value":15513},{"type":46,"tag":250,"props":18338,"children":18339},{"style":268},[18340],{"type":52,"value":9557},{"type":46,"tag":250,"props":18342,"children":18343},{"style":375},[18344],{"type":52,"value":14960},{"type":46,"tag":250,"props":18346,"children":18347},{"style":375},[18348],{"type":52,"value":15554},{"type":46,"tag":250,"props":18350,"children":18351},{"style":268},[18352],{"type":52,"value":17219},{"type":46,"tag":250,"props":18354,"children":18355},{"style":375},[18356],{"type":52,"value":10091},{"type":46,"tag":250,"props":18358,"children":18359},{"style":262},[18360],{"type":52,"value":17134},{"type":46,"tag":250,"props":18362,"children":18363},{"style":375},[18364],{"type":52,"value":15149},{"type":46,"tag":250,"props":18366,"children":18367},{"style":274},[18368],{"type":52,"value":15586},{"type":46,"tag":250,"props":18370,"children":18371},{"style":375},[18372],{"type":52,"value":15591},{"type":46,"tag":250,"props":18374,"children":18375},{"style":268},[18376],{"type":52,"value":10086},{"type":46,"tag":250,"props":18378,"children":18379},{"style":375},[18380],{"type":52,"value":9608},{"type":46,"tag":250,"props":18382,"children":18383},{"style":268},[18384],{"type":52,"value":17147},{"type":46,"tag":250,"props":18386,"children":18387},{"class":252,"line":9380},[18388,18392,18396,18400,18404,18409,18413,18417,18421,18425,18429,18433],{"type":46,"tag":250,"props":18389,"children":18390},{"style":274},[18391],{"type":52,"value":15513},{"type":46,"tag":250,"props":18393,"children":18394},{"style":268},[18395],{"type":52,"value":9557},{"type":46,"tag":250,"props":18397,"children":18398},{"style":375},[18399],{"type":52,"value":14960},{"type":46,"tag":250,"props":18401,"children":18402},{"style":375},[18403],{"type":52,"value":15554},{"type":46,"tag":250,"props":18405,"children":18406},{"style":268},[18407],{"type":52,"value":18408}," cancel_reason ",{"type":46,"tag":250,"props":18410,"children":18411},{"style":375},[18412],{"type":52,"value":17160},{"type":46,"tag":250,"props":18414,"children":18415},{"style":375},[18416],{"type":52,"value":15149},{"type":46,"tag":250,"props":18418,"children":18419},{"style":274},[18420],{"type":52,"value":15586},{"type":46,"tag":250,"props":18422,"children":18423},{"style":375},[18424],{"type":52,"value":15591},{"type":46,"tag":250,"props":18426,"children":18427},{"style":268},[18428],{"type":52,"value":10086},{"type":46,"tag":250,"props":18430,"children":18431},{"style":375},[18432],{"type":52,"value":9608},{"type":46,"tag":250,"props":18434,"children":18435},{"style":268},[18436],{"type":52,"value":17173},{"type":46,"tag":250,"props":18438,"children":18439},{"class":252,"line":9389},[18440,18444,18448,18452],{"type":46,"tag":250,"props":18441,"children":18442},{"style":274},[18443],{"type":52,"value":17181},{"type":46,"tag":250,"props":18445,"children":18446},{"style":268},[18447],{"type":52,"value":17186},{"type":46,"tag":250,"props":18449,"children":18450},{"style":375},[18451],{"type":52,"value":9608},{"type":46,"tag":250,"props":18453,"children":18454},{"style":268},[18455],{"type":52,"value":17195},{"type":46,"tag":250,"props":18457,"children":18458},{"class":252,"line":9398},[18459,18463,18467,18471,18475,18479,18483,18487,18491,18495,18499,18503,18507,18511,18515],{"type":46,"tag":250,"props":18460,"children":18461},{"style":274},[18462],{"type":52,"value":17181},{"type":46,"tag":250,"props":18464,"children":18465},{"style":268},[18466],{"type":52,"value":9557},{"type":46,"tag":250,"props":18468,"children":18469},{"style":375},[18470],{"type":52,"value":14960},{"type":46,"tag":250,"props":18472,"children":18473},{"style":375},[18474],{"type":52,"value":15554},{"type":46,"tag":250,"props":18476,"children":18477},{"style":268},[18478],{"type":52,"value":17219},{"type":46,"tag":250,"props":18480,"children":18481},{"style":375},[18482],{"type":52,"value":10091},{"type":46,"tag":250,"props":18484,"children":18485},{"style":262},[18486],{"type":52,"value":17134},{"type":46,"tag":250,"props":18488,"children":18489},{"style":375},[18490],{"type":52,"value":15149},{"type":46,"tag":250,"props":18492,"children":18493},{"style":268},[18494],{"type":52,"value":17236},{"type":46,"tag":250,"props":18496,"children":18497},{"style":375},[18498],{"type":52,"value":17241},{"type":46,"tag":250,"props":18500,"children":18501},{"style":274},[18502],{"type":52,"value":17246},{"type":46,"tag":250,"props":18504,"children":18505},{"style":375},[18506],{"type":52,"value":15591},{"type":46,"tag":250,"props":18508,"children":18509},{"style":268},[18510],{"type":52,"value":10086},{"type":46,"tag":250,"props":18512,"children":18513},{"style":375},[18514],{"type":52,"value":9608},{"type":46,"tag":250,"props":18516,"children":18517},{"style":268},[18518],{"type":52,"value":17263},{"type":46,"tag":250,"props":18520,"children":18521},{"class":252,"line":9426},[18522,18526,18530,18534],{"type":46,"tag":250,"props":18523,"children":18524},{"style":274},[18525],{"type":52,"value":17181},{"type":46,"tag":250,"props":18527,"children":18528},{"style":268},[18529],{"type":52,"value":17275},{"type":46,"tag":250,"props":18531,"children":18532},{"style":375},[18533],{"type":52,"value":9608},{"type":46,"tag":250,"props":18535,"children":18536},{"style":268},[18537],{"type":52,"value":17284},{"type":46,"tag":250,"props":18539,"children":18540},{"class":252,"line":9448},[18541,18545,18549,18553],{"type":46,"tag":250,"props":18542,"children":18543},{"style":274},[18544],{"type":52,"value":17181},{"type":46,"tag":250,"props":18546,"children":18547},{"style":268},[18548],{"type":52,"value":17296},{"type":46,"tag":250,"props":18550,"children":18551},{"style":375},[18552],{"type":52,"value":9608},{"type":46,"tag":250,"props":18554,"children":18555},{"style":268},[18556],{"type":52,"value":17305},{"type":46,"tag":250,"props":18558,"children":18559},{"class":252,"line":9474},[18560,18564,18568,18572,18576,18580,18584,18588,18592,18596,18600,18604,18608,18612,18616,18620,18624,18628,18632,18637,18641,18645,18649,18653,18657,18661,18665,18669,18673,18677,18681,18685,18689,18693,18697],{"type":46,"tag":250,"props":18561,"children":18562},{"style":274},[18563],{"type":52,"value":17313},{"type":46,"tag":250,"props":18565,"children":18566},{"style":268},[18567],{"type":52,"value":9557},{"type":46,"tag":250,"props":18569,"children":18570},{"style":274},[18571],{"type":52,"value":17852},{"type":46,"tag":250,"props":18573,"children":18574},{"style":268},[18575],{"type":52,"value":9557},{"type":46,"tag":250,"props":18577,"children":18578},{"style":375},[18579],{"type":52,"value":14960},{"type":46,"tag":250,"props":18581,"children":18582},{"style":375},[18583],{"type":52,"value":15554},{"type":46,"tag":250,"props":18585,"children":18586},{"style":268},[18587],{"type":52,"value":17219},{"type":46,"tag":250,"props":18589,"children":18590},{"style":375},[18591],{"type":52,"value":10091},{"type":46,"tag":250,"props":18593,"children":18594},{"style":262},[18595],{"type":52,"value":17134},{"type":46,"tag":250,"props":18597,"children":18598},{"style":375},[18599],{"type":52,"value":15149},{"type":46,"tag":250,"props":18601,"children":18602},{"style":268},[18603],{"type":52,"value":17236},{"type":46,"tag":250,"props":18605,"children":18606},{"style":375},[18607],{"type":52,"value":17241},{"type":46,"tag":250,"props":18609,"children":18610},{"style":274},[18611],{"type":52,"value":17246},{"type":46,"tag":250,"props":18613,"children":18614},{"style":375},[18615],{"type":52,"value":15591},{"type":46,"tag":250,"props":18617,"children":18618},{"style":268},[18619],{"type":52,"value":10086},{"type":46,"tag":250,"props":18621,"children":18622},{"style":375},[18623],{"type":52,"value":17323},{"type":46,"tag":250,"props":18625,"children":18626},{"style":274},[18627],{"type":52,"value":17909},{"type":46,"tag":250,"props":18629,"children":18630},{"style":268},[18631],{"type":52,"value":9557},{"type":46,"tag":250,"props":18633,"children":18634},{"style":274},[18635],{"type":52,"value":18636},"COUNT",{"type":46,"tag":250,"props":18638,"children":18639},{"style":268},[18640],{"type":52,"value":9557},{"type":46,"tag":250,"props":18642,"children":18643},{"style":375},[18644],{"type":52,"value":14960},{"type":46,"tag":250,"props":18646,"children":18647},{"style":375},[18648],{"type":52,"value":15554},{"type":46,"tag":250,"props":18650,"children":18651},{"style":268},[18652],{"type":52,"value":17219},{"type":46,"tag":250,"props":18654,"children":18655},{"style":375},[18656],{"type":52,"value":10091},{"type":46,"tag":250,"props":18658,"children":18659},{"style":262},[18660],{"type":52,"value":17134},{"type":46,"tag":250,"props":18662,"children":18663},{"style":375},[18664],{"type":52,"value":15149},{"type":46,"tag":250,"props":18666,"children":18667},{"style":274},[18668],{"type":52,"value":15586},{"type":46,"tag":250,"props":18670,"children":18671},{"style":375},[18672],{"type":52,"value":15591},{"type":46,"tag":250,"props":18674,"children":18675},{"style":268},[18676],{"type":52,"value":17342},{"type":46,"tag":250,"props":18678,"children":18679},{"style":274},[18680],{"type":52,"value":9899},{"type":46,"tag":250,"props":18682,"children":18683},{"style":268},[18684],{"type":52,"value":17342},{"type":46,"tag":250,"props":18686,"children":18687},{"style":274},[18688],{"type":52,"value":9598},{"type":46,"tag":250,"props":18690,"children":18691},{"style":268},[18692],{"type":52,"value":10086},{"type":46,"tag":250,"props":18694,"children":18695},{"style":375},[18696],{"type":52,"value":9608},{"type":46,"tag":250,"props":18698,"children":18699},{"style":268},[18700],{"type":52,"value":17359},{"type":46,"tag":250,"props":18702,"children":18703},{"class":252,"line":9500},[18704,18708,18712,18716,18720,18724,18728,18732,18736,18740,18744,18748,18752,18756,18760,18764,18768,18772,18776,18780,18784,18788,18792,18796,18800,18804,18808,18812],{"type":46,"tag":250,"props":18705,"children":18706},{"style":274},[18707],{"type":52,"value":17313},{"type":46,"tag":250,"props":18709,"children":18710},{"style":268},[18711],{"type":52,"value":9557},{"type":46,"tag":250,"props":18713,"children":18714},{"style":274},[18715],{"type":52,"value":18636},{"type":46,"tag":250,"props":18717,"children":18718},{"style":268},[18719],{"type":52,"value":9557},{"type":46,"tag":250,"props":18721,"children":18722},{"style":375},[18723],{"type":52,"value":14960},{"type":46,"tag":250,"props":18725,"children":18726},{"style":375},[18727],{"type":52,"value":15554},{"type":46,"tag":250,"props":18729,"children":18730},{"style":268},[18731],{"type":52,"value":18408},{"type":46,"tag":250,"props":18733,"children":18734},{"style":375},[18735],{"type":52,"value":17160},{"type":46,"tag":250,"props":18737,"children":18738},{"style":375},[18739],{"type":52,"value":15149},{"type":46,"tag":250,"props":18741,"children":18742},{"style":274},[18743],{"type":52,"value":15586},{"type":46,"tag":250,"props":18745,"children":18746},{"style":375},[18747],{"type":52,"value":15591},{"type":46,"tag":250,"props":18749,"children":18750},{"style":268},[18751],{"type":52,"value":10086},{"type":46,"tag":250,"props":18753,"children":18754},{"style":375},[18755],{"type":52,"value":17323},{"type":46,"tag":250,"props":18757,"children":18758},{"style":274},[18759],{"type":52,"value":17909},{"type":46,"tag":250,"props":18761,"children":18762},{"style":268},[18763],{"type":52,"value":9557},{"type":46,"tag":250,"props":18765,"children":18766},{"style":274},[18767],{"type":52,"value":17987},{"type":46,"tag":250,"props":18769,"children":18770},{"style":268},[18771],{"type":52,"value":9557},{"type":46,"tag":250,"props":18773,"children":18774},{"style":375},[18775],{"type":52,"value":15522},{"type":46,"tag":250,"props":18777,"children":18778},{"style":268},[18779],{"type":52,"value":17342},{"type":46,"tag":250,"props":18781,"children":18782},{"style":274},[18783],{"type":52,"value":9899},{"type":46,"tag":250,"props":18785,"children":18786},{"style":268},[18787],{"type":52,"value":10086},{"type":46,"tag":250,"props":18789,"children":18790},{"style":375},[18791],{"type":52,"value":15522},{"type":46,"tag":250,"props":18793,"children":18794},{"style":274},[18795],{"type":52,"value":9890},{"type":46,"tag":250,"props":18797,"children":18798},{"style":268},[18799],{"type":52,"value":151},{"type":46,"tag":250,"props":18801,"children":18802},{"style":274},[18803],{"type":52,"value":9598},{"type":46,"tag":250,"props":18805,"children":18806},{"style":268},[18807],{"type":52,"value":10086},{"type":46,"tag":250,"props":18809,"children":18810},{"style":375},[18811],{"type":52,"value":9608},{"type":46,"tag":250,"props":18813,"children":18814},{"style":268},[18815],{"type":52,"value":17421},{"type":46,"tag":250,"props":18817,"children":18818},{"class":252,"line":9525},[18819,18823,18827,18831],{"type":46,"tag":250,"props":18820,"children":18821},{"style":375},[18822],{"type":52,"value":9969},{"type":46,"tag":250,"props":18824,"children":18825},{"style":274},[18826],{"type":52,"value":17433},{"type":46,"tag":250,"props":18828,"children":18829},{"style":268},[18830],{"type":52,"value":106},{"type":46,"tag":250,"props":18832,"children":18833},{"style":274},[18834],{"type":52,"value":17442},{"type":46,"tag":250,"props":18836,"children":18837},{"class":252,"line":9546},[18838,18842,18847],{"type":46,"tag":250,"props":18839,"children":18840},{"style":375},[18841],{"type":52,"value":15970},{"type":46,"tag":250,"props":18843,"children":18844},{"style":268},[18845],{"type":52,"value":18846}," order_date::",{"type":46,"tag":250,"props":18848,"children":18849},{"style":375},[18850],{"type":52,"value":11907},{"type":46,"tag":250,"props":18852,"children":18853},{"class":252,"line":9616},[18854,18858],{"type":46,"tag":250,"props":18855,"children":18856},{"style":375},[18857],{"type":52,"value":17462},{"type":46,"tag":250,"props":18859,"children":18860},{"style":268},[18861],{"type":52,"value":17467},{"type":46,"tag":220,"props":18863,"children":18865},{"id":18864},"_2-customer-cohorts-rpt_customer_cohortssql",[18866,18868],{"type":52,"value":18867},"2) Customer cohorts - ",{"type":46,"tag":99,"props":18869,"children":18871},{"className":18870},[],[18872],{"type":52,"value":18873},"rpt_customer_cohorts.sql",{"type":46,"tag":55,"props":18875,"children":18876},{},[18877],{"type":52,"value":18878},"Monthly cohort analysis showing retention and lifetime value. This tells you if you're acquiring customers who stick around.",{"type":46,"tag":55,"props":18880,"children":18881},{},[18882,18883,18892],{"type":52,"value":9155},{"type":46,"tag":80,"props":18884,"children":18885},{},[18886],{"type":46,"tag":99,"props":18887,"children":18889},{"className":18888},[],[18890],{"type":52,"value":18891},"ecommerce\u002Fassets\u002Freports\u002Frpt_customer_cohorts.sql",{"type":52,"value":9166},{"type":46,"tag":423,"props":18894,"children":18895},{":variants":425,"group":426},[18896,19825,20764],{"type":46,"tag":429,"props":18897,"children":18898},{"v-slot:clickhouse":7},[18899],{"type":46,"tag":240,"props":18900,"children":18902},{"className":9175,"code":18901,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_customer_cohorts\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\n  - staging.stg_customers\ncolumns:\n  - name: cohort_month\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH customer_orders AS (\n    SELECT\n        o.customer_email,\n        toStartOfMonth(c.first_seen_at) AS cohort_month,\n        toStartOfMonth(o.order_date) AS order_month,\n        o.order_total\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n),\ncohort_sizes AS (\n    SELECT\n        cohort_month,\n        count(DISTINCT customer_email) AS cohort_size\n    FROM customer_orders\n    GROUP BY cohort_month\n)\nSELECT\n    co.cohort_month,\n    cs.cohort_size,\n    dateDiff('month', co.cohort_month, co.order_month) AS months_since_first,\n    count(DISTINCT co.customer_email) AS active_customers,\n    round(active_customers \u002F nullIf(cs.cohort_size, 0) * 100, 2) AS retention_rate,\n    sum(co.order_total) AS cohort_revenue,\n    round(cohort_revenue \u002F nullIf(cs.cohort_size, 0), 2) AS revenue_per_customer\nFROM customer_orders co\nINNER JOIN cohort_sizes cs\n    ON co.cohort_month = cs.cohort_month\nGROUP BY co.cohort_month, cs.cohort_size, months_since_first\nORDER BY co.cohort_month, months_since_first\n",[18903],{"type":46,"tag":99,"props":18904,"children":18905},{"__ignoreMap":7},[18906,18913,18921,18928,18935,18942,18949,18956,18964,18971,18979,18986,18993,19000,19007,19014,19036,19044,19065,19099,19132,19148,19172,19197,19234,19264,19272,19288,19295,19303,19334,19346,19359,19366,19373,19394,19415,19479,19520,19598,19635,19700,19712,19725,19762,19802],{"type":46,"tag":250,"props":18907,"children":18908},{"class":252,"line":23},[18909],{"type":46,"tag":250,"props":18910,"children":18911},{"style":9187},[18912],{"type":52,"value":9190},{"type":46,"tag":250,"props":18914,"children":18915},{"class":252,"line":285},[18916],{"type":46,"tag":250,"props":18917,"children":18918},{"style":9187},[18919],{"type":52,"value":18920},"name: reports.rpt_customer_cohorts\n",{"type":46,"tag":250,"props":18922,"children":18923},{"class":252,"line":299},[18924],{"type":46,"tag":250,"props":18925,"children":18926},{"style":9187},[18927],{"type":52,"value":9206},{"type":46,"tag":250,"props":18929,"children":18930},{"class":252,"line":807},[18931],{"type":46,"tag":250,"props":18932,"children":18933},{"style":9187},[18934],{"type":52,"value":9214},{"type":46,"tag":250,"props":18936,"children":18937},{"class":252,"line":820},[18938],{"type":46,"tag":250,"props":18939,"children":18940},{"style":9187},[18941],{"type":52,"value":9222},{"type":46,"tag":250,"props":18943,"children":18944},{"class":252,"line":844},[18945],{"type":46,"tag":250,"props":18946,"children":18947},{"style":9187},[18948],{"type":52,"value":9230},{"type":46,"tag":250,"props":18950,"children":18951},{"class":252,"line":862},[18952],{"type":46,"tag":250,"props":18953,"children":18954},{"style":9187},[18955],{"type":52,"value":16980},{"type":46,"tag":250,"props":18957,"children":18958},{"class":252,"line":11},[18959],{"type":46,"tag":250,"props":18960,"children":18961},{"style":9187},[18962],{"type":52,"value":18963},"  - staging.stg_customers\n",{"type":46,"tag":250,"props":18965,"children":18966},{"class":252,"line":4649},[18967],{"type":46,"tag":250,"props":18968,"children":18969},{"style":9187},[18970],{"type":52,"value":9254},{"type":46,"tag":250,"props":18972,"children":18973},{"class":252,"line":9257},[18974],{"type":46,"tag":250,"props":18975,"children":18976},{"style":9187},[18977],{"type":52,"value":18978},"  - name: cohort_month\n",{"type":46,"tag":250,"props":18980,"children":18981},{"class":252,"line":9266},[18982],{"type":46,"tag":250,"props":18983,"children":18984},{"style":9187},[18985],{"type":52,"value":13288},{"type":46,"tag":250,"props":18987,"children":18988},{"class":252,"line":9275},[18989],{"type":46,"tag":250,"props":18990,"children":18991},{"style":9187},[18992],{"type":52,"value":9281},{"type":46,"tag":250,"props":18994,"children":18995},{"class":252,"line":9284},[18996],{"type":46,"tag":250,"props":18997,"children":18998},{"style":9187},[18999],{"type":52,"value":9290},{"type":46,"tag":250,"props":19001,"children":19002},{"class":252,"line":9293},[19003],{"type":46,"tag":250,"props":19004,"children":19005},{"style":9187},[19006],{"type":52,"value":9377},{"type":46,"tag":250,"props":19008,"children":19009},{"class":252,"line":4121},[19010],{"type":46,"tag":250,"props":19011,"children":19012},{"emptyLinePlaceholder":22},[19013],{"type":52,"value":9386},{"type":46,"tag":250,"props":19015,"children":19016},{"class":252,"line":9310},[19017,19022,19027,19031],{"type":46,"tag":250,"props":19018,"children":19019},{"style":375},[19020],{"type":52,"value":19021},"WITH",{"type":46,"tag":250,"props":19023,"children":19024},{"style":268},[19025],{"type":52,"value":19026}," customer_orders ",{"type":46,"tag":250,"props":19028,"children":19029},{"style":375},[19030],{"type":52,"value":9608},{"type":46,"tag":250,"props":19032,"children":19033},{"style":268},[19034],{"type":52,"value":19035}," (\n",{"type":46,"tag":250,"props":19037,"children":19038},{"class":252,"line":9319},[19039],{"type":46,"tag":250,"props":19040,"children":19041},{"style":375},[19042],{"type":52,"value":19043},"    SELECT\n",{"type":46,"tag":250,"props":19045,"children":19046},{"class":252,"line":9327},[19047,19052,19056,19061],{"type":46,"tag":250,"props":19048,"children":19049},{"style":274},[19050],{"type":52,"value":19051},"        o",{"type":46,"tag":250,"props":19053,"children":19054},{"style":268},[19055],{"type":52,"value":106},{"type":46,"tag":250,"props":19057,"children":19058},{"style":274},[19059],{"type":52,"value":19060},"customer_email",{"type":46,"tag":250,"props":19062,"children":19063},{"style":268},[19064],{"type":52,"value":9445},{"type":46,"tag":250,"props":19066,"children":19067},{"class":252,"line":9335},[19068,19073,19077,19081,19086,19090,19094],{"type":46,"tag":250,"props":19069,"children":19070},{"style":268},[19071],{"type":52,"value":19072},"        toStartOfMonth(",{"type":46,"tag":250,"props":19074,"children":19075},{"style":274},[19076],{"type":52,"value":10100},{"type":46,"tag":250,"props":19078,"children":19079},{"style":268},[19080],{"type":52,"value":106},{"type":46,"tag":250,"props":19082,"children":19083},{"style":274},[19084],{"type":52,"value":19085},"first_seen_at",{"type":46,"tag":250,"props":19087,"children":19088},{"style":268},[19089],{"type":52,"value":10086},{"type":46,"tag":250,"props":19091,"children":19092},{"style":375},[19093],{"type":52,"value":9608},{"type":46,"tag":250,"props":19095,"children":19096},{"style":268},[19097],{"type":52,"value":19098}," cohort_month,\n",{"type":46,"tag":250,"props":19100,"children":19101},{"class":252,"line":9344},[19102,19106,19110,19114,19119,19123,19127],{"type":46,"tag":250,"props":19103,"children":19104},{"style":268},[19105],{"type":52,"value":19072},{"type":46,"tag":250,"props":19107,"children":19108},{"style":274},[19109],{"type":52,"value":9562},{"type":46,"tag":250,"props":19111,"children":19112},{"style":268},[19113],{"type":52,"value":106},{"type":46,"tag":250,"props":19115,"children":19116},{"style":274},[19117],{"type":52,"value":19118},"order_date",{"type":46,"tag":250,"props":19120,"children":19121},{"style":268},[19122],{"type":52,"value":10086},{"type":46,"tag":250,"props":19124,"children":19125},{"style":375},[19126],{"type":52,"value":9608},{"type":46,"tag":250,"props":19128,"children":19129},{"style":268},[19130],{"type":52,"value":19131}," order_month,\n",{"type":46,"tag":250,"props":19133,"children":19134},{"class":252,"line":9353},[19135,19139,19143],{"type":46,"tag":250,"props":19136,"children":19137},{"style":274},[19138],{"type":52,"value":19051},{"type":46,"tag":250,"props":19140,"children":19141},{"style":268},[19142],{"type":52,"value":106},{"type":46,"tag":250,"props":19144,"children":19145},{"style":274},[19146],{"type":52,"value":19147},"order_total\n",{"type":46,"tag":250,"props":19149,"children":19150},{"class":252,"line":9362},[19151,19156,19160,19164,19168],{"type":46,"tag":250,"props":19152,"children":19153},{"style":375},[19154],{"type":52,"value":19155},"    FROM",{"type":46,"tag":250,"props":19157,"children":19158},{"style":274},[19159],{"type":52,"value":17433},{"type":46,"tag":250,"props":19161,"children":19162},{"style":268},[19163],{"type":52,"value":106},{"type":46,"tag":250,"props":19165,"children":19166},{"style":274},[19167],{"type":52,"value":18055},{"type":46,"tag":250,"props":19169,"children":19170},{"style":268},[19171],{"type":52,"value":9988},{"type":46,"tag":250,"props":19173,"children":19174},{"class":252,"line":9371},[19175,19180,19184,19188,19193],{"type":46,"tag":250,"props":19176,"children":19177},{"style":375},[19178],{"type":52,"value":19179},"    INNER JOIN",{"type":46,"tag":250,"props":19181,"children":19182},{"style":274},[19183],{"type":52,"value":17433},{"type":46,"tag":250,"props":19185,"children":19186},{"style":268},[19187],{"type":52,"value":106},{"type":46,"tag":250,"props":19189,"children":19190},{"style":274},[19191],{"type":52,"value":19192},"stg_customers",{"type":46,"tag":250,"props":19194,"children":19195},{"style":268},[19196],{"type":52,"value":10014},{"type":46,"tag":250,"props":19198,"children":19199},{"class":252,"line":9380},[19200,19205,19209,19213,19217,19221,19225,19229],{"type":46,"tag":250,"props":19201,"children":19202},{"style":375},[19203],{"type":52,"value":19204},"        ON",{"type":46,"tag":250,"props":19206,"children":19207},{"style":274},[19208],{"type":52,"value":10028},{"type":46,"tag":250,"props":19210,"children":19211},{"style":268},[19212],{"type":52,"value":106},{"type":46,"tag":250,"props":19214,"children":19215},{"style":274},[19216],{"type":52,"value":19060},{"type":46,"tag":250,"props":19218,"children":19219},{"style":375},[19220],{"type":52,"value":10041},{"type":46,"tag":250,"props":19222,"children":19223},{"style":274},[19224],{"type":52,"value":10046},{"type":46,"tag":250,"props":19226,"children":19227},{"style":268},[19228],{"type":52,"value":106},{"type":46,"tag":250,"props":19230,"children":19231},{"style":274},[19232],{"type":52,"value":19233},"customer_email\n",{"type":46,"tag":250,"props":19235,"children":19236},{"class":252,"line":9389},[19237,19242,19246,19250,19255,19259],{"type":46,"tag":250,"props":19238,"children":19239},{"style":375},[19240],{"type":52,"value":19241},"    WHERE",{"type":46,"tag":250,"props":19243,"children":19244},{"style":274},[19245],{"type":52,"value":10028},{"type":46,"tag":250,"props":19247,"children":19248},{"style":268},[19249],{"type":52,"value":106},{"type":46,"tag":250,"props":19251,"children":19252},{"style":274},[19253],{"type":52,"value":19254},"payment_status",{"type":46,"tag":250,"props":19256,"children":19257},{"style":375},[19258],{"type":52,"value":10041},{"type":46,"tag":250,"props":19260,"children":19261},{"style":262},[19262],{"type":52,"value":19263}," 'paid'\n",{"type":46,"tag":250,"props":19265,"children":19266},{"class":252,"line":9398},[19267],{"type":46,"tag":250,"props":19268,"children":19269},{"style":268},[19270],{"type":52,"value":19271},"),\n",{"type":46,"tag":250,"props":19273,"children":19274},{"class":252,"line":9426},[19275,19280,19284],{"type":46,"tag":250,"props":19276,"children":19277},{"style":268},[19278],{"type":52,"value":19279},"cohort_sizes ",{"type":46,"tag":250,"props":19281,"children":19282},{"style":375},[19283],{"type":52,"value":9608},{"type":46,"tag":250,"props":19285,"children":19286},{"style":268},[19287],{"type":52,"value":19035},{"type":46,"tag":250,"props":19289,"children":19290},{"class":252,"line":9448},[19291],{"type":46,"tag":250,"props":19292,"children":19293},{"style":375},[19294],{"type":52,"value":19043},{"type":46,"tag":250,"props":19296,"children":19297},{"class":252,"line":9474},[19298],{"type":46,"tag":250,"props":19299,"children":19300},{"style":268},[19301],{"type":52,"value":19302},"        cohort_month,\n",{"type":46,"tag":250,"props":19304,"children":19305},{"class":252,"line":9500},[19306,19311,19315,19320,19325,19329],{"type":46,"tag":250,"props":19307,"children":19308},{"style":274},[19309],{"type":52,"value":19310},"        count",{"type":46,"tag":250,"props":19312,"children":19313},{"style":268},[19314],{"type":52,"value":9557},{"type":46,"tag":250,"props":19316,"children":19317},{"style":375},[19318],{"type":52,"value":19319},"DISTINCT",{"type":46,"tag":250,"props":19321,"children":19322},{"style":268},[19323],{"type":52,"value":19324}," customer_email) ",{"type":46,"tag":250,"props":19326,"children":19327},{"style":375},[19328],{"type":52,"value":9608},{"type":46,"tag":250,"props":19330,"children":19331},{"style":268},[19332],{"type":52,"value":19333}," cohort_size\n",{"type":46,"tag":250,"props":19335,"children":19336},{"class":252,"line":9525},[19337,19341],{"type":46,"tag":250,"props":19338,"children":19339},{"style":375},[19340],{"type":52,"value":19155},{"type":46,"tag":250,"props":19342,"children":19343},{"style":268},[19344],{"type":52,"value":19345}," customer_orders\n",{"type":46,"tag":250,"props":19347,"children":19348},{"class":252,"line":9546},[19349,19354],{"type":46,"tag":250,"props":19350,"children":19351},{"style":375},[19352],{"type":52,"value":19353},"    GROUP BY",{"type":46,"tag":250,"props":19355,"children":19356},{"style":268},[19357],{"type":52,"value":19358}," cohort_month\n",{"type":46,"tag":250,"props":19360,"children":19361},{"class":252,"line":9616},[19362],{"type":46,"tag":250,"props":19363,"children":19364},{"style":268},[19365],{"type":52,"value":10114},{"type":46,"tag":250,"props":19367,"children":19368},{"class":252,"line":9678},[19369],{"type":46,"tag":250,"props":19370,"children":19371},{"style":375},[19372],{"type":52,"value":9395},{"type":46,"tag":250,"props":19374,"children":19375},{"class":252,"line":9740},[19376,19381,19385,19390],{"type":46,"tag":250,"props":19377,"children":19378},{"style":274},[19379],{"type":52,"value":19380},"    co",{"type":46,"tag":250,"props":19382,"children":19383},{"style":268},[19384],{"type":52,"value":106},{"type":46,"tag":250,"props":19386,"children":19387},{"style":274},[19388],{"type":52,"value":19389},"cohort_month",{"type":46,"tag":250,"props":19391,"children":19392},{"style":268},[19393],{"type":52,"value":9445},{"type":46,"tag":250,"props":19395,"children":19396},{"class":252,"line":9802},[19397,19402,19406,19411],{"type":46,"tag":250,"props":19398,"children":19399},{"style":274},[19400],{"type":52,"value":19401},"    cs",{"type":46,"tag":250,"props":19403,"children":19404},{"style":268},[19405],{"type":52,"value":106},{"type":46,"tag":250,"props":19407,"children":19408},{"style":274},[19409],{"type":52,"value":19410},"cohort_size",{"type":46,"tag":250,"props":19412,"children":19413},{"style":268},[19414],{"type":52,"value":9445},{"type":46,"tag":250,"props":19416,"children":19417},{"class":252,"line":9823},[19418,19423,19427,19432,19436,19441,19445,19449,19453,19457,19461,19466,19470,19474],{"type":46,"tag":250,"props":19419,"children":19420},{"style":274},[19421],{"type":52,"value":19422},"    dateDiff",{"type":46,"tag":250,"props":19424,"children":19425},{"style":268},[19426],{"type":52,"value":9557},{"type":46,"tag":250,"props":19428,"children":19429},{"style":262},[19430],{"type":52,"value":19431},"'month'",{"type":46,"tag":250,"props":19433,"children":19434},{"style":268},[19435],{"type":52,"value":151},{"type":46,"tag":250,"props":19437,"children":19438},{"style":274},[19439],{"type":52,"value":19440},"co",{"type":46,"tag":250,"props":19442,"children":19443},{"style":268},[19444],{"type":52,"value":106},{"type":46,"tag":250,"props":19446,"children":19447},{"style":274},[19448],{"type":52,"value":19389},{"type":46,"tag":250,"props":19450,"children":19451},{"style":268},[19452],{"type":52,"value":151},{"type":46,"tag":250,"props":19454,"children":19455},{"style":274},[19456],{"type":52,"value":19440},{"type":46,"tag":250,"props":19458,"children":19459},{"style":268},[19460],{"type":52,"value":106},{"type":46,"tag":250,"props":19462,"children":19463},{"style":274},[19464],{"type":52,"value":19465},"order_month",{"type":46,"tag":250,"props":19467,"children":19468},{"style":268},[19469],{"type":52,"value":10086},{"type":46,"tag":250,"props":19471,"children":19472},{"style":375},[19473],{"type":52,"value":9608},{"type":46,"tag":250,"props":19475,"children":19476},{"style":268},[19477],{"type":52,"value":19478}," months_since_first,\n",{"type":46,"tag":250,"props":19480,"children":19481},{"class":252,"line":9844},[19482,19486,19490,19494,19499,19503,19507,19511,19515],{"type":46,"tag":250,"props":19483,"children":19484},{"style":274},[19485],{"type":52,"value":17096},{"type":46,"tag":250,"props":19487,"children":19488},{"style":268},[19489],{"type":52,"value":9557},{"type":46,"tag":250,"props":19491,"children":19492},{"style":375},[19493],{"type":52,"value":19319},{"type":46,"tag":250,"props":19495,"children":19496},{"style":274},[19497],{"type":52,"value":19498}," co",{"type":46,"tag":250,"props":19500,"children":19501},{"style":268},[19502],{"type":52,"value":106},{"type":46,"tag":250,"props":19504,"children":19505},{"style":274},[19506],{"type":52,"value":19060},{"type":46,"tag":250,"props":19508,"children":19509},{"style":268},[19510],{"type":52,"value":10086},{"type":46,"tag":250,"props":19512,"children":19513},{"style":375},[19514],{"type":52,"value":9608},{"type":46,"tag":250,"props":19516,"children":19517},{"style":268},[19518],{"type":52,"value":19519}," active_customers,\n",{"type":46,"tag":250,"props":19521,"children":19522},{"class":252,"line":9865},[19523,19527,19532,19536,19540,19544,19549,19553,19557,19561,19565,19569,19573,19577,19581,19585,19589,19593],{"type":46,"tag":250,"props":19524,"children":19525},{"style":274},[19526],{"type":52,"value":17313},{"type":46,"tag":250,"props":19528,"children":19529},{"style":268},[19530],{"type":52,"value":19531},"(active_customers ",{"type":46,"tag":250,"props":19533,"children":19534},{"style":375},[19535],{"type":52,"value":17323},{"type":46,"tag":250,"props":19537,"children":19538},{"style":274},[19539],{"type":52,"value":17328},{"type":46,"tag":250,"props":19541,"children":19542},{"style":268},[19543],{"type":52,"value":9557},{"type":46,"tag":250,"props":19545,"children":19546},{"style":274},[19547],{"type":52,"value":19548},"cs",{"type":46,"tag":250,"props":19550,"children":19551},{"style":268},[19552],{"type":52,"value":106},{"type":46,"tag":250,"props":19554,"children":19555},{"style":274},[19556],{"type":52,"value":19410},{"type":46,"tag":250,"props":19558,"children":19559},{"style":268},[19560],{"type":52,"value":151},{"type":46,"tag":250,"props":19562,"children":19563},{"style":274},[19564],{"type":52,"value":9899},{"type":46,"tag":250,"props":19566,"children":19567},{"style":268},[19568],{"type":52,"value":10086},{"type":46,"tag":250,"props":19570,"children":19571},{"style":375},[19572],{"type":52,"value":15522},{"type":46,"tag":250,"props":19574,"children":19575},{"style":274},[19576],{"type":52,"value":9890},{"type":46,"tag":250,"props":19578,"children":19579},{"style":268},[19580],{"type":52,"value":151},{"type":46,"tag":250,"props":19582,"children":19583},{"style":274},[19584],{"type":52,"value":9598},{"type":46,"tag":250,"props":19586,"children":19587},{"style":268},[19588],{"type":52,"value":10086},{"type":46,"tag":250,"props":19590,"children":19591},{"style":375},[19592],{"type":52,"value":9608},{"type":46,"tag":250,"props":19594,"children":19595},{"style":268},[19596],{"type":52,"value":19597}," retention_rate,\n",{"type":46,"tag":250,"props":19599,"children":19600},{"class":252,"line":9911},[19601,19605,19609,19613,19617,19622,19626,19630],{"type":46,"tag":250,"props":19602,"children":19603},{"style":274},[19604],{"type":52,"value":17181},{"type":46,"tag":250,"props":19606,"children":19607},{"style":268},[19608],{"type":52,"value":9557},{"type":46,"tag":250,"props":19610,"children":19611},{"style":274},[19612],{"type":52,"value":19440},{"type":46,"tag":250,"props":19614,"children":19615},{"style":268},[19616],{"type":52,"value":106},{"type":46,"tag":250,"props":19618,"children":19619},{"style":274},[19620],{"type":52,"value":19621},"order_total",{"type":46,"tag":250,"props":19623,"children":19624},{"style":268},[19625],{"type":52,"value":10086},{"type":46,"tag":250,"props":19627,"children":19628},{"style":375},[19629],{"type":52,"value":9608},{"type":46,"tag":250,"props":19631,"children":19632},{"style":268},[19633],{"type":52,"value":19634}," cohort_revenue,\n",{"type":46,"tag":250,"props":19636,"children":19637},{"class":252,"line":9937},[19638,19642,19647,19651,19655,19659,19663,19667,19671,19675,19679,19683,19687,19691,19695],{"type":46,"tag":250,"props":19639,"children":19640},{"style":274},[19641],{"type":52,"value":17313},{"type":46,"tag":250,"props":19643,"children":19644},{"style":268},[19645],{"type":52,"value":19646},"(cohort_revenue ",{"type":46,"tag":250,"props":19648,"children":19649},{"style":375},[19650],{"type":52,"value":17323},{"type":46,"tag":250,"props":19652,"children":19653},{"style":274},[19654],{"type":52,"value":17328},{"type":46,"tag":250,"props":19656,"children":19657},{"style":268},[19658],{"type":52,"value":9557},{"type":46,"tag":250,"props":19660,"children":19661},{"style":274},[19662],{"type":52,"value":19548},{"type":46,"tag":250,"props":19664,"children":19665},{"style":268},[19666],{"type":52,"value":106},{"type":46,"tag":250,"props":19668,"children":19669},{"style":274},[19670],{"type":52,"value":19410},{"type":46,"tag":250,"props":19672,"children":19673},{"style":268},[19674],{"type":52,"value":151},{"type":46,"tag":250,"props":19676,"children":19677},{"style":274},[19678],{"type":52,"value":9899},{"type":46,"tag":250,"props":19680,"children":19681},{"style":268},[19682],{"type":52,"value":17342},{"type":46,"tag":250,"props":19684,"children":19685},{"style":274},[19686],{"type":52,"value":9598},{"type":46,"tag":250,"props":19688,"children":19689},{"style":268},[19690],{"type":52,"value":10086},{"type":46,"tag":250,"props":19692,"children":19693},{"style":375},[19694],{"type":52,"value":9608},{"type":46,"tag":250,"props":19696,"children":19697},{"style":268},[19698],{"type":52,"value":19699}," revenue_per_customer\n",{"type":46,"tag":250,"props":19701,"children":19702},{"class":252,"line":9963},[19703,19707],{"type":46,"tag":250,"props":19704,"children":19705},{"style":375},[19706],{"type":52,"value":9969},{"type":46,"tag":250,"props":19708,"children":19709},{"style":268},[19710],{"type":52,"value":19711}," customer_orders co\n",{"type":46,"tag":250,"props":19713,"children":19714},{"class":252,"line":9991},[19715,19720],{"type":46,"tag":250,"props":19716,"children":19717},{"style":375},[19718],{"type":52,"value":19719},"INNER JOIN",{"type":46,"tag":250,"props":19721,"children":19722},{"style":268},[19723],{"type":52,"value":19724}," cohort_sizes cs\n",{"type":46,"tag":250,"props":19726,"children":19727},{"class":252,"line":10017},[19728,19732,19736,19740,19744,19748,19753,19757],{"type":46,"tag":250,"props":19729,"children":19730},{"style":375},[19731],{"type":52,"value":10023},{"type":46,"tag":250,"props":19733,"children":19734},{"style":274},[19735],{"type":52,"value":19498},{"type":46,"tag":250,"props":19737,"children":19738},{"style":268},[19739],{"type":52,"value":106},{"type":46,"tag":250,"props":19741,"children":19742},{"style":274},[19743],{"type":52,"value":19389},{"type":46,"tag":250,"props":19745,"children":19746},{"style":375},[19747],{"type":52,"value":10041},{"type":46,"tag":250,"props":19749,"children":19750},{"style":274},[19751],{"type":52,"value":19752}," cs",{"type":46,"tag":250,"props":19754,"children":19755},{"style":268},[19756],{"type":52,"value":106},{"type":46,"tag":250,"props":19758,"children":19759},{"style":274},[19760],{"type":52,"value":19761},"cohort_month\n",{"type":46,"tag":250,"props":19763,"children":19764},{"class":252,"line":10058},[19765,19769,19773,19777,19781,19785,19789,19793,19797],{"type":46,"tag":250,"props":19766,"children":19767},{"style":375},[19768],{"type":52,"value":15970},{"type":46,"tag":250,"props":19770,"children":19771},{"style":274},[19772],{"type":52,"value":19498},{"type":46,"tag":250,"props":19774,"children":19775},{"style":268},[19776],{"type":52,"value":106},{"type":46,"tag":250,"props":19778,"children":19779},{"style":274},[19780],{"type":52,"value":19389},{"type":46,"tag":250,"props":19782,"children":19783},{"style":268},[19784],{"type":52,"value":151},{"type":46,"tag":250,"props":19786,"children":19787},{"style":274},[19788],{"type":52,"value":19548},{"type":46,"tag":250,"props":19790,"children":19791},{"style":268},[19792],{"type":52,"value":106},{"type":46,"tag":250,"props":19794,"children":19795},{"style":274},[19796],{"type":52,"value":19410},{"type":46,"tag":250,"props":19798,"children":19799},{"style":268},[19800],{"type":52,"value":19801},", months_since_first\n",{"type":46,"tag":250,"props":19803,"children":19804},{"class":252,"line":10936},[19805,19809,19813,19817,19821],{"type":46,"tag":250,"props":19806,"children":19807},{"style":375},[19808],{"type":52,"value":17462},{"type":46,"tag":250,"props":19810,"children":19811},{"style":274},[19812],{"type":52,"value":19498},{"type":46,"tag":250,"props":19814,"children":19815},{"style":268},[19816],{"type":52,"value":106},{"type":46,"tag":250,"props":19818,"children":19819},{"style":274},[19820],{"type":52,"value":19389},{"type":46,"tag":250,"props":19822,"children":19823},{"style":268},[19824],{"type":52,"value":19801},{"type":46,"tag":429,"props":19826,"children":19827},{"v-slot:bigquery":7},[19828],{"type":46,"tag":240,"props":19829,"children":19831},{"className":9175,"code":19830,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_customer_cohorts\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\n  - staging.stg_customers\ncolumns:\n  - name: cohort_month\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH customer_orders AS (\n    SELECT\n        o.customer_email,\n        DATE_TRUNC(c.first_seen_at, MONTH) AS cohort_month,\n        DATE_TRUNC(o.order_date, MONTH) AS order_month,\n        o.order_total\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n),\ncohort_sizes AS (\n    SELECT\n        cohort_month,\n        count(DISTINCT customer_email) AS cohort_size\n    FROM customer_orders\n    GROUP BY cohort_month\n)\nSELECT\n    co.cohort_month,\n    cs.cohort_size,\n    DATE_DIFF(co.order_month, co.cohort_month, MONTH) AS months_since_first,\n    count(DISTINCT co.customer_email) AS active_customers,\n    round(count(DISTINCT co.customer_email) \u002F NULLIF(cs.cohort_size, 0) * 100, 2) AS retention_rate,\n    sum(co.order_total) AS cohort_revenue,\n    round(sum(co.order_total) \u002F NULLIF(cs.cohort_size, 0), 2) AS revenue_per_customer\nFROM customer_orders co\nINNER JOIN cohort_sizes cs\n    ON co.cohort_month = cs.cohort_month\nGROUP BY co.cohort_month, cs.cohort_size, months_since_first\nORDER BY co.cohort_month, months_since_first\n",[19832],{"type":46,"tag":99,"props":19833,"children":19834},{"__ignoreMap":7},[19835,19842,19849,19856,19863,19870,19877,19884,19891,19898,19905,19912,19919,19926,19933,19940,19959,19966,19985,20026,20065,20080,20103,20126,20161,20188,20195,20210,20217,20224,20251,20262,20273,20280,20287,20306,20325,20381,20420,20523,20558,20645,20656,20667,20702,20741],{"type":46,"tag":250,"props":19836,"children":19837},{"class":252,"line":23},[19838],{"type":46,"tag":250,"props":19839,"children":19840},{"style":9187},[19841],{"type":52,"value":9190},{"type":46,"tag":250,"props":19843,"children":19844},{"class":252,"line":285},[19845],{"type":46,"tag":250,"props":19846,"children":19847},{"style":9187},[19848],{"type":52,"value":18920},{"type":46,"tag":250,"props":19850,"children":19851},{"class":252,"line":299},[19852],{"type":46,"tag":250,"props":19853,"children":19854},{"style":9187},[19855],{"type":52,"value":9206},{"type":46,"tag":250,"props":19857,"children":19858},{"class":252,"line":807},[19859],{"type":46,"tag":250,"props":19860,"children":19861},{"style":9187},[19862],{"type":52,"value":9214},{"type":46,"tag":250,"props":19864,"children":19865},{"class":252,"line":820},[19866],{"type":46,"tag":250,"props":19867,"children":19868},{"style":9187},[19869],{"type":52,"value":9222},{"type":46,"tag":250,"props":19871,"children":19872},{"class":252,"line":844},[19873],{"type":46,"tag":250,"props":19874,"children":19875},{"style":9187},[19876],{"type":52,"value":9230},{"type":46,"tag":250,"props":19878,"children":19879},{"class":252,"line":862},[19880],{"type":46,"tag":250,"props":19881,"children":19882},{"style":9187},[19883],{"type":52,"value":16980},{"type":46,"tag":250,"props":19885,"children":19886},{"class":252,"line":11},[19887],{"type":46,"tag":250,"props":19888,"children":19889},{"style":9187},[19890],{"type":52,"value":18963},{"type":46,"tag":250,"props":19892,"children":19893},{"class":252,"line":4649},[19894],{"type":46,"tag":250,"props":19895,"children":19896},{"style":9187},[19897],{"type":52,"value":9254},{"type":46,"tag":250,"props":19899,"children":19900},{"class":252,"line":9257},[19901],{"type":46,"tag":250,"props":19902,"children":19903},{"style":9187},[19904],{"type":52,"value":18978},{"type":46,"tag":250,"props":19906,"children":19907},{"class":252,"line":9266},[19908],{"type":46,"tag":250,"props":19909,"children":19910},{"style":9187},[19911],{"type":52,"value":13288},{"type":46,"tag":250,"props":19913,"children":19914},{"class":252,"line":9275},[19915],{"type":46,"tag":250,"props":19916,"children":19917},{"style":9187},[19918],{"type":52,"value":9281},{"type":46,"tag":250,"props":19920,"children":19921},{"class":252,"line":9284},[19922],{"type":46,"tag":250,"props":19923,"children":19924},{"style":9187},[19925],{"type":52,"value":9290},{"type":46,"tag":250,"props":19927,"children":19928},{"class":252,"line":9293},[19929],{"type":46,"tag":250,"props":19930,"children":19931},{"style":9187},[19932],{"type":52,"value":9377},{"type":46,"tag":250,"props":19934,"children":19935},{"class":252,"line":4121},[19936],{"type":46,"tag":250,"props":19937,"children":19938},{"emptyLinePlaceholder":22},[19939],{"type":52,"value":9386},{"type":46,"tag":250,"props":19941,"children":19942},{"class":252,"line":9310},[19943,19947,19951,19955],{"type":46,"tag":250,"props":19944,"children":19945},{"style":375},[19946],{"type":52,"value":19021},{"type":46,"tag":250,"props":19948,"children":19949},{"style":268},[19950],{"type":52,"value":19026},{"type":46,"tag":250,"props":19952,"children":19953},{"style":375},[19954],{"type":52,"value":9608},{"type":46,"tag":250,"props":19956,"children":19957},{"style":268},[19958],{"type":52,"value":19035},{"type":46,"tag":250,"props":19960,"children":19961},{"class":252,"line":9319},[19962],{"type":46,"tag":250,"props":19963,"children":19964},{"style":375},[19965],{"type":52,"value":19043},{"type":46,"tag":250,"props":19967,"children":19968},{"class":252,"line":9327},[19969,19973,19977,19981],{"type":46,"tag":250,"props":19970,"children":19971},{"style":274},[19972],{"type":52,"value":19051},{"type":46,"tag":250,"props":19974,"children":19975},{"style":268},[19976],{"type":52,"value":106},{"type":46,"tag":250,"props":19978,"children":19979},{"style":274},[19980],{"type":52,"value":19060},{"type":46,"tag":250,"props":19982,"children":19983},{"style":268},[19984],{"type":52,"value":9445},{"type":46,"tag":250,"props":19986,"children":19987},{"class":252,"line":9335},[19988,19993,19997,20001,20005,20009,20014,20018,20022],{"type":46,"tag":250,"props":19989,"children":19990},{"style":268},[19991],{"type":52,"value":19992},"        DATE_TRUNC(",{"type":46,"tag":250,"props":19994,"children":19995},{"style":274},[19996],{"type":52,"value":10100},{"type":46,"tag":250,"props":19998,"children":19999},{"style":268},[20000],{"type":52,"value":106},{"type":46,"tag":250,"props":20002,"children":20003},{"style":274},[20004],{"type":52,"value":19085},{"type":46,"tag":250,"props":20006,"children":20007},{"style":268},[20008],{"type":52,"value":151},{"type":46,"tag":250,"props":20010,"children":20011},{"style":375},[20012],{"type":52,"value":20013},"MONTH",{"type":46,"tag":250,"props":20015,"children":20016},{"style":268},[20017],{"type":52,"value":10086},{"type":46,"tag":250,"props":20019,"children":20020},{"style":375},[20021],{"type":52,"value":9608},{"type":46,"tag":250,"props":20023,"children":20024},{"style":268},[20025],{"type":52,"value":19098},{"type":46,"tag":250,"props":20027,"children":20028},{"class":252,"line":9344},[20029,20033,20037,20041,20045,20049,20053,20057,20061],{"type":46,"tag":250,"props":20030,"children":20031},{"style":268},[20032],{"type":52,"value":19992},{"type":46,"tag":250,"props":20034,"children":20035},{"style":274},[20036],{"type":52,"value":9562},{"type":46,"tag":250,"props":20038,"children":20039},{"style":268},[20040],{"type":52,"value":106},{"type":46,"tag":250,"props":20042,"children":20043},{"style":274},[20044],{"type":52,"value":19118},{"type":46,"tag":250,"props":20046,"children":20047},{"style":268},[20048],{"type":52,"value":151},{"type":46,"tag":250,"props":20050,"children":20051},{"style":375},[20052],{"type":52,"value":20013},{"type":46,"tag":250,"props":20054,"children":20055},{"style":268},[20056],{"type":52,"value":10086},{"type":46,"tag":250,"props":20058,"children":20059},{"style":375},[20060],{"type":52,"value":9608},{"type":46,"tag":250,"props":20062,"children":20063},{"style":268},[20064],{"type":52,"value":19131},{"type":46,"tag":250,"props":20066,"children":20067},{"class":252,"line":9353},[20068,20072,20076],{"type":46,"tag":250,"props":20069,"children":20070},{"style":274},[20071],{"type":52,"value":19051},{"type":46,"tag":250,"props":20073,"children":20074},{"style":268},[20075],{"type":52,"value":106},{"type":46,"tag":250,"props":20077,"children":20078},{"style":274},[20079],{"type":52,"value":19147},{"type":46,"tag":250,"props":20081,"children":20082},{"class":252,"line":9362},[20083,20087,20091,20095,20099],{"type":46,"tag":250,"props":20084,"children":20085},{"style":375},[20086],{"type":52,"value":19155},{"type":46,"tag":250,"props":20088,"children":20089},{"style":274},[20090],{"type":52,"value":17433},{"type":46,"tag":250,"props":20092,"children":20093},{"style":268},[20094],{"type":52,"value":106},{"type":46,"tag":250,"props":20096,"children":20097},{"style":274},[20098],{"type":52,"value":18055},{"type":46,"tag":250,"props":20100,"children":20101},{"style":268},[20102],{"type":52,"value":9988},{"type":46,"tag":250,"props":20104,"children":20105},{"class":252,"line":9371},[20106,20110,20114,20118,20122],{"type":46,"tag":250,"props":20107,"children":20108},{"style":375},[20109],{"type":52,"value":19179},{"type":46,"tag":250,"props":20111,"children":20112},{"style":274},[20113],{"type":52,"value":17433},{"type":46,"tag":250,"props":20115,"children":20116},{"style":268},[20117],{"type":52,"value":106},{"type":46,"tag":250,"props":20119,"children":20120},{"style":274},[20121],{"type":52,"value":19192},{"type":46,"tag":250,"props":20123,"children":20124},{"style":268},[20125],{"type":52,"value":10014},{"type":46,"tag":250,"props":20127,"children":20128},{"class":252,"line":9380},[20129,20133,20137,20141,20145,20149,20153,20157],{"type":46,"tag":250,"props":20130,"children":20131},{"style":375},[20132],{"type":52,"value":19204},{"type":46,"tag":250,"props":20134,"children":20135},{"style":274},[20136],{"type":52,"value":10028},{"type":46,"tag":250,"props":20138,"children":20139},{"style":268},[20140],{"type":52,"value":106},{"type":46,"tag":250,"props":20142,"children":20143},{"style":274},[20144],{"type":52,"value":19060},{"type":46,"tag":250,"props":20146,"children":20147},{"style":375},[20148],{"type":52,"value":10041},{"type":46,"tag":250,"props":20150,"children":20151},{"style":274},[20152],{"type":52,"value":10046},{"type":46,"tag":250,"props":20154,"children":20155},{"style":268},[20156],{"type":52,"value":106},{"type":46,"tag":250,"props":20158,"children":20159},{"style":274},[20160],{"type":52,"value":19233},{"type":46,"tag":250,"props":20162,"children":20163},{"class":252,"line":9389},[20164,20168,20172,20176,20180,20184],{"type":46,"tag":250,"props":20165,"children":20166},{"style":375},[20167],{"type":52,"value":19241},{"type":46,"tag":250,"props":20169,"children":20170},{"style":274},[20171],{"type":52,"value":10028},{"type":46,"tag":250,"props":20173,"children":20174},{"style":268},[20175],{"type":52,"value":106},{"type":46,"tag":250,"props":20177,"children":20178},{"style":274},[20179],{"type":52,"value":19254},{"type":46,"tag":250,"props":20181,"children":20182},{"style":375},[20183],{"type":52,"value":10041},{"type":46,"tag":250,"props":20185,"children":20186},{"style":262},[20187],{"type":52,"value":19263},{"type":46,"tag":250,"props":20189,"children":20190},{"class":252,"line":9398},[20191],{"type":46,"tag":250,"props":20192,"children":20193},{"style":268},[20194],{"type":52,"value":19271},{"type":46,"tag":250,"props":20196,"children":20197},{"class":252,"line":9426},[20198,20202,20206],{"type":46,"tag":250,"props":20199,"children":20200},{"style":268},[20201],{"type":52,"value":19279},{"type":46,"tag":250,"props":20203,"children":20204},{"style":375},[20205],{"type":52,"value":9608},{"type":46,"tag":250,"props":20207,"children":20208},{"style":268},[20209],{"type":52,"value":19035},{"type":46,"tag":250,"props":20211,"children":20212},{"class":252,"line":9448},[20213],{"type":46,"tag":250,"props":20214,"children":20215},{"style":375},[20216],{"type":52,"value":19043},{"type":46,"tag":250,"props":20218,"children":20219},{"class":252,"line":9474},[20220],{"type":46,"tag":250,"props":20221,"children":20222},{"style":268},[20223],{"type":52,"value":19302},{"type":46,"tag":250,"props":20225,"children":20226},{"class":252,"line":9500},[20227,20231,20235,20239,20243,20247],{"type":46,"tag":250,"props":20228,"children":20229},{"style":274},[20230],{"type":52,"value":19310},{"type":46,"tag":250,"props":20232,"children":20233},{"style":268},[20234],{"type":52,"value":9557},{"type":46,"tag":250,"props":20236,"children":20237},{"style":375},[20238],{"type":52,"value":19319},{"type":46,"tag":250,"props":20240,"children":20241},{"style":268},[20242],{"type":52,"value":19324},{"type":46,"tag":250,"props":20244,"children":20245},{"style":375},[20246],{"type":52,"value":9608},{"type":46,"tag":250,"props":20248,"children":20249},{"style":268},[20250],{"type":52,"value":19333},{"type":46,"tag":250,"props":20252,"children":20253},{"class":252,"line":9525},[20254,20258],{"type":46,"tag":250,"props":20255,"children":20256},{"style":375},[20257],{"type":52,"value":19155},{"type":46,"tag":250,"props":20259,"children":20260},{"style":268},[20261],{"type":52,"value":19345},{"type":46,"tag":250,"props":20263,"children":20264},{"class":252,"line":9546},[20265,20269],{"type":46,"tag":250,"props":20266,"children":20267},{"style":375},[20268],{"type":52,"value":19353},{"type":46,"tag":250,"props":20270,"children":20271},{"style":268},[20272],{"type":52,"value":19358},{"type":46,"tag":250,"props":20274,"children":20275},{"class":252,"line":9616},[20276],{"type":46,"tag":250,"props":20277,"children":20278},{"style":268},[20279],{"type":52,"value":10114},{"type":46,"tag":250,"props":20281,"children":20282},{"class":252,"line":9678},[20283],{"type":46,"tag":250,"props":20284,"children":20285},{"style":375},[20286],{"type":52,"value":9395},{"type":46,"tag":250,"props":20288,"children":20289},{"class":252,"line":9740},[20290,20294,20298,20302],{"type":46,"tag":250,"props":20291,"children":20292},{"style":274},[20293],{"type":52,"value":19380},{"type":46,"tag":250,"props":20295,"children":20296},{"style":268},[20297],{"type":52,"value":106},{"type":46,"tag":250,"props":20299,"children":20300},{"style":274},[20301],{"type":52,"value":19389},{"type":46,"tag":250,"props":20303,"children":20304},{"style":268},[20305],{"type":52,"value":9445},{"type":46,"tag":250,"props":20307,"children":20308},{"class":252,"line":9802},[20309,20313,20317,20321],{"type":46,"tag":250,"props":20310,"children":20311},{"style":274},[20312],{"type":52,"value":19401},{"type":46,"tag":250,"props":20314,"children":20315},{"style":268},[20316],{"type":52,"value":106},{"type":46,"tag":250,"props":20318,"children":20319},{"style":274},[20320],{"type":52,"value":19410},{"type":46,"tag":250,"props":20322,"children":20323},{"style":268},[20324],{"type":52,"value":9445},{"type":46,"tag":250,"props":20326,"children":20327},{"class":252,"line":9823},[20328,20333,20337,20341,20345,20349,20353,20357,20361,20365,20369,20373,20377],{"type":46,"tag":250,"props":20329,"children":20330},{"style":268},[20331],{"type":52,"value":20332},"    DATE_DIFF(",{"type":46,"tag":250,"props":20334,"children":20335},{"style":274},[20336],{"type":52,"value":19440},{"type":46,"tag":250,"props":20338,"children":20339},{"style":268},[20340],{"type":52,"value":106},{"type":46,"tag":250,"props":20342,"children":20343},{"style":274},[20344],{"type":52,"value":19465},{"type":46,"tag":250,"props":20346,"children":20347},{"style":268},[20348],{"type":52,"value":151},{"type":46,"tag":250,"props":20350,"children":20351},{"style":274},[20352],{"type":52,"value":19440},{"type":46,"tag":250,"props":20354,"children":20355},{"style":268},[20356],{"type":52,"value":106},{"type":46,"tag":250,"props":20358,"children":20359},{"style":274},[20360],{"type":52,"value":19389},{"type":46,"tag":250,"props":20362,"children":20363},{"style":268},[20364],{"type":52,"value":151},{"type":46,"tag":250,"props":20366,"children":20367},{"style":375},[20368],{"type":52,"value":20013},{"type":46,"tag":250,"props":20370,"children":20371},{"style":268},[20372],{"type":52,"value":10086},{"type":46,"tag":250,"props":20374,"children":20375},{"style":375},[20376],{"type":52,"value":9608},{"type":46,"tag":250,"props":20378,"children":20379},{"style":268},[20380],{"type":52,"value":19478},{"type":46,"tag":250,"props":20382,"children":20383},{"class":252,"line":9844},[20384,20388,20392,20396,20400,20404,20408,20412,20416],{"type":46,"tag":250,"props":20385,"children":20386},{"style":274},[20387],{"type":52,"value":17096},{"type":46,"tag":250,"props":20389,"children":20390},{"style":268},[20391],{"type":52,"value":9557},{"type":46,"tag":250,"props":20393,"children":20394},{"style":375},[20395],{"type":52,"value":19319},{"type":46,"tag":250,"props":20397,"children":20398},{"style":274},[20399],{"type":52,"value":19498},{"type":46,"tag":250,"props":20401,"children":20402},{"style":268},[20403],{"type":52,"value":106},{"type":46,"tag":250,"props":20405,"children":20406},{"style":274},[20407],{"type":52,"value":19060},{"type":46,"tag":250,"props":20409,"children":20410},{"style":268},[20411],{"type":52,"value":10086},{"type":46,"tag":250,"props":20413,"children":20414},{"style":375},[20415],{"type":52,"value":9608},{"type":46,"tag":250,"props":20417,"children":20418},{"style":268},[20419],{"type":52,"value":19519},{"type":46,"tag":250,"props":20421,"children":20422},{"class":252,"line":9865},[20423,20427,20431,20435,20439,20443,20447,20451,20455,20459,20463,20467,20471,20475,20479,20483,20487,20491,20495,20499,20503,20507,20511,20515,20519],{"type":46,"tag":250,"props":20424,"children":20425},{"style":274},[20426],{"type":52,"value":17313},{"type":46,"tag":250,"props":20428,"children":20429},{"style":268},[20430],{"type":52,"value":9557},{"type":46,"tag":250,"props":20432,"children":20433},{"style":274},[20434],{"type":52,"value":17987},{"type":46,"tag":250,"props":20436,"children":20437},{"style":268},[20438],{"type":52,"value":9557},{"type":46,"tag":250,"props":20440,"children":20441},{"style":375},[20442],{"type":52,"value":19319},{"type":46,"tag":250,"props":20444,"children":20445},{"style":274},[20446],{"type":52,"value":19498},{"type":46,"tag":250,"props":20448,"children":20449},{"style":268},[20450],{"type":52,"value":106},{"type":46,"tag":250,"props":20452,"children":20453},{"style":274},[20454],{"type":52,"value":19060},{"type":46,"tag":250,"props":20456,"children":20457},{"style":268},[20458],{"type":52,"value":10086},{"type":46,"tag":250,"props":20460,"children":20461},{"style":375},[20462],{"type":52,"value":17323},{"type":46,"tag":250,"props":20464,"children":20465},{"style":274},[20466],{"type":52,"value":17909},{"type":46,"tag":250,"props":20468,"children":20469},{"style":268},[20470],{"type":52,"value":9557},{"type":46,"tag":250,"props":20472,"children":20473},{"style":274},[20474],{"type":52,"value":19548},{"type":46,"tag":250,"props":20476,"children":20477},{"style":268},[20478],{"type":52,"value":106},{"type":46,"tag":250,"props":20480,"children":20481},{"style":274},[20482],{"type":52,"value":19410},{"type":46,"tag":250,"props":20484,"children":20485},{"style":268},[20486],{"type":52,"value":151},{"type":46,"tag":250,"props":20488,"children":20489},{"style":274},[20490],{"type":52,"value":9899},{"type":46,"tag":250,"props":20492,"children":20493},{"style":268},[20494],{"type":52,"value":10086},{"type":46,"tag":250,"props":20496,"children":20497},{"style":375},[20498],{"type":52,"value":15522},{"type":46,"tag":250,"props":20500,"children":20501},{"style":274},[20502],{"type":52,"value":9890},{"type":46,"tag":250,"props":20504,"children":20505},{"style":268},[20506],{"type":52,"value":151},{"type":46,"tag":250,"props":20508,"children":20509},{"style":274},[20510],{"type":52,"value":9598},{"type":46,"tag":250,"props":20512,"children":20513},{"style":268},[20514],{"type":52,"value":10086},{"type":46,"tag":250,"props":20516,"children":20517},{"style":375},[20518],{"type":52,"value":9608},{"type":46,"tag":250,"props":20520,"children":20521},{"style":268},[20522],{"type":52,"value":19597},{"type":46,"tag":250,"props":20524,"children":20525},{"class":252,"line":9911},[20526,20530,20534,20538,20542,20546,20550,20554],{"type":46,"tag":250,"props":20527,"children":20528},{"style":274},[20529],{"type":52,"value":17181},{"type":46,"tag":250,"props":20531,"children":20532},{"style":268},[20533],{"type":52,"value":9557},{"type":46,"tag":250,"props":20535,"children":20536},{"style":274},[20537],{"type":52,"value":19440},{"type":46,"tag":250,"props":20539,"children":20540},{"style":268},[20541],{"type":52,"value":106},{"type":46,"tag":250,"props":20543,"children":20544},{"style":274},[20545],{"type":52,"value":19621},{"type":46,"tag":250,"props":20547,"children":20548},{"style":268},[20549],{"type":52,"value":10086},{"type":46,"tag":250,"props":20551,"children":20552},{"style":375},[20553],{"type":52,"value":9608},{"type":46,"tag":250,"props":20555,"children":20556},{"style":268},[20557],{"type":52,"value":19634},{"type":46,"tag":250,"props":20559,"children":20560},{"class":252,"line":9937},[20561,20565,20569,20573,20577,20581,20585,20589,20593,20597,20601,20605,20609,20613,20617,20621,20625,20629,20633,20637,20641],{"type":46,"tag":250,"props":20562,"children":20563},{"style":274},[20564],{"type":52,"value":17313},{"type":46,"tag":250,"props":20566,"children":20567},{"style":268},[20568],{"type":52,"value":9557},{"type":46,"tag":250,"props":20570,"children":20571},{"style":274},[20572],{"type":52,"value":17852},{"type":46,"tag":250,"props":20574,"children":20575},{"style":268},[20576],{"type":52,"value":9557},{"type":46,"tag":250,"props":20578,"children":20579},{"style":274},[20580],{"type":52,"value":19440},{"type":46,"tag":250,"props":20582,"children":20583},{"style":268},[20584],{"type":52,"value":106},{"type":46,"tag":250,"props":20586,"children":20587},{"style":274},[20588],{"type":52,"value":19621},{"type":46,"tag":250,"props":20590,"children":20591},{"style":268},[20592],{"type":52,"value":10086},{"type":46,"tag":250,"props":20594,"children":20595},{"style":375},[20596],{"type":52,"value":17323},{"type":46,"tag":250,"props":20598,"children":20599},{"style":274},[20600],{"type":52,"value":17909},{"type":46,"tag":250,"props":20602,"children":20603},{"style":268},[20604],{"type":52,"value":9557},{"type":46,"tag":250,"props":20606,"children":20607},{"style":274},[20608],{"type":52,"value":19548},{"type":46,"tag":250,"props":20610,"children":20611},{"style":268},[20612],{"type":52,"value":106},{"type":46,"tag":250,"props":20614,"children":20615},{"style":274},[20616],{"type":52,"value":19410},{"type":46,"tag":250,"props":20618,"children":20619},{"style":268},[20620],{"type":52,"value":151},{"type":46,"tag":250,"props":20622,"children":20623},{"style":274},[20624],{"type":52,"value":9899},{"type":46,"tag":250,"props":20626,"children":20627},{"style":268},[20628],{"type":52,"value":17342},{"type":46,"tag":250,"props":20630,"children":20631},{"style":274},[20632],{"type":52,"value":9598},{"type":46,"tag":250,"props":20634,"children":20635},{"style":268},[20636],{"type":52,"value":10086},{"type":46,"tag":250,"props":20638,"children":20639},{"style":375},[20640],{"type":52,"value":9608},{"type":46,"tag":250,"props":20642,"children":20643},{"style":268},[20644],{"type":52,"value":19699},{"type":46,"tag":250,"props":20646,"children":20647},{"class":252,"line":9963},[20648,20652],{"type":46,"tag":250,"props":20649,"children":20650},{"style":375},[20651],{"type":52,"value":9969},{"type":46,"tag":250,"props":20653,"children":20654},{"style":268},[20655],{"type":52,"value":19711},{"type":46,"tag":250,"props":20657,"children":20658},{"class":252,"line":9991},[20659,20663],{"type":46,"tag":250,"props":20660,"children":20661},{"style":375},[20662],{"type":52,"value":19719},{"type":46,"tag":250,"props":20664,"children":20665},{"style":268},[20666],{"type":52,"value":19724},{"type":46,"tag":250,"props":20668,"children":20669},{"class":252,"line":10017},[20670,20674,20678,20682,20686,20690,20694,20698],{"type":46,"tag":250,"props":20671,"children":20672},{"style":375},[20673],{"type":52,"value":10023},{"type":46,"tag":250,"props":20675,"children":20676},{"style":274},[20677],{"type":52,"value":19498},{"type":46,"tag":250,"props":20679,"children":20680},{"style":268},[20681],{"type":52,"value":106},{"type":46,"tag":250,"props":20683,"children":20684},{"style":274},[20685],{"type":52,"value":19389},{"type":46,"tag":250,"props":20687,"children":20688},{"style":375},[20689],{"type":52,"value":10041},{"type":46,"tag":250,"props":20691,"children":20692},{"style":274},[20693],{"type":52,"value":19752},{"type":46,"tag":250,"props":20695,"children":20696},{"style":268},[20697],{"type":52,"value":106},{"type":46,"tag":250,"props":20699,"children":20700},{"style":274},[20701],{"type":52,"value":19761},{"type":46,"tag":250,"props":20703,"children":20704},{"class":252,"line":10058},[20705,20709,20713,20717,20721,20725,20729,20733,20737],{"type":46,"tag":250,"props":20706,"children":20707},{"style":375},[20708],{"type":52,"value":15970},{"type":46,"tag":250,"props":20710,"children":20711},{"style":274},[20712],{"type":52,"value":19498},{"type":46,"tag":250,"props":20714,"children":20715},{"style":268},[20716],{"type":52,"value":106},{"type":46,"tag":250,"props":20718,"children":20719},{"style":274},[20720],{"type":52,"value":19389},{"type":46,"tag":250,"props":20722,"children":20723},{"style":268},[20724],{"type":52,"value":151},{"type":46,"tag":250,"props":20726,"children":20727},{"style":274},[20728],{"type":52,"value":19548},{"type":46,"tag":250,"props":20730,"children":20731},{"style":268},[20732],{"type":52,"value":106},{"type":46,"tag":250,"props":20734,"children":20735},{"style":274},[20736],{"type":52,"value":19410},{"type":46,"tag":250,"props":20738,"children":20739},{"style":268},[20740],{"type":52,"value":19801},{"type":46,"tag":250,"props":20742,"children":20743},{"class":252,"line":10936},[20744,20748,20752,20756,20760],{"type":46,"tag":250,"props":20745,"children":20746},{"style":375},[20747],{"type":52,"value":17462},{"type":46,"tag":250,"props":20749,"children":20750},{"style":274},[20751],{"type":52,"value":19498},{"type":46,"tag":250,"props":20753,"children":20754},{"style":268},[20755],{"type":52,"value":106},{"type":46,"tag":250,"props":20757,"children":20758},{"style":274},[20759],{"type":52,"value":19389},{"type":46,"tag":250,"props":20761,"children":20762},{"style":268},[20763],{"type":52,"value":19801},{"type":46,"tag":429,"props":20765,"children":20766},{"v-slot:snowflake":7},[20767],{"type":46,"tag":240,"props":20768,"children":20770},{"className":9175,"code":20769,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_customer_cohorts\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_orders\n  - staging.stg_customers\ncolumns:\n  - name: cohort_month\n    type: date\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH customer_orders AS (\n    SELECT\n        o.customer_email,\n        DATE_TRUNC('month', c.first_seen_at) AS cohort_month,\n        DATE_TRUNC('month', o.order_date) AS order_month,\n        o.order_total\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n),\ncohort_sizes AS (\n    SELECT\n        cohort_month,\n        count(DISTINCT customer_email) AS cohort_size\n    FROM customer_orders\n    GROUP BY cohort_month\n)\nSELECT\n    co.cohort_month,\n    cs.cohort_size,\n    DATEDIFF('month', co.cohort_month, co.order_month) AS months_since_first,\n    count(DISTINCT co.customer_email) AS active_customers,\n    round(count(DISTINCT co.customer_email) \u002F NULLIF(cs.cohort_size, 0) * 100, 2) AS retention_rate,\n    sum(co.order_total) AS cohort_revenue,\n    round(sum(co.order_total) \u002F NULLIF(cs.cohort_size, 0), 2) AS revenue_per_customer\nFROM customer_orders co\nINNER JOIN cohort_sizes cs\n    ON co.cohort_month = cs.cohort_month\nGROUP BY co.cohort_month, cs.cohort_size, months_since_first\nORDER BY co.cohort_month, months_since_first\n",[20771],{"type":46,"tag":99,"props":20772,"children":20773},{"__ignoreMap":7},[20774,20781,20788,20795,20802,20809,20816,20823,20830,20837,20844,20851,20858,20865,20872,20879,20898,20905,20924,20963,21002,21017,21040,21063,21098,21125,21132,21147,21154,21161,21188,21199,21210,21217,21224,21243,21262,21322,21361,21464,21499,21586,21597,21608,21643,21682],{"type":46,"tag":250,"props":20775,"children":20776},{"class":252,"line":23},[20777],{"type":46,"tag":250,"props":20778,"children":20779},{"style":9187},[20780],{"type":52,"value":9190},{"type":46,"tag":250,"props":20782,"children":20783},{"class":252,"line":285},[20784],{"type":46,"tag":250,"props":20785,"children":20786},{"style":9187},[20787],{"type":52,"value":18920},{"type":46,"tag":250,"props":20789,"children":20790},{"class":252,"line":299},[20791],{"type":46,"tag":250,"props":20792,"children":20793},{"style":9187},[20794],{"type":52,"value":9206},{"type":46,"tag":250,"props":20796,"children":20797},{"class":252,"line":807},[20798],{"type":46,"tag":250,"props":20799,"children":20800},{"style":9187},[20801],{"type":52,"value":9214},{"type":46,"tag":250,"props":20803,"children":20804},{"class":252,"line":820},[20805],{"type":46,"tag":250,"props":20806,"children":20807},{"style":9187},[20808],{"type":52,"value":9222},{"type":46,"tag":250,"props":20810,"children":20811},{"class":252,"line":844},[20812],{"type":46,"tag":250,"props":20813,"children":20814},{"style":9187},[20815],{"type":52,"value":9230},{"type":46,"tag":250,"props":20817,"children":20818},{"class":252,"line":862},[20819],{"type":46,"tag":250,"props":20820,"children":20821},{"style":9187},[20822],{"type":52,"value":16980},{"type":46,"tag":250,"props":20824,"children":20825},{"class":252,"line":11},[20826],{"type":46,"tag":250,"props":20827,"children":20828},{"style":9187},[20829],{"type":52,"value":18963},{"type":46,"tag":250,"props":20831,"children":20832},{"class":252,"line":4649},[20833],{"type":46,"tag":250,"props":20834,"children":20835},{"style":9187},[20836],{"type":52,"value":9254},{"type":46,"tag":250,"props":20838,"children":20839},{"class":252,"line":9257},[20840],{"type":46,"tag":250,"props":20841,"children":20842},{"style":9187},[20843],{"type":52,"value":18978},{"type":46,"tag":250,"props":20845,"children":20846},{"class":252,"line":9266},[20847],{"type":46,"tag":250,"props":20848,"children":20849},{"style":9187},[20850],{"type":52,"value":13288},{"type":46,"tag":250,"props":20852,"children":20853},{"class":252,"line":9275},[20854],{"type":46,"tag":250,"props":20855,"children":20856},{"style":9187},[20857],{"type":52,"value":9281},{"type":46,"tag":250,"props":20859,"children":20860},{"class":252,"line":9284},[20861],{"type":46,"tag":250,"props":20862,"children":20863},{"style":9187},[20864],{"type":52,"value":9290},{"type":46,"tag":250,"props":20866,"children":20867},{"class":252,"line":9293},[20868],{"type":46,"tag":250,"props":20869,"children":20870},{"style":9187},[20871],{"type":52,"value":9377},{"type":46,"tag":250,"props":20873,"children":20874},{"class":252,"line":4121},[20875],{"type":46,"tag":250,"props":20876,"children":20877},{"emptyLinePlaceholder":22},[20878],{"type":52,"value":9386},{"type":46,"tag":250,"props":20880,"children":20881},{"class":252,"line":9310},[20882,20886,20890,20894],{"type":46,"tag":250,"props":20883,"children":20884},{"style":375},[20885],{"type":52,"value":19021},{"type":46,"tag":250,"props":20887,"children":20888},{"style":268},[20889],{"type":52,"value":19026},{"type":46,"tag":250,"props":20891,"children":20892},{"style":375},[20893],{"type":52,"value":9608},{"type":46,"tag":250,"props":20895,"children":20896},{"style":268},[20897],{"type":52,"value":19035},{"type":46,"tag":250,"props":20899,"children":20900},{"class":252,"line":9319},[20901],{"type":46,"tag":250,"props":20902,"children":20903},{"style":375},[20904],{"type":52,"value":19043},{"type":46,"tag":250,"props":20906,"children":20907},{"class":252,"line":9327},[20908,20912,20916,20920],{"type":46,"tag":250,"props":20909,"children":20910},{"style":274},[20911],{"type":52,"value":19051},{"type":46,"tag":250,"props":20913,"children":20914},{"style":268},[20915],{"type":52,"value":106},{"type":46,"tag":250,"props":20917,"children":20918},{"style":274},[20919],{"type":52,"value":19060},{"type":46,"tag":250,"props":20921,"children":20922},{"style":268},[20923],{"type":52,"value":9445},{"type":46,"tag":250,"props":20925,"children":20926},{"class":252,"line":9335},[20927,20931,20935,20939,20943,20947,20951,20955,20959],{"type":46,"tag":250,"props":20928,"children":20929},{"style":268},[20930],{"type":52,"value":19992},{"type":46,"tag":250,"props":20932,"children":20933},{"style":262},[20934],{"type":52,"value":19431},{"type":46,"tag":250,"props":20936,"children":20937},{"style":268},[20938],{"type":52,"value":151},{"type":46,"tag":250,"props":20940,"children":20941},{"style":274},[20942],{"type":52,"value":10100},{"type":46,"tag":250,"props":20944,"children":20945},{"style":268},[20946],{"type":52,"value":106},{"type":46,"tag":250,"props":20948,"children":20949},{"style":274},[20950],{"type":52,"value":19085},{"type":46,"tag":250,"props":20952,"children":20953},{"style":268},[20954],{"type":52,"value":10086},{"type":46,"tag":250,"props":20956,"children":20957},{"style":375},[20958],{"type":52,"value":9608},{"type":46,"tag":250,"props":20960,"children":20961},{"style":268},[20962],{"type":52,"value":19098},{"type":46,"tag":250,"props":20964,"children":20965},{"class":252,"line":9344},[20966,20970,20974,20978,20982,20986,20990,20994,20998],{"type":46,"tag":250,"props":20967,"children":20968},{"style":268},[20969],{"type":52,"value":19992},{"type":46,"tag":250,"props":20971,"children":20972},{"style":262},[20973],{"type":52,"value":19431},{"type":46,"tag":250,"props":20975,"children":20976},{"style":268},[20977],{"type":52,"value":151},{"type":46,"tag":250,"props":20979,"children":20980},{"style":274},[20981],{"type":52,"value":9562},{"type":46,"tag":250,"props":20983,"children":20984},{"style":268},[20985],{"type":52,"value":106},{"type":46,"tag":250,"props":20987,"children":20988},{"style":274},[20989],{"type":52,"value":19118},{"type":46,"tag":250,"props":20991,"children":20992},{"style":268},[20993],{"type":52,"value":10086},{"type":46,"tag":250,"props":20995,"children":20996},{"style":375},[20997],{"type":52,"value":9608},{"type":46,"tag":250,"props":20999,"children":21000},{"style":268},[21001],{"type":52,"value":19131},{"type":46,"tag":250,"props":21003,"children":21004},{"class":252,"line":9353},[21005,21009,21013],{"type":46,"tag":250,"props":21006,"children":21007},{"style":274},[21008],{"type":52,"value":19051},{"type":46,"tag":250,"props":21010,"children":21011},{"style":268},[21012],{"type":52,"value":106},{"type":46,"tag":250,"props":21014,"children":21015},{"style":274},[21016],{"type":52,"value":19147},{"type":46,"tag":250,"props":21018,"children":21019},{"class":252,"line":9362},[21020,21024,21028,21032,21036],{"type":46,"tag":250,"props":21021,"children":21022},{"style":375},[21023],{"type":52,"value":19155},{"type":46,"tag":250,"props":21025,"children":21026},{"style":274},[21027],{"type":52,"value":17433},{"type":46,"tag":250,"props":21029,"children":21030},{"style":268},[21031],{"type":52,"value":106},{"type":46,"tag":250,"props":21033,"children":21034},{"style":274},[21035],{"type":52,"value":18055},{"type":46,"tag":250,"props":21037,"children":21038},{"style":268},[21039],{"type":52,"value":9988},{"type":46,"tag":250,"props":21041,"children":21042},{"class":252,"line":9371},[21043,21047,21051,21055,21059],{"type":46,"tag":250,"props":21044,"children":21045},{"style":375},[21046],{"type":52,"value":19179},{"type":46,"tag":250,"props":21048,"children":21049},{"style":274},[21050],{"type":52,"value":17433},{"type":46,"tag":250,"props":21052,"children":21053},{"style":268},[21054],{"type":52,"value":106},{"type":46,"tag":250,"props":21056,"children":21057},{"style":274},[21058],{"type":52,"value":19192},{"type":46,"tag":250,"props":21060,"children":21061},{"style":268},[21062],{"type":52,"value":10014},{"type":46,"tag":250,"props":21064,"children":21065},{"class":252,"line":9380},[21066,21070,21074,21078,21082,21086,21090,21094],{"type":46,"tag":250,"props":21067,"children":21068},{"style":375},[21069],{"type":52,"value":19204},{"type":46,"tag":250,"props":21071,"children":21072},{"style":274},[21073],{"type":52,"value":10028},{"type":46,"tag":250,"props":21075,"children":21076},{"style":268},[21077],{"type":52,"value":106},{"type":46,"tag":250,"props":21079,"children":21080},{"style":274},[21081],{"type":52,"value":19060},{"type":46,"tag":250,"props":21083,"children":21084},{"style":375},[21085],{"type":52,"value":10041},{"type":46,"tag":250,"props":21087,"children":21088},{"style":274},[21089],{"type":52,"value":10046},{"type":46,"tag":250,"props":21091,"children":21092},{"style":268},[21093],{"type":52,"value":106},{"type":46,"tag":250,"props":21095,"children":21096},{"style":274},[21097],{"type":52,"value":19233},{"type":46,"tag":250,"props":21099,"children":21100},{"class":252,"line":9389},[21101,21105,21109,21113,21117,21121],{"type":46,"tag":250,"props":21102,"children":21103},{"style":375},[21104],{"type":52,"value":19241},{"type":46,"tag":250,"props":21106,"children":21107},{"style":274},[21108],{"type":52,"value":10028},{"type":46,"tag":250,"props":21110,"children":21111},{"style":268},[21112],{"type":52,"value":106},{"type":46,"tag":250,"props":21114,"children":21115},{"style":274},[21116],{"type":52,"value":19254},{"type":46,"tag":250,"props":21118,"children":21119},{"style":375},[21120],{"type":52,"value":10041},{"type":46,"tag":250,"props":21122,"children":21123},{"style":262},[21124],{"type":52,"value":19263},{"type":46,"tag":250,"props":21126,"children":21127},{"class":252,"line":9398},[21128],{"type":46,"tag":250,"props":21129,"children":21130},{"style":268},[21131],{"type":52,"value":19271},{"type":46,"tag":250,"props":21133,"children":21134},{"class":252,"line":9426},[21135,21139,21143],{"type":46,"tag":250,"props":21136,"children":21137},{"style":268},[21138],{"type":52,"value":19279},{"type":46,"tag":250,"props":21140,"children":21141},{"style":375},[21142],{"type":52,"value":9608},{"type":46,"tag":250,"props":21144,"children":21145},{"style":268},[21146],{"type":52,"value":19035},{"type":46,"tag":250,"props":21148,"children":21149},{"class":252,"line":9448},[21150],{"type":46,"tag":250,"props":21151,"children":21152},{"style":375},[21153],{"type":52,"value":19043},{"type":46,"tag":250,"props":21155,"children":21156},{"class":252,"line":9474},[21157],{"type":46,"tag":250,"props":21158,"children":21159},{"style":268},[21160],{"type":52,"value":19302},{"type":46,"tag":250,"props":21162,"children":21163},{"class":252,"line":9500},[21164,21168,21172,21176,21180,21184],{"type":46,"tag":250,"props":21165,"children":21166},{"style":274},[21167],{"type":52,"value":19310},{"type":46,"tag":250,"props":21169,"children":21170},{"style":268},[21171],{"type":52,"value":9557},{"type":46,"tag":250,"props":21173,"children":21174},{"style":375},[21175],{"type":52,"value":19319},{"type":46,"tag":250,"props":21177,"children":21178},{"style":268},[21179],{"type":52,"value":19324},{"type":46,"tag":250,"props":21181,"children":21182},{"style":375},[21183],{"type":52,"value":9608},{"type":46,"tag":250,"props":21185,"children":21186},{"style":268},[21187],{"type":52,"value":19333},{"type":46,"tag":250,"props":21189,"children":21190},{"class":252,"line":9525},[21191,21195],{"type":46,"tag":250,"props":21192,"children":21193},{"style":375},[21194],{"type":52,"value":19155},{"type":46,"tag":250,"props":21196,"children":21197},{"style":268},[21198],{"type":52,"value":19345},{"type":46,"tag":250,"props":21200,"children":21201},{"class":252,"line":9546},[21202,21206],{"type":46,"tag":250,"props":21203,"children":21204},{"style":375},[21205],{"type":52,"value":19353},{"type":46,"tag":250,"props":21207,"children":21208},{"style":268},[21209],{"type":52,"value":19358},{"type":46,"tag":250,"props":21211,"children":21212},{"class":252,"line":9616},[21213],{"type":46,"tag":250,"props":21214,"children":21215},{"style":268},[21216],{"type":52,"value":10114},{"type":46,"tag":250,"props":21218,"children":21219},{"class":252,"line":9678},[21220],{"type":46,"tag":250,"props":21221,"children":21222},{"style":375},[21223],{"type":52,"value":9395},{"type":46,"tag":250,"props":21225,"children":21226},{"class":252,"line":9740},[21227,21231,21235,21239],{"type":46,"tag":250,"props":21228,"children":21229},{"style":274},[21230],{"type":52,"value":19380},{"type":46,"tag":250,"props":21232,"children":21233},{"style":268},[21234],{"type":52,"value":106},{"type":46,"tag":250,"props":21236,"children":21237},{"style":274},[21238],{"type":52,"value":19389},{"type":46,"tag":250,"props":21240,"children":21241},{"style":268},[21242],{"type":52,"value":9445},{"type":46,"tag":250,"props":21244,"children":21245},{"class":252,"line":9802},[21246,21250,21254,21258],{"type":46,"tag":250,"props":21247,"children":21248},{"style":274},[21249],{"type":52,"value":19401},{"type":46,"tag":250,"props":21251,"children":21252},{"style":268},[21253],{"type":52,"value":106},{"type":46,"tag":250,"props":21255,"children":21256},{"style":274},[21257],{"type":52,"value":19410},{"type":46,"tag":250,"props":21259,"children":21260},{"style":268},[21261],{"type":52,"value":9445},{"type":46,"tag":250,"props":21263,"children":21264},{"class":252,"line":9823},[21265,21270,21274,21278,21282,21286,21290,21294,21298,21302,21306,21310,21314,21318],{"type":46,"tag":250,"props":21266,"children":21267},{"style":274},[21268],{"type":52,"value":21269},"    DATEDIFF",{"type":46,"tag":250,"props":21271,"children":21272},{"style":268},[21273],{"type":52,"value":9557},{"type":46,"tag":250,"props":21275,"children":21276},{"style":262},[21277],{"type":52,"value":19431},{"type":46,"tag":250,"props":21279,"children":21280},{"style":268},[21281],{"type":52,"value":151},{"type":46,"tag":250,"props":21283,"children":21284},{"style":274},[21285],{"type":52,"value":19440},{"type":46,"tag":250,"props":21287,"children":21288},{"style":268},[21289],{"type":52,"value":106},{"type":46,"tag":250,"props":21291,"children":21292},{"style":274},[21293],{"type":52,"value":19389},{"type":46,"tag":250,"props":21295,"children":21296},{"style":268},[21297],{"type":52,"value":151},{"type":46,"tag":250,"props":21299,"children":21300},{"style":274},[21301],{"type":52,"value":19440},{"type":46,"tag":250,"props":21303,"children":21304},{"style":268},[21305],{"type":52,"value":106},{"type":46,"tag":250,"props":21307,"children":21308},{"style":274},[21309],{"type":52,"value":19465},{"type":46,"tag":250,"props":21311,"children":21312},{"style":268},[21313],{"type":52,"value":10086},{"type":46,"tag":250,"props":21315,"children":21316},{"style":375},[21317],{"type":52,"value":9608},{"type":46,"tag":250,"props":21319,"children":21320},{"style":268},[21321],{"type":52,"value":19478},{"type":46,"tag":250,"props":21323,"children":21324},{"class":252,"line":9844},[21325,21329,21333,21337,21341,21345,21349,21353,21357],{"type":46,"tag":250,"props":21326,"children":21327},{"style":274},[21328],{"type":52,"value":17096},{"type":46,"tag":250,"props":21330,"children":21331},{"style":268},[21332],{"type":52,"value":9557},{"type":46,"tag":250,"props":21334,"children":21335},{"style":375},[21336],{"type":52,"value":19319},{"type":46,"tag":250,"props":21338,"children":21339},{"style":274},[21340],{"type":52,"value":19498},{"type":46,"tag":250,"props":21342,"children":21343},{"style":268},[21344],{"type":52,"value":106},{"type":46,"tag":250,"props":21346,"children":21347},{"style":274},[21348],{"type":52,"value":19060},{"type":46,"tag":250,"props":21350,"children":21351},{"style":268},[21352],{"type":52,"value":10086},{"type":46,"tag":250,"props":21354,"children":21355},{"style":375},[21356],{"type":52,"value":9608},{"type":46,"tag":250,"props":21358,"children":21359},{"style":268},[21360],{"type":52,"value":19519},{"type":46,"tag":250,"props":21362,"children":21363},{"class":252,"line":9865},[21364,21368,21372,21376,21380,21384,21388,21392,21396,21400,21404,21408,21412,21416,21420,21424,21428,21432,21436,21440,21444,21448,21452,21456,21460],{"type":46,"tag":250,"props":21365,"children":21366},{"style":274},[21367],{"type":52,"value":17313},{"type":46,"tag":250,"props":21369,"children":21370},{"style":268},[21371],{"type":52,"value":9557},{"type":46,"tag":250,"props":21373,"children":21374},{"style":274},[21375],{"type":52,"value":17987},{"type":46,"tag":250,"props":21377,"children":21378},{"style":268},[21379],{"type":52,"value":9557},{"type":46,"tag":250,"props":21381,"children":21382},{"style":375},[21383],{"type":52,"value":19319},{"type":46,"tag":250,"props":21385,"children":21386},{"style":274},[21387],{"type":52,"value":19498},{"type":46,"tag":250,"props":21389,"children":21390},{"style":268},[21391],{"type":52,"value":106},{"type":46,"tag":250,"props":21393,"children":21394},{"style":274},[21395],{"type":52,"value":19060},{"type":46,"tag":250,"props":21397,"children":21398},{"style":268},[21399],{"type":52,"value":10086},{"type":46,"tag":250,"props":21401,"children":21402},{"style":375},[21403],{"type":52,"value":17323},{"type":46,"tag":250,"props":21405,"children":21406},{"style":274},[21407],{"type":52,"value":17909},{"type":46,"tag":250,"props":21409,"children":21410},{"style":268},[21411],{"type":52,"value":9557},{"type":46,"tag":250,"props":21413,"children":21414},{"style":274},[21415],{"type":52,"value":19548},{"type":46,"tag":250,"props":21417,"children":21418},{"style":268},[21419],{"type":52,"value":106},{"type":46,"tag":250,"props":21421,"children":21422},{"style":274},[21423],{"type":52,"value":19410},{"type":46,"tag":250,"props":21425,"children":21426},{"style":268},[21427],{"type":52,"value":151},{"type":46,"tag":250,"props":21429,"children":21430},{"style":274},[21431],{"type":52,"value":9899},{"type":46,"tag":250,"props":21433,"children":21434},{"style":268},[21435],{"type":52,"value":10086},{"type":46,"tag":250,"props":21437,"children":21438},{"style":375},[21439],{"type":52,"value":15522},{"type":46,"tag":250,"props":21441,"children":21442},{"style":274},[21443],{"type":52,"value":9890},{"type":46,"tag":250,"props":21445,"children":21446},{"style":268},[21447],{"type":52,"value":151},{"type":46,"tag":250,"props":21449,"children":21450},{"style":274},[21451],{"type":52,"value":9598},{"type":46,"tag":250,"props":21453,"children":21454},{"style":268},[21455],{"type":52,"value":10086},{"type":46,"tag":250,"props":21457,"children":21458},{"style":375},[21459],{"type":52,"value":9608},{"type":46,"tag":250,"props":21461,"children":21462},{"style":268},[21463],{"type":52,"value":19597},{"type":46,"tag":250,"props":21465,"children":21466},{"class":252,"line":9911},[21467,21471,21475,21479,21483,21487,21491,21495],{"type":46,"tag":250,"props":21468,"children":21469},{"style":274},[21470],{"type":52,"value":17181},{"type":46,"tag":250,"props":21472,"children":21473},{"style":268},[21474],{"type":52,"value":9557},{"type":46,"tag":250,"props":21476,"children":21477},{"style":274},[21478],{"type":52,"value":19440},{"type":46,"tag":250,"props":21480,"children":21481},{"style":268},[21482],{"type":52,"value":106},{"type":46,"tag":250,"props":21484,"children":21485},{"style":274},[21486],{"type":52,"value":19621},{"type":46,"tag":250,"props":21488,"children":21489},{"style":268},[21490],{"type":52,"value":10086},{"type":46,"tag":250,"props":21492,"children":21493},{"style":375},[21494],{"type":52,"value":9608},{"type":46,"tag":250,"props":21496,"children":21497},{"style":268},[21498],{"type":52,"value":19634},{"type":46,"tag":250,"props":21500,"children":21501},{"class":252,"line":9937},[21502,21506,21510,21514,21518,21522,21526,21530,21534,21538,21542,21546,21550,21554,21558,21562,21566,21570,21574,21578,21582],{"type":46,"tag":250,"props":21503,"children":21504},{"style":274},[21505],{"type":52,"value":17313},{"type":46,"tag":250,"props":21507,"children":21508},{"style":268},[21509],{"type":52,"value":9557},{"type":46,"tag":250,"props":21511,"children":21512},{"style":274},[21513],{"type":52,"value":17852},{"type":46,"tag":250,"props":21515,"children":21516},{"style":268},[21517],{"type":52,"value":9557},{"type":46,"tag":250,"props":21519,"children":21520},{"style":274},[21521],{"type":52,"value":19440},{"type":46,"tag":250,"props":21523,"children":21524},{"style":268},[21525],{"type":52,"value":106},{"type":46,"tag":250,"props":21527,"children":21528},{"style":274},[21529],{"type":52,"value":19621},{"type":46,"tag":250,"props":21531,"children":21532},{"style":268},[21533],{"type":52,"value":10086},{"type":46,"tag":250,"props":21535,"children":21536},{"style":375},[21537],{"type":52,"value":17323},{"type":46,"tag":250,"props":21539,"children":21540},{"style":274},[21541],{"type":52,"value":17909},{"type":46,"tag":250,"props":21543,"children":21544},{"style":268},[21545],{"type":52,"value":9557},{"type":46,"tag":250,"props":21547,"children":21548},{"style":274},[21549],{"type":52,"value":19548},{"type":46,"tag":250,"props":21551,"children":21552},{"style":268},[21553],{"type":52,"value":106},{"type":46,"tag":250,"props":21555,"children":21556},{"style":274},[21557],{"type":52,"value":19410},{"type":46,"tag":250,"props":21559,"children":21560},{"style":268},[21561],{"type":52,"value":151},{"type":46,"tag":250,"props":21563,"children":21564},{"style":274},[21565],{"type":52,"value":9899},{"type":46,"tag":250,"props":21567,"children":21568},{"style":268},[21569],{"type":52,"value":17342},{"type":46,"tag":250,"props":21571,"children":21572},{"style":274},[21573],{"type":52,"value":9598},{"type":46,"tag":250,"props":21575,"children":21576},{"style":268},[21577],{"type":52,"value":10086},{"type":46,"tag":250,"props":21579,"children":21580},{"style":375},[21581],{"type":52,"value":9608},{"type":46,"tag":250,"props":21583,"children":21584},{"style":268},[21585],{"type":52,"value":19699},{"type":46,"tag":250,"props":21587,"children":21588},{"class":252,"line":9963},[21589,21593],{"type":46,"tag":250,"props":21590,"children":21591},{"style":375},[21592],{"type":52,"value":9969},{"type":46,"tag":250,"props":21594,"children":21595},{"style":268},[21596],{"type":52,"value":19711},{"type":46,"tag":250,"props":21598,"children":21599},{"class":252,"line":9991},[21600,21604],{"type":46,"tag":250,"props":21601,"children":21602},{"style":375},[21603],{"type":52,"value":19719},{"type":46,"tag":250,"props":21605,"children":21606},{"style":268},[21607],{"type":52,"value":19724},{"type":46,"tag":250,"props":21609,"children":21610},{"class":252,"line":10017},[21611,21615,21619,21623,21627,21631,21635,21639],{"type":46,"tag":250,"props":21612,"children":21613},{"style":375},[21614],{"type":52,"value":10023},{"type":46,"tag":250,"props":21616,"children":21617},{"style":274},[21618],{"type":52,"value":19498},{"type":46,"tag":250,"props":21620,"children":21621},{"style":268},[21622],{"type":52,"value":106},{"type":46,"tag":250,"props":21624,"children":21625},{"style":274},[21626],{"type":52,"value":19389},{"type":46,"tag":250,"props":21628,"children":21629},{"style":375},[21630],{"type":52,"value":10041},{"type":46,"tag":250,"props":21632,"children":21633},{"style":274},[21634],{"type":52,"value":19752},{"type":46,"tag":250,"props":21636,"children":21637},{"style":268},[21638],{"type":52,"value":106},{"type":46,"tag":250,"props":21640,"children":21641},{"style":274},[21642],{"type":52,"value":19761},{"type":46,"tag":250,"props":21644,"children":21645},{"class":252,"line":10058},[21646,21650,21654,21658,21662,21666,21670,21674,21678],{"type":46,"tag":250,"props":21647,"children":21648},{"style":375},[21649],{"type":52,"value":15970},{"type":46,"tag":250,"props":21651,"children":21652},{"style":274},[21653],{"type":52,"value":19498},{"type":46,"tag":250,"props":21655,"children":21656},{"style":268},[21657],{"type":52,"value":106},{"type":46,"tag":250,"props":21659,"children":21660},{"style":274},[21661],{"type":52,"value":19389},{"type":46,"tag":250,"props":21663,"children":21664},{"style":268},[21665],{"type":52,"value":151},{"type":46,"tag":250,"props":21667,"children":21668},{"style":274},[21669],{"type":52,"value":19548},{"type":46,"tag":250,"props":21671,"children":21672},{"style":268},[21673],{"type":52,"value":106},{"type":46,"tag":250,"props":21675,"children":21676},{"style":274},[21677],{"type":52,"value":19410},{"type":46,"tag":250,"props":21679,"children":21680},{"style":268},[21681],{"type":52,"value":19801},{"type":46,"tag":250,"props":21683,"children":21684},{"class":252,"line":10936},[21685,21689,21693,21697,21701],{"type":46,"tag":250,"props":21686,"children":21687},{"style":375},[21688],{"type":52,"value":17462},{"type":46,"tag":250,"props":21690,"children":21691},{"style":274},[21692],{"type":52,"value":19498},{"type":46,"tag":250,"props":21694,"children":21695},{"style":268},[21696],{"type":52,"value":106},{"type":46,"tag":250,"props":21698,"children":21699},{"style":274},[21700],{"type":52,"value":19389},{"type":46,"tag":250,"props":21702,"children":21703},{"style":268},[21704],{"type":52,"value":19801},{"type":46,"tag":220,"props":21706,"children":21708},{"id":21707},"_3-product-performance-rpt_product_performancesql",[21709,21711],{"type":52,"value":21710},"3) Product performance - ",{"type":46,"tag":99,"props":21712,"children":21714},{"className":21713},[],[21715],{"type":52,"value":21716},"rpt_product_performance.sql",{"type":46,"tag":55,"props":21718,"children":21719},{},[21720],{"type":52,"value":21721},"A product catalog report showing all products with their key attributes and status.",{"type":46,"tag":198,"props":21723,"children":21724},{},[21725],{"type":46,"tag":55,"props":21726,"children":21727},{},[21728,21730,21735,21737,21743],{"type":52,"value":21729},"A full product performance report would need an order_line_items staging table to connect orders to individual products. Shopify stores line items as nested JSON in the orders table. For production use, ask Claude Code to create a ",{"type":46,"tag":99,"props":21731,"children":21733},{"className":21732},[],[21734],{"type":52,"value":9030},{"type":52,"value":21736}," asset that flattens this data. This simplified version shows product catalog metrics from ",{"type":46,"tag":99,"props":21738,"children":21740},{"className":21739},[],[21741],{"type":52,"value":21742},"stg_products",{"type":52,"value":106},{"type":46,"tag":55,"props":21745,"children":21746},{},[21747,21748,21757],{"type":52,"value":9155},{"type":46,"tag":80,"props":21749,"children":21750},{},[21751],{"type":46,"tag":99,"props":21752,"children":21754},{"className":21753},[],[21755],{"type":52,"value":21756},"ecommerce\u002Fassets\u002Freports\u002Frpt_product_performance.sql",{"type":52,"value":9166},{"type":46,"tag":240,"props":21759,"children":21761},{"className":9175,"code":21760,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_product_performance\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_products\ncolumns:\n  - name: product_id\n    type: varchar\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nSELECT\n    product_id,\n    product_name,\n    category,\n    vendor,\n    price,\n    product_status,\n    created_at,\n    updated_at\nFROM staging.stg_products\nORDER BY product_name\n",[21762],{"type":46,"tag":99,"props":21763,"children":21764},{"__ignoreMap":7},[21765,21772,21780,21787,21794,21801,21808,21816,21823,21830,21837,21844,21851,21858,21865,21872,21879,21887,21895,21903,21910,21918,21926,21933,21940,21960],{"type":46,"tag":250,"props":21766,"children":21767},{"class":252,"line":23},[21768],{"type":46,"tag":250,"props":21769,"children":21770},{"style":9187},[21771],{"type":52,"value":9190},{"type":46,"tag":250,"props":21773,"children":21774},{"class":252,"line":285},[21775],{"type":46,"tag":250,"props":21776,"children":21777},{"style":9187},[21778],{"type":52,"value":21779},"name: reports.rpt_product_performance\n",{"type":46,"tag":250,"props":21781,"children":21782},{"class":252,"line":299},[21783],{"type":46,"tag":250,"props":21784,"children":21785},{"style":9187},[21786],{"type":52,"value":9206},{"type":46,"tag":250,"props":21788,"children":21789},{"class":252,"line":807},[21790],{"type":46,"tag":250,"props":21791,"children":21792},{"style":9187},[21793],{"type":52,"value":9214},{"type":46,"tag":250,"props":21795,"children":21796},{"class":252,"line":820},[21797],{"type":46,"tag":250,"props":21798,"children":21799},{"style":9187},[21800],{"type":52,"value":9222},{"type":46,"tag":250,"props":21802,"children":21803},{"class":252,"line":844},[21804],{"type":46,"tag":250,"props":21805,"children":21806},{"style":9187},[21807],{"type":52,"value":9230},{"type":46,"tag":250,"props":21809,"children":21810},{"class":252,"line":862},[21811],{"type":46,"tag":250,"props":21812,"children":21813},{"style":9187},[21814],{"type":52,"value":21815},"  - staging.stg_products\n",{"type":46,"tag":250,"props":21817,"children":21818},{"class":252,"line":11},[21819],{"type":46,"tag":250,"props":21820,"children":21821},{"style":9187},[21822],{"type":52,"value":9254},{"type":46,"tag":250,"props":21824,"children":21825},{"class":252,"line":4649},[21826],{"type":46,"tag":250,"props":21827,"children":21828},{"style":9187},[21829],{"type":52,"value":12892},{"type":46,"tag":250,"props":21831,"children":21832},{"class":252,"line":9257},[21833],{"type":46,"tag":250,"props":21834,"children":21835},{"style":9187},[21836],{"type":52,"value":9272},{"type":46,"tag":250,"props":21838,"children":21839},{"class":252,"line":9266},[21840],{"type":46,"tag":250,"props":21841,"children":21842},{"style":9187},[21843],{"type":52,"value":9281},{"type":46,"tag":250,"props":21845,"children":21846},{"class":252,"line":9275},[21847],{"type":46,"tag":250,"props":21848,"children":21849},{"style":9187},[21850],{"type":52,"value":9290},{"type":46,"tag":250,"props":21852,"children":21853},{"class":252,"line":9284},[21854],{"type":46,"tag":250,"props":21855,"children":21856},{"style":9187},[21857],{"type":52,"value":9299},{"type":46,"tag":250,"props":21859,"children":21860},{"class":252,"line":9293},[21861],{"type":46,"tag":250,"props":21862,"children":21863},{"style":9187},[21864],{"type":52,"value":9377},{"type":46,"tag":250,"props":21866,"children":21867},{"class":252,"line":4121},[21868],{"type":46,"tag":250,"props":21869,"children":21870},{"emptyLinePlaceholder":22},[21871],{"type":52,"value":9386},{"type":46,"tag":250,"props":21873,"children":21874},{"class":252,"line":9310},[21875],{"type":46,"tag":250,"props":21876,"children":21877},{"style":375},[21878],{"type":52,"value":9395},{"type":46,"tag":250,"props":21880,"children":21881},{"class":252,"line":9319},[21882],{"type":46,"tag":250,"props":21883,"children":21884},{"style":268},[21885],{"type":52,"value":21886},"    product_id,\n",{"type":46,"tag":250,"props":21888,"children":21889},{"class":252,"line":9327},[21890],{"type":46,"tag":250,"props":21891,"children":21892},{"style":268},[21893],{"type":52,"value":21894},"    product_name,\n",{"type":46,"tag":250,"props":21896,"children":21897},{"class":252,"line":9335},[21898],{"type":46,"tag":250,"props":21899,"children":21900},{"style":268},[21901],{"type":52,"value":21902},"    category,\n",{"type":46,"tag":250,"props":21904,"children":21905},{"class":252,"line":9344},[21906],{"type":46,"tag":250,"props":21907,"children":21908},{"style":268},[21909],{"type":52,"value":13000},{"type":46,"tag":250,"props":21911,"children":21912},{"class":252,"line":9353},[21913],{"type":46,"tag":250,"props":21914,"children":21915},{"style":268},[21916],{"type":52,"value":21917},"    price,\n",{"type":46,"tag":250,"props":21919,"children":21920},{"class":252,"line":9362},[21921],{"type":46,"tag":250,"props":21922,"children":21923},{"style":268},[21924],{"type":52,"value":21925},"    product_status,\n",{"type":46,"tag":250,"props":21927,"children":21928},{"class":252,"line":9371},[21929],{"type":46,"tag":250,"props":21930,"children":21931},{"style":268},[21932],{"type":52,"value":13087},{"type":46,"tag":250,"props":21934,"children":21935},{"class":252,"line":9380},[21936],{"type":46,"tag":250,"props":21937,"children":21938},{"style":268},[21939],{"type":52,"value":13095},{"type":46,"tag":250,"props":21941,"children":21942},{"class":252,"line":9389},[21943,21947,21951,21955],{"type":46,"tag":250,"props":21944,"children":21945},{"style":375},[21946],{"type":52,"value":9969},{"type":46,"tag":250,"props":21948,"children":21949},{"style":274},[21950],{"type":52,"value":17433},{"type":46,"tag":250,"props":21952,"children":21953},{"style":268},[21954],{"type":52,"value":106},{"type":46,"tag":250,"props":21956,"children":21957},{"style":274},[21958],{"type":52,"value":21959},"stg_products\n",{"type":46,"tag":250,"props":21961,"children":21962},{"class":252,"line":9398},[21963,21967],{"type":46,"tag":250,"props":21964,"children":21965},{"style":375},[21966],{"type":52,"value":17462},{"type":46,"tag":250,"props":21968,"children":21969},{"style":268},[21970],{"type":52,"value":21971}," product_name\n",{"type":46,"tag":220,"props":21973,"children":21975},{"id":21974},"_4-marketing-roi-rpt_marketing_roisql",[21976,21978],{"type":52,"value":21977},"4) Marketing ROI - ",{"type":46,"tag":99,"props":21979,"children":21981},{"className":21980},[],[21982],{"type":52,"value":21983},"rpt_marketing_roi.sql",{"type":46,"tag":55,"props":21985,"children":21986},{},[21987],{"type":52,"value":21988},"Spend, revenue, and ROAS by marketing channel. This is the report that answers \"where should we spend more?\"",{"type":46,"tag":55,"props":21990,"children":21991},{},[21992,21993,22002],{"type":52,"value":9155},{"type":46,"tag":80,"props":21994,"children":21995},{},[21996],{"type":46,"tag":99,"props":21997,"children":21999},{"className":21998},[],[22000],{"type":52,"value":22001},"ecommerce\u002Fassets\u002Freports\u002Frpt_marketing_roi.sql",{"type":52,"value":9166},{"type":46,"tag":423,"props":22004,"children":22005},{":variants":425,"group":426},[22006,23368,24663],{"type":46,"tag":429,"props":22007,"children":22008},{"v-slot:clickhouse":7},[22009],{"type":46,"tag":240,"props":22010,"children":22012},{"className":9175,"code":22011,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_marketing_roi\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_marketing_spend\n  - staging.stg_web_sessions\n  - staging.stg_orders\ncolumns:\n  - name: channel\n    type: varchar\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH channel_spend AS (\n    SELECT\n        spend_date,\n        channel,\n        sum(spend) AS total_spend,\n        sum(impressions) AS total_impressions,\n        sum(clicks) AS total_clicks,\n        sum(conversions) AS total_conversions\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date, channel\n),\nchannel_sessions AS (\n    SELECT\n        session_date,\n        channel,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_users,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date, channel\n),\nchannel_revenue AS (\n    SELECT\n        toDate(order_date) AS order_date,\n        ws.channel,\n        sum(o.order_total) AS attributed_revenue\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_web_sessions ws\n        ON toDate(o.order_date) = ws.session_date\n    WHERE o.payment_status = 'paid'\n    GROUP BY toDate(order_date), ws.channel\n)\nSELECT\n    cs.spend_date AS report_date,\n    cs.channel,\n    cs.total_spend,\n    cs.total_impressions,\n    cs.total_clicks,\n    cs.total_conversions,\n    sess.sessions,\n    sess.new_users,\n    cr.attributed_revenue,\n    round(cr.attributed_revenue \u002F nullIf(cs.total_spend, 0), 2) AS roas,\n    round(cs.total_spend \u002F nullIf(cs.total_conversions, 0), 2) AS cost_per_acquisition,\n    round(cs.total_clicks \u002F nullIf(cs.total_impressions, 0) * 100, 2) AS click_through_rate\nFROM channel_spend cs\nLEFT JOIN channel_sessions sess\n    ON cs.spend_date = sess.session_date\n    AND cs.channel = sess.channel\nLEFT JOIN channel_revenue cr\n    ON cs.spend_date = cr.order_date\n    AND cs.channel = cr.channel\nORDER BY cs.spend_date DESC, cs.total_spend DESC\n",[22013],{"type":46,"tag":99,"props":22014,"children":22015},{"__ignoreMap":7},[22016,22023,22031,22038,22045,22052,22059,22067,22075,22082,22089,22097,22104,22111,22118,22125,22132,22152,22159,22167,22175,22197,22218,22239,22260,22280,22292,22299,22315,22322,22330,22337,22362,22382,22403,22423,22435,22442,22458,22465,22481,22502,22538,22561,22586,22631,22658,22684,22692,22700,22726,22746,22767,22788,22809,22830,22851,22871,22893,22971,23048,23137,23150,23163,23200,23236,23249,23287,23323],{"type":46,"tag":250,"props":22017,"children":22018},{"class":252,"line":23},[22019],{"type":46,"tag":250,"props":22020,"children":22021},{"style":9187},[22022],{"type":52,"value":9190},{"type":46,"tag":250,"props":22024,"children":22025},{"class":252,"line":285},[22026],{"type":46,"tag":250,"props":22027,"children":22028},{"style":9187},[22029],{"type":52,"value":22030},"name: reports.rpt_marketing_roi\n",{"type":46,"tag":250,"props":22032,"children":22033},{"class":252,"line":299},[22034],{"type":46,"tag":250,"props":22035,"children":22036},{"style":9187},[22037],{"type":52,"value":9206},{"type":46,"tag":250,"props":22039,"children":22040},{"class":252,"line":807},[22041],{"type":46,"tag":250,"props":22042,"children":22043},{"style":9187},[22044],{"type":52,"value":9214},{"type":46,"tag":250,"props":22046,"children":22047},{"class":252,"line":820},[22048],{"type":46,"tag":250,"props":22049,"children":22050},{"style":9187},[22051],{"type":52,"value":9222},{"type":46,"tag":250,"props":22053,"children":22054},{"class":252,"line":844},[22055],{"type":46,"tag":250,"props":22056,"children":22057},{"style":9187},[22058],{"type":52,"value":9230},{"type":46,"tag":250,"props":22060,"children":22061},{"class":252,"line":862},[22062],{"type":46,"tag":250,"props":22063,"children":22064},{"style":9187},[22065],{"type":52,"value":22066},"  - staging.stg_marketing_spend\n",{"type":46,"tag":250,"props":22068,"children":22069},{"class":252,"line":11},[22070],{"type":46,"tag":250,"props":22071,"children":22072},{"style":9187},[22073],{"type":52,"value":22074},"  - staging.stg_web_sessions\n",{"type":46,"tag":250,"props":22076,"children":22077},{"class":252,"line":4649},[22078],{"type":46,"tag":250,"props":22079,"children":22080},{"style":9187},[22081],{"type":52,"value":16980},{"type":46,"tag":250,"props":22083,"children":22084},{"class":252,"line":9257},[22085],{"type":46,"tag":250,"props":22086,"children":22087},{"style":9187},[22088],{"type":52,"value":9254},{"type":46,"tag":250,"props":22090,"children":22091},{"class":252,"line":9266},[22092],{"type":46,"tag":250,"props":22093,"children":22094},{"style":9187},[22095],{"type":52,"value":22096},"  - name: channel\n",{"type":46,"tag":250,"props":22098,"children":22099},{"class":252,"line":9275},[22100],{"type":46,"tag":250,"props":22101,"children":22102},{"style":9187},[22103],{"type":52,"value":9272},{"type":46,"tag":250,"props":22105,"children":22106},{"class":252,"line":9284},[22107],{"type":46,"tag":250,"props":22108,"children":22109},{"style":9187},[22110],{"type":52,"value":9281},{"type":46,"tag":250,"props":22112,"children":22113},{"class":252,"line":9293},[22114],{"type":46,"tag":250,"props":22115,"children":22116},{"style":9187},[22117],{"type":52,"value":9290},{"type":46,"tag":250,"props":22119,"children":22120},{"class":252,"line":4121},[22121],{"type":46,"tag":250,"props":22122,"children":22123},{"style":9187},[22124],{"type":52,"value":9377},{"type":46,"tag":250,"props":22126,"children":22127},{"class":252,"line":9310},[22128],{"type":46,"tag":250,"props":22129,"children":22130},{"emptyLinePlaceholder":22},[22131],{"type":52,"value":9386},{"type":46,"tag":250,"props":22133,"children":22134},{"class":252,"line":9319},[22135,22139,22144,22148],{"type":46,"tag":250,"props":22136,"children":22137},{"style":375},[22138],{"type":52,"value":19021},{"type":46,"tag":250,"props":22140,"children":22141},{"style":268},[22142],{"type":52,"value":22143}," channel_spend ",{"type":46,"tag":250,"props":22145,"children":22146},{"style":375},[22147],{"type":52,"value":9608},{"type":46,"tag":250,"props":22149,"children":22150},{"style":268},[22151],{"type":52,"value":19035},{"type":46,"tag":250,"props":22153,"children":22154},{"class":252,"line":9327},[22155],{"type":46,"tag":250,"props":22156,"children":22157},{"style":375},[22158],{"type":52,"value":19043},{"type":46,"tag":250,"props":22160,"children":22161},{"class":252,"line":9335},[22162],{"type":46,"tag":250,"props":22163,"children":22164},{"style":268},[22165],{"type":52,"value":22166},"        spend_date,\n",{"type":46,"tag":250,"props":22168,"children":22169},{"class":252,"line":9344},[22170],{"type":46,"tag":250,"props":22171,"children":22172},{"style":268},[22173],{"type":52,"value":22174},"        channel,\n",{"type":46,"tag":250,"props":22176,"children":22177},{"class":252,"line":9353},[22178,22183,22188,22192],{"type":46,"tag":250,"props":22179,"children":22180},{"style":274},[22181],{"type":52,"value":22182},"        sum",{"type":46,"tag":250,"props":22184,"children":22185},{"style":268},[22186],{"type":52,"value":22187},"(spend) ",{"type":46,"tag":250,"props":22189,"children":22190},{"style":375},[22191],{"type":52,"value":9608},{"type":46,"tag":250,"props":22193,"children":22194},{"style":268},[22195],{"type":52,"value":22196}," total_spend,\n",{"type":46,"tag":250,"props":22198,"children":22199},{"class":252,"line":9362},[22200,22204,22209,22213],{"type":46,"tag":250,"props":22201,"children":22202},{"style":274},[22203],{"type":52,"value":22182},{"type":46,"tag":250,"props":22205,"children":22206},{"style":268},[22207],{"type":52,"value":22208},"(impressions) ",{"type":46,"tag":250,"props":22210,"children":22211},{"style":375},[22212],{"type":52,"value":9608},{"type":46,"tag":250,"props":22214,"children":22215},{"style":268},[22216],{"type":52,"value":22217}," total_impressions,\n",{"type":46,"tag":250,"props":22219,"children":22220},{"class":252,"line":9371},[22221,22225,22230,22234],{"type":46,"tag":250,"props":22222,"children":22223},{"style":274},[22224],{"type":52,"value":22182},{"type":46,"tag":250,"props":22226,"children":22227},{"style":268},[22228],{"type":52,"value":22229},"(clicks) ",{"type":46,"tag":250,"props":22231,"children":22232},{"style":375},[22233],{"type":52,"value":9608},{"type":46,"tag":250,"props":22235,"children":22236},{"style":268},[22237],{"type":52,"value":22238}," total_clicks,\n",{"type":46,"tag":250,"props":22240,"children":22241},{"class":252,"line":9380},[22242,22246,22251,22255],{"type":46,"tag":250,"props":22243,"children":22244},{"style":274},[22245],{"type":52,"value":22182},{"type":46,"tag":250,"props":22247,"children":22248},{"style":268},[22249],{"type":52,"value":22250},"(conversions) ",{"type":46,"tag":250,"props":22252,"children":22253},{"style":375},[22254],{"type":52,"value":9608},{"type":46,"tag":250,"props":22256,"children":22257},{"style":268},[22258],{"type":52,"value":22259}," total_conversions\n",{"type":46,"tag":250,"props":22261,"children":22262},{"class":252,"line":9389},[22263,22267,22271,22275],{"type":46,"tag":250,"props":22264,"children":22265},{"style":375},[22266],{"type":52,"value":19155},{"type":46,"tag":250,"props":22268,"children":22269},{"style":274},[22270],{"type":52,"value":17433},{"type":46,"tag":250,"props":22272,"children":22273},{"style":268},[22274],{"type":52,"value":106},{"type":46,"tag":250,"props":22276,"children":22277},{"style":274},[22278],{"type":52,"value":22279},"stg_marketing_spend\n",{"type":46,"tag":250,"props":22281,"children":22282},{"class":252,"line":9398},[22283,22287],{"type":46,"tag":250,"props":22284,"children":22285},{"style":375},[22286],{"type":52,"value":19353},{"type":46,"tag":250,"props":22288,"children":22289},{"style":268},[22290],{"type":52,"value":22291}," spend_date, channel\n",{"type":46,"tag":250,"props":22293,"children":22294},{"class":252,"line":9426},[22295],{"type":46,"tag":250,"props":22296,"children":22297},{"style":268},[22298],{"type":52,"value":19271},{"type":46,"tag":250,"props":22300,"children":22301},{"class":252,"line":9448},[22302,22307,22311],{"type":46,"tag":250,"props":22303,"children":22304},{"style":268},[22305],{"type":52,"value":22306},"channel_sessions ",{"type":46,"tag":250,"props":22308,"children":22309},{"style":375},[22310],{"type":52,"value":9608},{"type":46,"tag":250,"props":22312,"children":22313},{"style":268},[22314],{"type":52,"value":19035},{"type":46,"tag":250,"props":22316,"children":22317},{"class":252,"line":9474},[22318],{"type":46,"tag":250,"props":22319,"children":22320},{"style":375},[22321],{"type":52,"value":19043},{"type":46,"tag":250,"props":22323,"children":22324},{"class":252,"line":9500},[22325],{"type":46,"tag":250,"props":22326,"children":22327},{"style":268},[22328],{"type":52,"value":22329},"        session_date,\n",{"type":46,"tag":250,"props":22331,"children":22332},{"class":252,"line":9525},[22333],{"type":46,"tag":250,"props":22334,"children":22335},{"style":268},[22336],{"type":52,"value":22174},{"type":46,"tag":250,"props":22338,"children":22339},{"class":252,"line":9546},[22340,22344,22349,22353,22358],{"type":46,"tag":250,"props":22341,"children":22342},{"style":274},[22343],{"type":52,"value":22182},{"type":46,"tag":250,"props":22345,"children":22346},{"style":268},[22347],{"type":52,"value":22348},"(total_sessions) ",{"type":46,"tag":250,"props":22350,"children":22351},{"style":375},[22352],{"type":52,"value":9608},{"type":46,"tag":250,"props":22354,"children":22355},{"style":375},[22356],{"type":52,"value":22357}," sessions",{"type":46,"tag":250,"props":22359,"children":22360},{"style":268},[22361],{"type":52,"value":9445},{"type":46,"tag":250,"props":22363,"children":22364},{"class":252,"line":9616},[22365,22369,22374,22378],{"type":46,"tag":250,"props":22366,"children":22367},{"style":274},[22368],{"type":52,"value":22182},{"type":46,"tag":250,"props":22370,"children":22371},{"style":268},[22372],{"type":52,"value":22373},"(new_users) ",{"type":46,"tag":250,"props":22375,"children":22376},{"style":375},[22377],{"type":52,"value":9608},{"type":46,"tag":250,"props":22379,"children":22380},{"style":268},[22381],{"type":52,"value":15604},{"type":46,"tag":250,"props":22383,"children":22384},{"class":252,"line":9678},[22385,22389,22394,22398],{"type":46,"tag":250,"props":22386,"children":22387},{"style":274},[22388],{"type":52,"value":22182},{"type":46,"tag":250,"props":22390,"children":22391},{"style":268},[22392],{"type":52,"value":22393},"(purchase_events) ",{"type":46,"tag":250,"props":22395,"children":22396},{"style":375},[22397],{"type":52,"value":9608},{"type":46,"tag":250,"props":22399,"children":22400},{"style":268},[22401],{"type":52,"value":22402}," purchases\n",{"type":46,"tag":250,"props":22404,"children":22405},{"class":252,"line":9740},[22406,22410,22414,22418],{"type":46,"tag":250,"props":22407,"children":22408},{"style":375},[22409],{"type":52,"value":19155},{"type":46,"tag":250,"props":22411,"children":22412},{"style":274},[22413],{"type":52,"value":17433},{"type":46,"tag":250,"props":22415,"children":22416},{"style":268},[22417],{"type":52,"value":106},{"type":46,"tag":250,"props":22419,"children":22420},{"style":274},[22421],{"type":52,"value":22422},"stg_web_sessions\n",{"type":46,"tag":250,"props":22424,"children":22425},{"class":252,"line":9802},[22426,22430],{"type":46,"tag":250,"props":22427,"children":22428},{"style":375},[22429],{"type":52,"value":19353},{"type":46,"tag":250,"props":22431,"children":22432},{"style":268},[22433],{"type":52,"value":22434}," session_date, channel\n",{"type":46,"tag":250,"props":22436,"children":22437},{"class":252,"line":9823},[22438],{"type":46,"tag":250,"props":22439,"children":22440},{"style":268},[22441],{"type":52,"value":19271},{"type":46,"tag":250,"props":22443,"children":22444},{"class":252,"line":9844},[22445,22450,22454],{"type":46,"tag":250,"props":22446,"children":22447},{"style":268},[22448],{"type":52,"value":22449},"channel_revenue ",{"type":46,"tag":250,"props":22451,"children":22452},{"style":375},[22453],{"type":52,"value":9608},{"type":46,"tag":250,"props":22455,"children":22456},{"style":268},[22457],{"type":52,"value":19035},{"type":46,"tag":250,"props":22459,"children":22460},{"class":252,"line":9865},[22461],{"type":46,"tag":250,"props":22462,"children":22463},{"style":375},[22464],{"type":52,"value":19043},{"type":46,"tag":250,"props":22466,"children":22467},{"class":252,"line":9911},[22468,22473,22477],{"type":46,"tag":250,"props":22469,"children":22470},{"style":268},[22471],{"type":52,"value":22472},"        toDate(order_date) ",{"type":46,"tag":250,"props":22474,"children":22475},{"style":375},[22476],{"type":52,"value":9608},{"type":46,"tag":250,"props":22478,"children":22479},{"style":268},[22480],{"type":52,"value":9497},{"type":46,"tag":250,"props":22482,"children":22483},{"class":252,"line":9937},[22484,22489,22493,22498],{"type":46,"tag":250,"props":22485,"children":22486},{"style":274},[22487],{"type":52,"value":22488},"        ws",{"type":46,"tag":250,"props":22490,"children":22491},{"style":268},[22492],{"type":52,"value":106},{"type":46,"tag":250,"props":22494,"children":22495},{"style":274},[22496],{"type":52,"value":22497},"channel",{"type":46,"tag":250,"props":22499,"children":22500},{"style":268},[22501],{"type":52,"value":9445},{"type":46,"tag":250,"props":22503,"children":22504},{"class":252,"line":9963},[22505,22509,22513,22517,22521,22525,22529,22533],{"type":46,"tag":250,"props":22506,"children":22507},{"style":274},[22508],{"type":52,"value":22182},{"type":46,"tag":250,"props":22510,"children":22511},{"style":268},[22512],{"type":52,"value":9557},{"type":46,"tag":250,"props":22514,"children":22515},{"style":274},[22516],{"type":52,"value":9562},{"type":46,"tag":250,"props":22518,"children":22519},{"style":268},[22520],{"type":52,"value":106},{"type":46,"tag":250,"props":22522,"children":22523},{"style":274},[22524],{"type":52,"value":19621},{"type":46,"tag":250,"props":22526,"children":22527},{"style":268},[22528],{"type":52,"value":10086},{"type":46,"tag":250,"props":22530,"children":22531},{"style":375},[22532],{"type":52,"value":9608},{"type":46,"tag":250,"props":22534,"children":22535},{"style":268},[22536],{"type":52,"value":22537}," attributed_revenue\n",{"type":46,"tag":250,"props":22539,"children":22540},{"class":252,"line":9991},[22541,22545,22549,22553,22557],{"type":46,"tag":250,"props":22542,"children":22543},{"style":375},[22544],{"type":52,"value":19155},{"type":46,"tag":250,"props":22546,"children":22547},{"style":274},[22548],{"type":52,"value":17433},{"type":46,"tag":250,"props":22550,"children":22551},{"style":268},[22552],{"type":52,"value":106},{"type":46,"tag":250,"props":22554,"children":22555},{"style":274},[22556],{"type":52,"value":18055},{"type":46,"tag":250,"props":22558,"children":22559},{"style":268},[22560],{"type":52,"value":9988},{"type":46,"tag":250,"props":22562,"children":22563},{"class":252,"line":10017},[22564,22568,22572,22576,22581],{"type":46,"tag":250,"props":22565,"children":22566},{"style":375},[22567],{"type":52,"value":19179},{"type":46,"tag":250,"props":22569,"children":22570},{"style":274},[22571],{"type":52,"value":17433},{"type":46,"tag":250,"props":22573,"children":22574},{"style":268},[22575],{"type":52,"value":106},{"type":46,"tag":250,"props":22577,"children":22578},{"style":274},[22579],{"type":52,"value":22580},"stg_web_sessions",{"type":46,"tag":250,"props":22582,"children":22583},{"style":268},[22584],{"type":52,"value":22585}," ws\n",{"type":46,"tag":250,"props":22587,"children":22588},{"class":252,"line":10058},[22589,22593,22597,22601,22605,22609,22613,22617,22622,22626],{"type":46,"tag":250,"props":22590,"children":22591},{"style":375},[22592],{"type":52,"value":19204},{"type":46,"tag":250,"props":22594,"children":22595},{"style":268},[22596],{"type":52,"value":10069},{"type":46,"tag":250,"props":22598,"children":22599},{"style":274},[22600],{"type":52,"value":9562},{"type":46,"tag":250,"props":22602,"children":22603},{"style":268},[22604],{"type":52,"value":106},{"type":46,"tag":250,"props":22606,"children":22607},{"style":274},[22608],{"type":52,"value":19118},{"type":46,"tag":250,"props":22610,"children":22611},{"style":268},[22612],{"type":52,"value":10086},{"type":46,"tag":250,"props":22614,"children":22615},{"style":375},[22616],{"type":52,"value":10091},{"type":46,"tag":250,"props":22618,"children":22619},{"style":274},[22620],{"type":52,"value":22621}," ws",{"type":46,"tag":250,"props":22623,"children":22624},{"style":268},[22625],{"type":52,"value":106},{"type":46,"tag":250,"props":22627,"children":22628},{"style":274},[22629],{"type":52,"value":22630},"session_date\n",{"type":46,"tag":250,"props":22632,"children":22633},{"class":252,"line":10936},[22634,22638,22642,22646,22650,22654],{"type":46,"tag":250,"props":22635,"children":22636},{"style":375},[22637],{"type":52,"value":19241},{"type":46,"tag":250,"props":22639,"children":22640},{"style":274},[22641],{"type":52,"value":10028},{"type":46,"tag":250,"props":22643,"children":22644},{"style":268},[22645],{"type":52,"value":106},{"type":46,"tag":250,"props":22647,"children":22648},{"style":274},[22649],{"type":52,"value":19254},{"type":46,"tag":250,"props":22651,"children":22652},{"style":375},[22653],{"type":52,"value":10041},{"type":46,"tag":250,"props":22655,"children":22656},{"style":262},[22657],{"type":52,"value":19263},{"type":46,"tag":250,"props":22659,"children":22660},{"class":252,"line":10995},[22661,22665,22670,22675,22679],{"type":46,"tag":250,"props":22662,"children":22663},{"style":375},[22664],{"type":52,"value":19353},{"type":46,"tag":250,"props":22666,"children":22667},{"style":268},[22668],{"type":52,"value":22669}," toDate(order_date), ",{"type":46,"tag":250,"props":22671,"children":22672},{"style":274},[22673],{"type":52,"value":22674},"ws",{"type":46,"tag":250,"props":22676,"children":22677},{"style":268},[22678],{"type":52,"value":106},{"type":46,"tag":250,"props":22680,"children":22681},{"style":274},[22682],{"type":52,"value":22683},"channel\n",{"type":46,"tag":250,"props":22685,"children":22687},{"class":252,"line":22686},48,[22688],{"type":46,"tag":250,"props":22689,"children":22690},{"style":268},[22691],{"type":52,"value":10114},{"type":46,"tag":250,"props":22693,"children":22695},{"class":252,"line":22694},49,[22696],{"type":46,"tag":250,"props":22697,"children":22698},{"style":375},[22699],{"type":52,"value":9395},{"type":46,"tag":250,"props":22701,"children":22703},{"class":252,"line":22702},50,[22704,22708,22712,22717,22721],{"type":46,"tag":250,"props":22705,"children":22706},{"style":274},[22707],{"type":52,"value":19401},{"type":46,"tag":250,"props":22709,"children":22710},{"style":268},[22711],{"type":52,"value":106},{"type":46,"tag":250,"props":22713,"children":22714},{"style":274},[22715],{"type":52,"value":22716},"spend_date",{"type":46,"tag":250,"props":22718,"children":22719},{"style":375},[22720],{"type":52,"value":9418},{"type":46,"tag":250,"props":22722,"children":22723},{"style":268},[22724],{"type":52,"value":22725}," report_date,\n",{"type":46,"tag":250,"props":22727,"children":22729},{"class":252,"line":22728},51,[22730,22734,22738,22742],{"type":46,"tag":250,"props":22731,"children":22732},{"style":274},[22733],{"type":52,"value":19401},{"type":46,"tag":250,"props":22735,"children":22736},{"style":268},[22737],{"type":52,"value":106},{"type":46,"tag":250,"props":22739,"children":22740},{"style":274},[22741],{"type":52,"value":22497},{"type":46,"tag":250,"props":22743,"children":22744},{"style":268},[22745],{"type":52,"value":9445},{"type":46,"tag":250,"props":22747,"children":22749},{"class":252,"line":22748},52,[22750,22754,22758,22763],{"type":46,"tag":250,"props":22751,"children":22752},{"style":274},[22753],{"type":52,"value":19401},{"type":46,"tag":250,"props":22755,"children":22756},{"style":268},[22757],{"type":52,"value":106},{"type":46,"tag":250,"props":22759,"children":22760},{"style":274},[22761],{"type":52,"value":22762},"total_spend",{"type":46,"tag":250,"props":22764,"children":22765},{"style":268},[22766],{"type":52,"value":9445},{"type":46,"tag":250,"props":22768,"children":22770},{"class":252,"line":22769},53,[22771,22775,22779,22784],{"type":46,"tag":250,"props":22772,"children":22773},{"style":274},[22774],{"type":52,"value":19401},{"type":46,"tag":250,"props":22776,"children":22777},{"style":268},[22778],{"type":52,"value":106},{"type":46,"tag":250,"props":22780,"children":22781},{"style":274},[22782],{"type":52,"value":22783},"total_impressions",{"type":46,"tag":250,"props":22785,"children":22786},{"style":268},[22787],{"type":52,"value":9445},{"type":46,"tag":250,"props":22789,"children":22791},{"class":252,"line":22790},54,[22792,22796,22800,22805],{"type":46,"tag":250,"props":22793,"children":22794},{"style":274},[22795],{"type":52,"value":19401},{"type":46,"tag":250,"props":22797,"children":22798},{"style":268},[22799],{"type":52,"value":106},{"type":46,"tag":250,"props":22801,"children":22802},{"style":274},[22803],{"type":52,"value":22804},"total_clicks",{"type":46,"tag":250,"props":22806,"children":22807},{"style":268},[22808],{"type":52,"value":9445},{"type":46,"tag":250,"props":22810,"children":22812},{"class":252,"line":22811},55,[22813,22817,22821,22826],{"type":46,"tag":250,"props":22814,"children":22815},{"style":274},[22816],{"type":52,"value":19401},{"type":46,"tag":250,"props":22818,"children":22819},{"style":268},[22820],{"type":52,"value":106},{"type":46,"tag":250,"props":22822,"children":22823},{"style":274},[22824],{"type":52,"value":22825},"total_conversions",{"type":46,"tag":250,"props":22827,"children":22828},{"style":268},[22829],{"type":52,"value":9445},{"type":46,"tag":250,"props":22831,"children":22833},{"class":252,"line":22832},56,[22834,22839,22843,22847],{"type":46,"tag":250,"props":22835,"children":22836},{"style":274},[22837],{"type":52,"value":22838},"    sess",{"type":46,"tag":250,"props":22840,"children":22841},{"style":268},[22842],{"type":52,"value":106},{"type":46,"tag":250,"props":22844,"children":22845},{"style":274},[22846],{"type":52,"value":15030},{"type":46,"tag":250,"props":22848,"children":22849},{"style":268},[22850],{"type":52,"value":9445},{"type":46,"tag":250,"props":22852,"children":22854},{"class":252,"line":22853},57,[22855,22859,22863,22867],{"type":46,"tag":250,"props":22856,"children":22857},{"style":274},[22858],{"type":52,"value":22838},{"type":46,"tag":250,"props":22860,"children":22861},{"style":268},[22862],{"type":52,"value":106},{"type":46,"tag":250,"props":22864,"children":22865},{"style":274},[22866],{"type":52,"value":15055},{"type":46,"tag":250,"props":22868,"children":22869},{"style":268},[22870],{"type":52,"value":9445},{"type":46,"tag":250,"props":22872,"children":22874},{"class":252,"line":22873},58,[22875,22880,22884,22889],{"type":46,"tag":250,"props":22876,"children":22877},{"style":274},[22878],{"type":52,"value":22879},"    cr",{"type":46,"tag":250,"props":22881,"children":22882},{"style":268},[22883],{"type":52,"value":106},{"type":46,"tag":250,"props":22885,"children":22886},{"style":274},[22887],{"type":52,"value":22888},"attributed_revenue",{"type":46,"tag":250,"props":22890,"children":22891},{"style":268},[22892],{"type":52,"value":9445},{"type":46,"tag":250,"props":22894,"children":22896},{"class":252,"line":22895},59,[22897,22901,22905,22910,22914,22918,22922,22926,22930,22934,22938,22942,22946,22950,22954,22958,22962,22966],{"type":46,"tag":250,"props":22898,"children":22899},{"style":274},[22900],{"type":52,"value":17313},{"type":46,"tag":250,"props":22902,"children":22903},{"style":268},[22904],{"type":52,"value":9557},{"type":46,"tag":250,"props":22906,"children":22907},{"style":274},[22908],{"type":52,"value":22909},"cr",{"type":46,"tag":250,"props":22911,"children":22912},{"style":268},[22913],{"type":52,"value":106},{"type":46,"tag":250,"props":22915,"children":22916},{"style":274},[22917],{"type":52,"value":22888},{"type":46,"tag":250,"props":22919,"children":22920},{"style":375},[22921],{"type":52,"value":9885},{"type":46,"tag":250,"props":22923,"children":22924},{"style":274},[22925],{"type":52,"value":17328},{"type":46,"tag":250,"props":22927,"children":22928},{"style":268},[22929],{"type":52,"value":9557},{"type":46,"tag":250,"props":22931,"children":22932},{"style":274},[22933],{"type":52,"value":19548},{"type":46,"tag":250,"props":22935,"children":22936},{"style":268},[22937],{"type":52,"value":106},{"type":46,"tag":250,"props":22939,"children":22940},{"style":274},[22941],{"type":52,"value":22762},{"type":46,"tag":250,"props":22943,"children":22944},{"style":268},[22945],{"type":52,"value":151},{"type":46,"tag":250,"props":22947,"children":22948},{"style":274},[22949],{"type":52,"value":9899},{"type":46,"tag":250,"props":22951,"children":22952},{"style":268},[22953],{"type":52,"value":17342},{"type":46,"tag":250,"props":22955,"children":22956},{"style":274},[22957],{"type":52,"value":9598},{"type":46,"tag":250,"props":22959,"children":22960},{"style":268},[22961],{"type":52,"value":10086},{"type":46,"tag":250,"props":22963,"children":22964},{"style":375},[22965],{"type":52,"value":9608},{"type":46,"tag":250,"props":22967,"children":22968},{"style":268},[22969],{"type":52,"value":22970}," roas,\n",{"type":46,"tag":250,"props":22972,"children":22974},{"class":252,"line":22973},60,[22975,22979,22983,22987,22991,22995,22999,23003,23007,23011,23015,23019,23023,23027,23031,23035,23039,23043],{"type":46,"tag":250,"props":22976,"children":22977},{"style":274},[22978],{"type":52,"value":17313},{"type":46,"tag":250,"props":22980,"children":22981},{"style":268},[22982],{"type":52,"value":9557},{"type":46,"tag":250,"props":22984,"children":22985},{"style":274},[22986],{"type":52,"value":19548},{"type":46,"tag":250,"props":22988,"children":22989},{"style":268},[22990],{"type":52,"value":106},{"type":46,"tag":250,"props":22992,"children":22993},{"style":274},[22994],{"type":52,"value":22762},{"type":46,"tag":250,"props":22996,"children":22997},{"style":375},[22998],{"type":52,"value":9885},{"type":46,"tag":250,"props":23000,"children":23001},{"style":274},[23002],{"type":52,"value":17328},{"type":46,"tag":250,"props":23004,"children":23005},{"style":268},[23006],{"type":52,"value":9557},{"type":46,"tag":250,"props":23008,"children":23009},{"style":274},[23010],{"type":52,"value":19548},{"type":46,"tag":250,"props":23012,"children":23013},{"style":268},[23014],{"type":52,"value":106},{"type":46,"tag":250,"props":23016,"children":23017},{"style":274},[23018],{"type":52,"value":22825},{"type":46,"tag":250,"props":23020,"children":23021},{"style":268},[23022],{"type":52,"value":151},{"type":46,"tag":250,"props":23024,"children":23025},{"style":274},[23026],{"type":52,"value":9899},{"type":46,"tag":250,"props":23028,"children":23029},{"style":268},[23030],{"type":52,"value":17342},{"type":46,"tag":250,"props":23032,"children":23033},{"style":274},[23034],{"type":52,"value":9598},{"type":46,"tag":250,"props":23036,"children":23037},{"style":268},[23038],{"type":52,"value":10086},{"type":46,"tag":250,"props":23040,"children":23041},{"style":375},[23042],{"type":52,"value":9608},{"type":46,"tag":250,"props":23044,"children":23045},{"style":268},[23046],{"type":52,"value":23047}," cost_per_acquisition,\n",{"type":46,"tag":250,"props":23049,"children":23051},{"class":252,"line":23050},61,[23052,23056,23060,23064,23068,23072,23076,23080,23084,23088,23092,23096,23100,23104,23108,23112,23116,23120,23124,23128,23132],{"type":46,"tag":250,"props":23053,"children":23054},{"style":274},[23055],{"type":52,"value":17313},{"type":46,"tag":250,"props":23057,"children":23058},{"style":268},[23059],{"type":52,"value":9557},{"type":46,"tag":250,"props":23061,"children":23062},{"style":274},[23063],{"type":52,"value":19548},{"type":46,"tag":250,"props":23065,"children":23066},{"style":268},[23067],{"type":52,"value":106},{"type":46,"tag":250,"props":23069,"children":23070},{"style":274},[23071],{"type":52,"value":22804},{"type":46,"tag":250,"props":23073,"children":23074},{"style":375},[23075],{"type":52,"value":9885},{"type":46,"tag":250,"props":23077,"children":23078},{"style":274},[23079],{"type":52,"value":17328},{"type":46,"tag":250,"props":23081,"children":23082},{"style":268},[23083],{"type":52,"value":9557},{"type":46,"tag":250,"props":23085,"children":23086},{"style":274},[23087],{"type":52,"value":19548},{"type":46,"tag":250,"props":23089,"children":23090},{"style":268},[23091],{"type":52,"value":106},{"type":46,"tag":250,"props":23093,"children":23094},{"style":274},[23095],{"type":52,"value":22783},{"type":46,"tag":250,"props":23097,"children":23098},{"style":268},[23099],{"type":52,"value":151},{"type":46,"tag":250,"props":23101,"children":23102},{"style":274},[23103],{"type":52,"value":9899},{"type":46,"tag":250,"props":23105,"children":23106},{"style":268},[23107],{"type":52,"value":10086},{"type":46,"tag":250,"props":23109,"children":23110},{"style":375},[23111],{"type":52,"value":15522},{"type":46,"tag":250,"props":23113,"children":23114},{"style":274},[23115],{"type":52,"value":9890},{"type":46,"tag":250,"props":23117,"children":23118},{"style":268},[23119],{"type":52,"value":151},{"type":46,"tag":250,"props":23121,"children":23122},{"style":274},[23123],{"type":52,"value":9598},{"type":46,"tag":250,"props":23125,"children":23126},{"style":268},[23127],{"type":52,"value":10086},{"type":46,"tag":250,"props":23129,"children":23130},{"style":375},[23131],{"type":52,"value":9608},{"type":46,"tag":250,"props":23133,"children":23134},{"style":268},[23135],{"type":52,"value":23136}," click_through_rate\n",{"type":46,"tag":250,"props":23138,"children":23140},{"class":252,"line":23139},62,[23141,23145],{"type":46,"tag":250,"props":23142,"children":23143},{"style":375},[23144],{"type":52,"value":9969},{"type":46,"tag":250,"props":23146,"children":23147},{"style":268},[23148],{"type":52,"value":23149}," channel_spend cs\n",{"type":46,"tag":250,"props":23151,"children":23153},{"class":252,"line":23152},63,[23154,23158],{"type":46,"tag":250,"props":23155,"children":23156},{"style":375},[23157],{"type":52,"value":9077},{"type":46,"tag":250,"props":23159,"children":23160},{"style":268},[23161],{"type":52,"value":23162}," channel_sessions sess\n",{"type":46,"tag":250,"props":23164,"children":23166},{"class":252,"line":23165},64,[23167,23171,23175,23179,23183,23187,23192,23196],{"type":46,"tag":250,"props":23168,"children":23169},{"style":375},[23170],{"type":52,"value":10023},{"type":46,"tag":250,"props":23172,"children":23173},{"style":274},[23174],{"type":52,"value":19752},{"type":46,"tag":250,"props":23176,"children":23177},{"style":268},[23178],{"type":52,"value":106},{"type":46,"tag":250,"props":23180,"children":23181},{"style":274},[23182],{"type":52,"value":22716},{"type":46,"tag":250,"props":23184,"children":23185},{"style":375},[23186],{"type":52,"value":10041},{"type":46,"tag":250,"props":23188,"children":23189},{"style":274},[23190],{"type":52,"value":23191}," sess",{"type":46,"tag":250,"props":23193,"children":23194},{"style":268},[23195],{"type":52,"value":106},{"type":46,"tag":250,"props":23197,"children":23198},{"style":274},[23199],{"type":52,"value":22630},{"type":46,"tag":250,"props":23201,"children":23203},{"class":252,"line":23202},65,[23204,23208,23212,23216,23220,23224,23228,23232],{"type":46,"tag":250,"props":23205,"children":23206},{"style":375},[23207],{"type":52,"value":10064},{"type":46,"tag":250,"props":23209,"children":23210},{"style":274},[23211],{"type":52,"value":19752},{"type":46,"tag":250,"props":23213,"children":23214},{"style":268},[23215],{"type":52,"value":106},{"type":46,"tag":250,"props":23217,"children":23218},{"style":274},[23219],{"type":52,"value":22497},{"type":46,"tag":250,"props":23221,"children":23222},{"style":375},[23223],{"type":52,"value":10041},{"type":46,"tag":250,"props":23225,"children":23226},{"style":274},[23227],{"type":52,"value":23191},{"type":46,"tag":250,"props":23229,"children":23230},{"style":268},[23231],{"type":52,"value":106},{"type":46,"tag":250,"props":23233,"children":23234},{"style":274},[23235],{"type":52,"value":22683},{"type":46,"tag":250,"props":23237,"children":23239},{"class":252,"line":23238},66,[23240,23244],{"type":46,"tag":250,"props":23241,"children":23242},{"style":375},[23243],{"type":52,"value":9077},{"type":46,"tag":250,"props":23245,"children":23246},{"style":268},[23247],{"type":52,"value":23248}," channel_revenue cr\n",{"type":46,"tag":250,"props":23250,"children":23252},{"class":252,"line":23251},67,[23253,23257,23261,23265,23269,23273,23278,23282],{"type":46,"tag":250,"props":23254,"children":23255},{"style":375},[23256],{"type":52,"value":10023},{"type":46,"tag":250,"props":23258,"children":23259},{"style":274},[23260],{"type":52,"value":19752},{"type":46,"tag":250,"props":23262,"children":23263},{"style":268},[23264],{"type":52,"value":106},{"type":46,"tag":250,"props":23266,"children":23267},{"style":274},[23268],{"type":52,"value":22716},{"type":46,"tag":250,"props":23270,"children":23271},{"style":375},[23272],{"type":52,"value":10041},{"type":46,"tag":250,"props":23274,"children":23275},{"style":274},[23276],{"type":52,"value":23277}," cr",{"type":46,"tag":250,"props":23279,"children":23280},{"style":268},[23281],{"type":52,"value":106},{"type":46,"tag":250,"props":23283,"children":23284},{"style":274},[23285],{"type":52,"value":23286},"order_date\n",{"type":46,"tag":250,"props":23288,"children":23290},{"class":252,"line":23289},68,[23291,23295,23299,23303,23307,23311,23315,23319],{"type":46,"tag":250,"props":23292,"children":23293},{"style":375},[23294],{"type":52,"value":10064},{"type":46,"tag":250,"props":23296,"children":23297},{"style":274},[23298],{"type":52,"value":19752},{"type":46,"tag":250,"props":23300,"children":23301},{"style":268},[23302],{"type":52,"value":106},{"type":46,"tag":250,"props":23304,"children":23305},{"style":274},[23306],{"type":52,"value":22497},{"type":46,"tag":250,"props":23308,"children":23309},{"style":375},[23310],{"type":52,"value":10041},{"type":46,"tag":250,"props":23312,"children":23313},{"style":274},[23314],{"type":52,"value":23277},{"type":46,"tag":250,"props":23316,"children":23317},{"style":268},[23318],{"type":52,"value":106},{"type":46,"tag":250,"props":23320,"children":23321},{"style":274},[23322],{"type":52,"value":22683},{"type":46,"tag":250,"props":23324,"children":23326},{"class":252,"line":23325},69,[23327,23331,23335,23339,23343,23347,23351,23355,23359,23363],{"type":46,"tag":250,"props":23328,"children":23329},{"style":375},[23330],{"type":52,"value":17462},{"type":46,"tag":250,"props":23332,"children":23333},{"style":274},[23334],{"type":52,"value":19752},{"type":46,"tag":250,"props":23336,"children":23337},{"style":268},[23338],{"type":52,"value":106},{"type":46,"tag":250,"props":23340,"children":23341},{"style":274},[23342],{"type":52,"value":22716},{"type":46,"tag":250,"props":23344,"children":23345},{"style":375},[23346],{"type":52,"value":11066},{"type":46,"tag":250,"props":23348,"children":23349},{"style":268},[23350],{"type":52,"value":151},{"type":46,"tag":250,"props":23352,"children":23353},{"style":274},[23354],{"type":52,"value":19548},{"type":46,"tag":250,"props":23356,"children":23357},{"style":268},[23358],{"type":52,"value":106},{"type":46,"tag":250,"props":23360,"children":23361},{"style":274},[23362],{"type":52,"value":22762},{"type":46,"tag":250,"props":23364,"children":23365},{"style":375},[23366],{"type":52,"value":23367}," DESC\n",{"type":46,"tag":429,"props":23369,"children":23370},{"v-slot:bigquery":7},[23371],{"type":46,"tag":240,"props":23372,"children":23374},{"className":9175,"code":23373,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_marketing_roi\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_marketing_spend\n  - staging.stg_web_sessions\n  - staging.stg_orders\ncolumns:\n  - name: channel\n    type: varchar\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH channel_spend AS (\n    SELECT\n        spend_date,\n        channel,\n        sum(spend) AS total_spend,\n        sum(impressions) AS total_impressions,\n        sum(clicks) AS total_clicks,\n        sum(conversions) AS total_conversions\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date, channel\n),\nchannel_sessions AS (\n    SELECT\n        session_date,\n        channel,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_users,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date, channel\n),\nchannel_revenue AS (\n    SELECT\n        DATE(order_date) AS order_date,\n        ws.channel,\n        sum(o.order_total) AS attributed_revenue\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_web_sessions ws\n        ON DATE(o.order_date) = ws.session_date\n    WHERE o.payment_status = 'paid'\n    GROUP BY DATE(order_date), ws.channel\n)\nSELECT\n    cs.spend_date AS report_date,\n    cs.channel,\n    cs.total_spend,\n    cs.total_impressions,\n    cs.total_clicks,\n    cs.total_conversions,\n    sess.sessions,\n    sess.new_users,\n    cr.attributed_revenue,\n    round(cr.attributed_revenue \u002F NULLIF(cs.total_spend, 0), 2) AS roas,\n    round(cs.total_spend \u002F NULLIF(cs.total_conversions, 0), 2) AS cost_per_acquisition,\n    round(cs.total_clicks \u002F NULLIF(cs.total_impressions, 0) * 100, 2) AS click_through_rate\nFROM channel_spend cs\nLEFT JOIN channel_sessions sess\n    ON cs.spend_date = sess.session_date\n    AND cs.channel = sess.channel\nLEFT JOIN channel_revenue cr\n    ON cs.spend_date = cr.order_date\n    AND cs.channel = cr.channel\nORDER BY cs.spend_date DESC, cs.total_spend DESC\n",[23375],{"type":46,"tag":99,"props":23376,"children":23377},{"__ignoreMap":7},[23378,23385,23392,23399,23406,23413,23420,23427,23434,23441,23448,23455,23462,23469,23476,23483,23490,23509,23516,23523,23530,23549,23568,23587,23606,23625,23636,23643,23658,23665,23672,23679,23702,23721,23740,23759,23770,23777,23792,23799,23819,23838,23873,23896,23919,23966,23993,24021,24028,24035,24058,24077,24096,24115,24134,24153,24172,24191,24210,24285,24360,24447,24458,24469,24504,24539,24550,24585,24620],{"type":46,"tag":250,"props":23379,"children":23380},{"class":252,"line":23},[23381],{"type":46,"tag":250,"props":23382,"children":23383},{"style":9187},[23384],{"type":52,"value":9190},{"type":46,"tag":250,"props":23386,"children":23387},{"class":252,"line":285},[23388],{"type":46,"tag":250,"props":23389,"children":23390},{"style":9187},[23391],{"type":52,"value":22030},{"type":46,"tag":250,"props":23393,"children":23394},{"class":252,"line":299},[23395],{"type":46,"tag":250,"props":23396,"children":23397},{"style":9187},[23398],{"type":52,"value":9206},{"type":46,"tag":250,"props":23400,"children":23401},{"class":252,"line":807},[23402],{"type":46,"tag":250,"props":23403,"children":23404},{"style":9187},[23405],{"type":52,"value":9214},{"type":46,"tag":250,"props":23407,"children":23408},{"class":252,"line":820},[23409],{"type":46,"tag":250,"props":23410,"children":23411},{"style":9187},[23412],{"type":52,"value":9222},{"type":46,"tag":250,"props":23414,"children":23415},{"class":252,"line":844},[23416],{"type":46,"tag":250,"props":23417,"children":23418},{"style":9187},[23419],{"type":52,"value":9230},{"type":46,"tag":250,"props":23421,"children":23422},{"class":252,"line":862},[23423],{"type":46,"tag":250,"props":23424,"children":23425},{"style":9187},[23426],{"type":52,"value":22066},{"type":46,"tag":250,"props":23428,"children":23429},{"class":252,"line":11},[23430],{"type":46,"tag":250,"props":23431,"children":23432},{"style":9187},[23433],{"type":52,"value":22074},{"type":46,"tag":250,"props":23435,"children":23436},{"class":252,"line":4649},[23437],{"type":46,"tag":250,"props":23438,"children":23439},{"style":9187},[23440],{"type":52,"value":16980},{"type":46,"tag":250,"props":23442,"children":23443},{"class":252,"line":9257},[23444],{"type":46,"tag":250,"props":23445,"children":23446},{"style":9187},[23447],{"type":52,"value":9254},{"type":46,"tag":250,"props":23449,"children":23450},{"class":252,"line":9266},[23451],{"type":46,"tag":250,"props":23452,"children":23453},{"style":9187},[23454],{"type":52,"value":22096},{"type":46,"tag":250,"props":23456,"children":23457},{"class":252,"line":9275},[23458],{"type":46,"tag":250,"props":23459,"children":23460},{"style":9187},[23461],{"type":52,"value":9272},{"type":46,"tag":250,"props":23463,"children":23464},{"class":252,"line":9284},[23465],{"type":46,"tag":250,"props":23466,"children":23467},{"style":9187},[23468],{"type":52,"value":9281},{"type":46,"tag":250,"props":23470,"children":23471},{"class":252,"line":9293},[23472],{"type":46,"tag":250,"props":23473,"children":23474},{"style":9187},[23475],{"type":52,"value":9290},{"type":46,"tag":250,"props":23477,"children":23478},{"class":252,"line":4121},[23479],{"type":46,"tag":250,"props":23480,"children":23481},{"style":9187},[23482],{"type":52,"value":9377},{"type":46,"tag":250,"props":23484,"children":23485},{"class":252,"line":9310},[23486],{"type":46,"tag":250,"props":23487,"children":23488},{"emptyLinePlaceholder":22},[23489],{"type":52,"value":9386},{"type":46,"tag":250,"props":23491,"children":23492},{"class":252,"line":9319},[23493,23497,23501,23505],{"type":46,"tag":250,"props":23494,"children":23495},{"style":375},[23496],{"type":52,"value":19021},{"type":46,"tag":250,"props":23498,"children":23499},{"style":268},[23500],{"type":52,"value":22143},{"type":46,"tag":250,"props":23502,"children":23503},{"style":375},[23504],{"type":52,"value":9608},{"type":46,"tag":250,"props":23506,"children":23507},{"style":268},[23508],{"type":52,"value":19035},{"type":46,"tag":250,"props":23510,"children":23511},{"class":252,"line":9327},[23512],{"type":46,"tag":250,"props":23513,"children":23514},{"style":375},[23515],{"type":52,"value":19043},{"type":46,"tag":250,"props":23517,"children":23518},{"class":252,"line":9335},[23519],{"type":46,"tag":250,"props":23520,"children":23521},{"style":268},[23522],{"type":52,"value":22166},{"type":46,"tag":250,"props":23524,"children":23525},{"class":252,"line":9344},[23526],{"type":46,"tag":250,"props":23527,"children":23528},{"style":268},[23529],{"type":52,"value":22174},{"type":46,"tag":250,"props":23531,"children":23532},{"class":252,"line":9353},[23533,23537,23541,23545],{"type":46,"tag":250,"props":23534,"children":23535},{"style":274},[23536],{"type":52,"value":22182},{"type":46,"tag":250,"props":23538,"children":23539},{"style":268},[23540],{"type":52,"value":22187},{"type":46,"tag":250,"props":23542,"children":23543},{"style":375},[23544],{"type":52,"value":9608},{"type":46,"tag":250,"props":23546,"children":23547},{"style":268},[23548],{"type":52,"value":22196},{"type":46,"tag":250,"props":23550,"children":23551},{"class":252,"line":9362},[23552,23556,23560,23564],{"type":46,"tag":250,"props":23553,"children":23554},{"style":274},[23555],{"type":52,"value":22182},{"type":46,"tag":250,"props":23557,"children":23558},{"style":268},[23559],{"type":52,"value":22208},{"type":46,"tag":250,"props":23561,"children":23562},{"style":375},[23563],{"type":52,"value":9608},{"type":46,"tag":250,"props":23565,"children":23566},{"style":268},[23567],{"type":52,"value":22217},{"type":46,"tag":250,"props":23569,"children":23570},{"class":252,"line":9371},[23571,23575,23579,23583],{"type":46,"tag":250,"props":23572,"children":23573},{"style":274},[23574],{"type":52,"value":22182},{"type":46,"tag":250,"props":23576,"children":23577},{"style":268},[23578],{"type":52,"value":22229},{"type":46,"tag":250,"props":23580,"children":23581},{"style":375},[23582],{"type":52,"value":9608},{"type":46,"tag":250,"props":23584,"children":23585},{"style":268},[23586],{"type":52,"value":22238},{"type":46,"tag":250,"props":23588,"children":23589},{"class":252,"line":9380},[23590,23594,23598,23602],{"type":46,"tag":250,"props":23591,"children":23592},{"style":274},[23593],{"type":52,"value":22182},{"type":46,"tag":250,"props":23595,"children":23596},{"style":268},[23597],{"type":52,"value":22250},{"type":46,"tag":250,"props":23599,"children":23600},{"style":375},[23601],{"type":52,"value":9608},{"type":46,"tag":250,"props":23603,"children":23604},{"style":268},[23605],{"type":52,"value":22259},{"type":46,"tag":250,"props":23607,"children":23608},{"class":252,"line":9389},[23609,23613,23617,23621],{"type":46,"tag":250,"props":23610,"children":23611},{"style":375},[23612],{"type":52,"value":19155},{"type":46,"tag":250,"props":23614,"children":23615},{"style":274},[23616],{"type":52,"value":17433},{"type":46,"tag":250,"props":23618,"children":23619},{"style":268},[23620],{"type":52,"value":106},{"type":46,"tag":250,"props":23622,"children":23623},{"style":274},[23624],{"type":52,"value":22279},{"type":46,"tag":250,"props":23626,"children":23627},{"class":252,"line":9398},[23628,23632],{"type":46,"tag":250,"props":23629,"children":23630},{"style":375},[23631],{"type":52,"value":19353},{"type":46,"tag":250,"props":23633,"children":23634},{"style":268},[23635],{"type":52,"value":22291},{"type":46,"tag":250,"props":23637,"children":23638},{"class":252,"line":9426},[23639],{"type":46,"tag":250,"props":23640,"children":23641},{"style":268},[23642],{"type":52,"value":19271},{"type":46,"tag":250,"props":23644,"children":23645},{"class":252,"line":9448},[23646,23650,23654],{"type":46,"tag":250,"props":23647,"children":23648},{"style":268},[23649],{"type":52,"value":22306},{"type":46,"tag":250,"props":23651,"children":23652},{"style":375},[23653],{"type":52,"value":9608},{"type":46,"tag":250,"props":23655,"children":23656},{"style":268},[23657],{"type":52,"value":19035},{"type":46,"tag":250,"props":23659,"children":23660},{"class":252,"line":9474},[23661],{"type":46,"tag":250,"props":23662,"children":23663},{"style":375},[23664],{"type":52,"value":19043},{"type":46,"tag":250,"props":23666,"children":23667},{"class":252,"line":9500},[23668],{"type":46,"tag":250,"props":23669,"children":23670},{"style":268},[23671],{"type":52,"value":22329},{"type":46,"tag":250,"props":23673,"children":23674},{"class":252,"line":9525},[23675],{"type":46,"tag":250,"props":23676,"children":23677},{"style":268},[23678],{"type":52,"value":22174},{"type":46,"tag":250,"props":23680,"children":23681},{"class":252,"line":9546},[23682,23686,23690,23694,23698],{"type":46,"tag":250,"props":23683,"children":23684},{"style":274},[23685],{"type":52,"value":22182},{"type":46,"tag":250,"props":23687,"children":23688},{"style":268},[23689],{"type":52,"value":22348},{"type":46,"tag":250,"props":23691,"children":23692},{"style":375},[23693],{"type":52,"value":9608},{"type":46,"tag":250,"props":23695,"children":23696},{"style":375},[23697],{"type":52,"value":22357},{"type":46,"tag":250,"props":23699,"children":23700},{"style":268},[23701],{"type":52,"value":9445},{"type":46,"tag":250,"props":23703,"children":23704},{"class":252,"line":9616},[23705,23709,23713,23717],{"type":46,"tag":250,"props":23706,"children":23707},{"style":274},[23708],{"type":52,"value":22182},{"type":46,"tag":250,"props":23710,"children":23711},{"style":268},[23712],{"type":52,"value":22373},{"type":46,"tag":250,"props":23714,"children":23715},{"style":375},[23716],{"type":52,"value":9608},{"type":46,"tag":250,"props":23718,"children":23719},{"style":268},[23720],{"type":52,"value":15604},{"type":46,"tag":250,"props":23722,"children":23723},{"class":252,"line":9678},[23724,23728,23732,23736],{"type":46,"tag":250,"props":23725,"children":23726},{"style":274},[23727],{"type":52,"value":22182},{"type":46,"tag":250,"props":23729,"children":23730},{"style":268},[23731],{"type":52,"value":22393},{"type":46,"tag":250,"props":23733,"children":23734},{"style":375},[23735],{"type":52,"value":9608},{"type":46,"tag":250,"props":23737,"children":23738},{"style":268},[23739],{"type":52,"value":22402},{"type":46,"tag":250,"props":23741,"children":23742},{"class":252,"line":9740},[23743,23747,23751,23755],{"type":46,"tag":250,"props":23744,"children":23745},{"style":375},[23746],{"type":52,"value":19155},{"type":46,"tag":250,"props":23748,"children":23749},{"style":274},[23750],{"type":52,"value":17433},{"type":46,"tag":250,"props":23752,"children":23753},{"style":268},[23754],{"type":52,"value":106},{"type":46,"tag":250,"props":23756,"children":23757},{"style":274},[23758],{"type":52,"value":22422},{"type":46,"tag":250,"props":23760,"children":23761},{"class":252,"line":9802},[23762,23766],{"type":46,"tag":250,"props":23763,"children":23764},{"style":375},[23765],{"type":52,"value":19353},{"type":46,"tag":250,"props":23767,"children":23768},{"style":268},[23769],{"type":52,"value":22434},{"type":46,"tag":250,"props":23771,"children":23772},{"class":252,"line":9823},[23773],{"type":46,"tag":250,"props":23774,"children":23775},{"style":268},[23776],{"type":52,"value":19271},{"type":46,"tag":250,"props":23778,"children":23779},{"class":252,"line":9844},[23780,23784,23788],{"type":46,"tag":250,"props":23781,"children":23782},{"style":268},[23783],{"type":52,"value":22449},{"type":46,"tag":250,"props":23785,"children":23786},{"style":375},[23787],{"type":52,"value":9608},{"type":46,"tag":250,"props":23789,"children":23790},{"style":268},[23791],{"type":52,"value":19035},{"type":46,"tag":250,"props":23793,"children":23794},{"class":252,"line":9865},[23795],{"type":46,"tag":250,"props":23796,"children":23797},{"style":375},[23798],{"type":52,"value":19043},{"type":46,"tag":250,"props":23800,"children":23801},{"class":252,"line":9911},[23802,23807,23811,23815],{"type":46,"tag":250,"props":23803,"children":23804},{"style":375},[23805],{"type":52,"value":23806},"        DATE",{"type":46,"tag":250,"props":23808,"children":23809},{"style":268},[23810],{"type":52,"value":17629},{"type":46,"tag":250,"props":23812,"children":23813},{"style":375},[23814],{"type":52,"value":9608},{"type":46,"tag":250,"props":23816,"children":23817},{"style":268},[23818],{"type":52,"value":9497},{"type":46,"tag":250,"props":23820,"children":23821},{"class":252,"line":9937},[23822,23826,23830,23834],{"type":46,"tag":250,"props":23823,"children":23824},{"style":274},[23825],{"type":52,"value":22488},{"type":46,"tag":250,"props":23827,"children":23828},{"style":268},[23829],{"type":52,"value":106},{"type":46,"tag":250,"props":23831,"children":23832},{"style":274},[23833],{"type":52,"value":22497},{"type":46,"tag":250,"props":23835,"children":23836},{"style":268},[23837],{"type":52,"value":9445},{"type":46,"tag":250,"props":23839,"children":23840},{"class":252,"line":9963},[23841,23845,23849,23853,23857,23861,23865,23869],{"type":46,"tag":250,"props":23842,"children":23843},{"style":274},[23844],{"type":52,"value":22182},{"type":46,"tag":250,"props":23846,"children":23847},{"style":268},[23848],{"type":52,"value":9557},{"type":46,"tag":250,"props":23850,"children":23851},{"style":274},[23852],{"type":52,"value":9562},{"type":46,"tag":250,"props":23854,"children":23855},{"style":268},[23856],{"type":52,"value":106},{"type":46,"tag":250,"props":23858,"children":23859},{"style":274},[23860],{"type":52,"value":19621},{"type":46,"tag":250,"props":23862,"children":23863},{"style":268},[23864],{"type":52,"value":10086},{"type":46,"tag":250,"props":23866,"children":23867},{"style":375},[23868],{"type":52,"value":9608},{"type":46,"tag":250,"props":23870,"children":23871},{"style":268},[23872],{"type":52,"value":22537},{"type":46,"tag":250,"props":23874,"children":23875},{"class":252,"line":9991},[23876,23880,23884,23888,23892],{"type":46,"tag":250,"props":23877,"children":23878},{"style":375},[23879],{"type":52,"value":19155},{"type":46,"tag":250,"props":23881,"children":23882},{"style":274},[23883],{"type":52,"value":17433},{"type":46,"tag":250,"props":23885,"children":23886},{"style":268},[23887],{"type":52,"value":106},{"type":46,"tag":250,"props":23889,"children":23890},{"style":274},[23891],{"type":52,"value":18055},{"type":46,"tag":250,"props":23893,"children":23894},{"style":268},[23895],{"type":52,"value":9988},{"type":46,"tag":250,"props":23897,"children":23898},{"class":252,"line":10017},[23899,23903,23907,23911,23915],{"type":46,"tag":250,"props":23900,"children":23901},{"style":375},[23902],{"type":52,"value":19179},{"type":46,"tag":250,"props":23904,"children":23905},{"style":274},[23906],{"type":52,"value":17433},{"type":46,"tag":250,"props":23908,"children":23909},{"style":268},[23910],{"type":52,"value":106},{"type":46,"tag":250,"props":23912,"children":23913},{"style":274},[23914],{"type":52,"value":22580},{"type":46,"tag":250,"props":23916,"children":23917},{"style":268},[23918],{"type":52,"value":22585},{"type":46,"tag":250,"props":23920,"children":23921},{"class":252,"line":10058},[23922,23926,23930,23934,23938,23942,23946,23950,23954,23958,23962],{"type":46,"tag":250,"props":23923,"children":23924},{"style":375},[23925],{"type":52,"value":19204},{"type":46,"tag":250,"props":23927,"children":23928},{"style":375},[23929],{"type":52,"value":10885},{"type":46,"tag":250,"props":23931,"children":23932},{"style":268},[23933],{"type":52,"value":9557},{"type":46,"tag":250,"props":23935,"children":23936},{"style":274},[23937],{"type":52,"value":9562},{"type":46,"tag":250,"props":23939,"children":23940},{"style":268},[23941],{"type":52,"value":106},{"type":46,"tag":250,"props":23943,"children":23944},{"style":274},[23945],{"type":52,"value":19118},{"type":46,"tag":250,"props":23947,"children":23948},{"style":268},[23949],{"type":52,"value":10086},{"type":46,"tag":250,"props":23951,"children":23952},{"style":375},[23953],{"type":52,"value":10091},{"type":46,"tag":250,"props":23955,"children":23956},{"style":274},[23957],{"type":52,"value":22621},{"type":46,"tag":250,"props":23959,"children":23960},{"style":268},[23961],{"type":52,"value":106},{"type":46,"tag":250,"props":23963,"children":23964},{"style":274},[23965],{"type":52,"value":22630},{"type":46,"tag":250,"props":23967,"children":23968},{"class":252,"line":10936},[23969,23973,23977,23981,23985,23989],{"type":46,"tag":250,"props":23970,"children":23971},{"style":375},[23972],{"type":52,"value":19241},{"type":46,"tag":250,"props":23974,"children":23975},{"style":274},[23976],{"type":52,"value":10028},{"type":46,"tag":250,"props":23978,"children":23979},{"style":268},[23980],{"type":52,"value":106},{"type":46,"tag":250,"props":23982,"children":23983},{"style":274},[23984],{"type":52,"value":19254},{"type":46,"tag":250,"props":23986,"children":23987},{"style":375},[23988],{"type":52,"value":10041},{"type":46,"tag":250,"props":23990,"children":23991},{"style":262},[23992],{"type":52,"value":19263},{"type":46,"tag":250,"props":23994,"children":23995},{"class":252,"line":10995},[23996,24000,24004,24009,24013,24017],{"type":46,"tag":250,"props":23997,"children":23998},{"style":375},[23999],{"type":52,"value":19353},{"type":46,"tag":250,"props":24001,"children":24002},{"style":375},[24003],{"type":52,"value":10885},{"type":46,"tag":250,"props":24005,"children":24006},{"style":268},[24007],{"type":52,"value":24008},"(order_date), ",{"type":46,"tag":250,"props":24010,"children":24011},{"style":274},[24012],{"type":52,"value":22674},{"type":46,"tag":250,"props":24014,"children":24015},{"style":268},[24016],{"type":52,"value":106},{"type":46,"tag":250,"props":24018,"children":24019},{"style":274},[24020],{"type":52,"value":22683},{"type":46,"tag":250,"props":24022,"children":24023},{"class":252,"line":22686},[24024],{"type":46,"tag":250,"props":24025,"children":24026},{"style":268},[24027],{"type":52,"value":10114},{"type":46,"tag":250,"props":24029,"children":24030},{"class":252,"line":22694},[24031],{"type":46,"tag":250,"props":24032,"children":24033},{"style":375},[24034],{"type":52,"value":9395},{"type":46,"tag":250,"props":24036,"children":24037},{"class":252,"line":22702},[24038,24042,24046,24050,24054],{"type":46,"tag":250,"props":24039,"children":24040},{"style":274},[24041],{"type":52,"value":19401},{"type":46,"tag":250,"props":24043,"children":24044},{"style":268},[24045],{"type":52,"value":106},{"type":46,"tag":250,"props":24047,"children":24048},{"style":274},[24049],{"type":52,"value":22716},{"type":46,"tag":250,"props":24051,"children":24052},{"style":375},[24053],{"type":52,"value":9418},{"type":46,"tag":250,"props":24055,"children":24056},{"style":268},[24057],{"type":52,"value":22725},{"type":46,"tag":250,"props":24059,"children":24060},{"class":252,"line":22728},[24061,24065,24069,24073],{"type":46,"tag":250,"props":24062,"children":24063},{"style":274},[24064],{"type":52,"value":19401},{"type":46,"tag":250,"props":24066,"children":24067},{"style":268},[24068],{"type":52,"value":106},{"type":46,"tag":250,"props":24070,"children":24071},{"style":274},[24072],{"type":52,"value":22497},{"type":46,"tag":250,"props":24074,"children":24075},{"style":268},[24076],{"type":52,"value":9445},{"type":46,"tag":250,"props":24078,"children":24079},{"class":252,"line":22748},[24080,24084,24088,24092],{"type":46,"tag":250,"props":24081,"children":24082},{"style":274},[24083],{"type":52,"value":19401},{"type":46,"tag":250,"props":24085,"children":24086},{"style":268},[24087],{"type":52,"value":106},{"type":46,"tag":250,"props":24089,"children":24090},{"style":274},[24091],{"type":52,"value":22762},{"type":46,"tag":250,"props":24093,"children":24094},{"style":268},[24095],{"type":52,"value":9445},{"type":46,"tag":250,"props":24097,"children":24098},{"class":252,"line":22769},[24099,24103,24107,24111],{"type":46,"tag":250,"props":24100,"children":24101},{"style":274},[24102],{"type":52,"value":19401},{"type":46,"tag":250,"props":24104,"children":24105},{"style":268},[24106],{"type":52,"value":106},{"type":46,"tag":250,"props":24108,"children":24109},{"style":274},[24110],{"type":52,"value":22783},{"type":46,"tag":250,"props":24112,"children":24113},{"style":268},[24114],{"type":52,"value":9445},{"type":46,"tag":250,"props":24116,"children":24117},{"class":252,"line":22790},[24118,24122,24126,24130],{"type":46,"tag":250,"props":24119,"children":24120},{"style":274},[24121],{"type":52,"value":19401},{"type":46,"tag":250,"props":24123,"children":24124},{"style":268},[24125],{"type":52,"value":106},{"type":46,"tag":250,"props":24127,"children":24128},{"style":274},[24129],{"type":52,"value":22804},{"type":46,"tag":250,"props":24131,"children":24132},{"style":268},[24133],{"type":52,"value":9445},{"type":46,"tag":250,"props":24135,"children":24136},{"class":252,"line":22811},[24137,24141,24145,24149],{"type":46,"tag":250,"props":24138,"children":24139},{"style":274},[24140],{"type":52,"value":19401},{"type":46,"tag":250,"props":24142,"children":24143},{"style":268},[24144],{"type":52,"value":106},{"type":46,"tag":250,"props":24146,"children":24147},{"style":274},[24148],{"type":52,"value":22825},{"type":46,"tag":250,"props":24150,"children":24151},{"style":268},[24152],{"type":52,"value":9445},{"type":46,"tag":250,"props":24154,"children":24155},{"class":252,"line":22832},[24156,24160,24164,24168],{"type":46,"tag":250,"props":24157,"children":24158},{"style":274},[24159],{"type":52,"value":22838},{"type":46,"tag":250,"props":24161,"children":24162},{"style":268},[24163],{"type":52,"value":106},{"type":46,"tag":250,"props":24165,"children":24166},{"style":274},[24167],{"type":52,"value":15030},{"type":46,"tag":250,"props":24169,"children":24170},{"style":268},[24171],{"type":52,"value":9445},{"type":46,"tag":250,"props":24173,"children":24174},{"class":252,"line":22853},[24175,24179,24183,24187],{"type":46,"tag":250,"props":24176,"children":24177},{"style":274},[24178],{"type":52,"value":22838},{"type":46,"tag":250,"props":24180,"children":24181},{"style":268},[24182],{"type":52,"value":106},{"type":46,"tag":250,"props":24184,"children":24185},{"style":274},[24186],{"type":52,"value":15055},{"type":46,"tag":250,"props":24188,"children":24189},{"style":268},[24190],{"type":52,"value":9445},{"type":46,"tag":250,"props":24192,"children":24193},{"class":252,"line":22873},[24194,24198,24202,24206],{"type":46,"tag":250,"props":24195,"children":24196},{"style":274},[24197],{"type":52,"value":22879},{"type":46,"tag":250,"props":24199,"children":24200},{"style":268},[24201],{"type":52,"value":106},{"type":46,"tag":250,"props":24203,"children":24204},{"style":274},[24205],{"type":52,"value":22888},{"type":46,"tag":250,"props":24207,"children":24208},{"style":268},[24209],{"type":52,"value":9445},{"type":46,"tag":250,"props":24211,"children":24212},{"class":252,"line":22895},[24213,24217,24221,24225,24229,24233,24237,24241,24245,24249,24253,24257,24261,24265,24269,24273,24277,24281],{"type":46,"tag":250,"props":24214,"children":24215},{"style":274},[24216],{"type":52,"value":17313},{"type":46,"tag":250,"props":24218,"children":24219},{"style":268},[24220],{"type":52,"value":9557},{"type":46,"tag":250,"props":24222,"children":24223},{"style":274},[24224],{"type":52,"value":22909},{"type":46,"tag":250,"props":24226,"children":24227},{"style":268},[24228],{"type":52,"value":106},{"type":46,"tag":250,"props":24230,"children":24231},{"style":274},[24232],{"type":52,"value":22888},{"type":46,"tag":250,"props":24234,"children":24235},{"style":375},[24236],{"type":52,"value":9885},{"type":46,"tag":250,"props":24238,"children":24239},{"style":274},[24240],{"type":52,"value":17909},{"type":46,"tag":250,"props":24242,"children":24243},{"style":268},[24244],{"type":52,"value":9557},{"type":46,"tag":250,"props":24246,"children":24247},{"style":274},[24248],{"type":52,"value":19548},{"type":46,"tag":250,"props":24250,"children":24251},{"style":268},[24252],{"type":52,"value":106},{"type":46,"tag":250,"props":24254,"children":24255},{"style":274},[24256],{"type":52,"value":22762},{"type":46,"tag":250,"props":24258,"children":24259},{"style":268},[24260],{"type":52,"value":151},{"type":46,"tag":250,"props":24262,"children":24263},{"style":274},[24264],{"type":52,"value":9899},{"type":46,"tag":250,"props":24266,"children":24267},{"style":268},[24268],{"type":52,"value":17342},{"type":46,"tag":250,"props":24270,"children":24271},{"style":274},[24272],{"type":52,"value":9598},{"type":46,"tag":250,"props":24274,"children":24275},{"style":268},[24276],{"type":52,"value":10086},{"type":46,"tag":250,"props":24278,"children":24279},{"style":375},[24280],{"type":52,"value":9608},{"type":46,"tag":250,"props":24282,"children":24283},{"style":268},[24284],{"type":52,"value":22970},{"type":46,"tag":250,"props":24286,"children":24287},{"class":252,"line":22973},[24288,24292,24296,24300,24304,24308,24312,24316,24320,24324,24328,24332,24336,24340,24344,24348,24352,24356],{"type":46,"tag":250,"props":24289,"children":24290},{"style":274},[24291],{"type":52,"value":17313},{"type":46,"tag":250,"props":24293,"children":24294},{"style":268},[24295],{"type":52,"value":9557},{"type":46,"tag":250,"props":24297,"children":24298},{"style":274},[24299],{"type":52,"value":19548},{"type":46,"tag":250,"props":24301,"children":24302},{"style":268},[24303],{"type":52,"value":106},{"type":46,"tag":250,"props":24305,"children":24306},{"style":274},[24307],{"type":52,"value":22762},{"type":46,"tag":250,"props":24309,"children":24310},{"style":375},[24311],{"type":52,"value":9885},{"type":46,"tag":250,"props":24313,"children":24314},{"style":274},[24315],{"type":52,"value":17909},{"type":46,"tag":250,"props":24317,"children":24318},{"style":268},[24319],{"type":52,"value":9557},{"type":46,"tag":250,"props":24321,"children":24322},{"style":274},[24323],{"type":52,"value":19548},{"type":46,"tag":250,"props":24325,"children":24326},{"style":268},[24327],{"type":52,"value":106},{"type":46,"tag":250,"props":24329,"children":24330},{"style":274},[24331],{"type":52,"value":22825},{"type":46,"tag":250,"props":24333,"children":24334},{"style":268},[24335],{"type":52,"value":151},{"type":46,"tag":250,"props":24337,"children":24338},{"style":274},[24339],{"type":52,"value":9899},{"type":46,"tag":250,"props":24341,"children":24342},{"style":268},[24343],{"type":52,"value":17342},{"type":46,"tag":250,"props":24345,"children":24346},{"style":274},[24347],{"type":52,"value":9598},{"type":46,"tag":250,"props":24349,"children":24350},{"style":268},[24351],{"type":52,"value":10086},{"type":46,"tag":250,"props":24353,"children":24354},{"style":375},[24355],{"type":52,"value":9608},{"type":46,"tag":250,"props":24357,"children":24358},{"style":268},[24359],{"type":52,"value":23047},{"type":46,"tag":250,"props":24361,"children":24362},{"class":252,"line":23050},[24363,24367,24371,24375,24379,24383,24387,24391,24395,24399,24403,24407,24411,24415,24419,24423,24427,24431,24435,24439,24443],{"type":46,"tag":250,"props":24364,"children":24365},{"style":274},[24366],{"type":52,"value":17313},{"type":46,"tag":250,"props":24368,"children":24369},{"style":268},[24370],{"type":52,"value":9557},{"type":46,"tag":250,"props":24372,"children":24373},{"style":274},[24374],{"type":52,"value":19548},{"type":46,"tag":250,"props":24376,"children":24377},{"style":268},[24378],{"type":52,"value":106},{"type":46,"tag":250,"props":24380,"children":24381},{"style":274},[24382],{"type":52,"value":22804},{"type":46,"tag":250,"props":24384,"children":24385},{"style":375},[24386],{"type":52,"value":9885},{"type":46,"tag":250,"props":24388,"children":24389},{"style":274},[24390],{"type":52,"value":17909},{"type":46,"tag":250,"props":24392,"children":24393},{"style":268},[24394],{"type":52,"value":9557},{"type":46,"tag":250,"props":24396,"children":24397},{"style":274},[24398],{"type":52,"value":19548},{"type":46,"tag":250,"props":24400,"children":24401},{"style":268},[24402],{"type":52,"value":106},{"type":46,"tag":250,"props":24404,"children":24405},{"style":274},[24406],{"type":52,"value":22783},{"type":46,"tag":250,"props":24408,"children":24409},{"style":268},[24410],{"type":52,"value":151},{"type":46,"tag":250,"props":24412,"children":24413},{"style":274},[24414],{"type":52,"value":9899},{"type":46,"tag":250,"props":24416,"children":24417},{"style":268},[24418],{"type":52,"value":10086},{"type":46,"tag":250,"props":24420,"children":24421},{"style":375},[24422],{"type":52,"value":15522},{"type":46,"tag":250,"props":24424,"children":24425},{"style":274},[24426],{"type":52,"value":9890},{"type":46,"tag":250,"props":24428,"children":24429},{"style":268},[24430],{"type":52,"value":151},{"type":46,"tag":250,"props":24432,"children":24433},{"style":274},[24434],{"type":52,"value":9598},{"type":46,"tag":250,"props":24436,"children":24437},{"style":268},[24438],{"type":52,"value":10086},{"type":46,"tag":250,"props":24440,"children":24441},{"style":375},[24442],{"type":52,"value":9608},{"type":46,"tag":250,"props":24444,"children":24445},{"style":268},[24446],{"type":52,"value":23136},{"type":46,"tag":250,"props":24448,"children":24449},{"class":252,"line":23139},[24450,24454],{"type":46,"tag":250,"props":24451,"children":24452},{"style":375},[24453],{"type":52,"value":9969},{"type":46,"tag":250,"props":24455,"children":24456},{"style":268},[24457],{"type":52,"value":23149},{"type":46,"tag":250,"props":24459,"children":24460},{"class":252,"line":23152},[24461,24465],{"type":46,"tag":250,"props":24462,"children":24463},{"style":375},[24464],{"type":52,"value":9077},{"type":46,"tag":250,"props":24466,"children":24467},{"style":268},[24468],{"type":52,"value":23162},{"type":46,"tag":250,"props":24470,"children":24471},{"class":252,"line":23165},[24472,24476,24480,24484,24488,24492,24496,24500],{"type":46,"tag":250,"props":24473,"children":24474},{"style":375},[24475],{"type":52,"value":10023},{"type":46,"tag":250,"props":24477,"children":24478},{"style":274},[24479],{"type":52,"value":19752},{"type":46,"tag":250,"props":24481,"children":24482},{"style":268},[24483],{"type":52,"value":106},{"type":46,"tag":250,"props":24485,"children":24486},{"style":274},[24487],{"type":52,"value":22716},{"type":46,"tag":250,"props":24489,"children":24490},{"style":375},[24491],{"type":52,"value":10041},{"type":46,"tag":250,"props":24493,"children":24494},{"style":274},[24495],{"type":52,"value":23191},{"type":46,"tag":250,"props":24497,"children":24498},{"style":268},[24499],{"type":52,"value":106},{"type":46,"tag":250,"props":24501,"children":24502},{"style":274},[24503],{"type":52,"value":22630},{"type":46,"tag":250,"props":24505,"children":24506},{"class":252,"line":23202},[24507,24511,24515,24519,24523,24527,24531,24535],{"type":46,"tag":250,"props":24508,"children":24509},{"style":375},[24510],{"type":52,"value":10064},{"type":46,"tag":250,"props":24512,"children":24513},{"style":274},[24514],{"type":52,"value":19752},{"type":46,"tag":250,"props":24516,"children":24517},{"style":268},[24518],{"type":52,"value":106},{"type":46,"tag":250,"props":24520,"children":24521},{"style":274},[24522],{"type":52,"value":22497},{"type":46,"tag":250,"props":24524,"children":24525},{"style":375},[24526],{"type":52,"value":10041},{"type":46,"tag":250,"props":24528,"children":24529},{"style":274},[24530],{"type":52,"value":23191},{"type":46,"tag":250,"props":24532,"children":24533},{"style":268},[24534],{"type":52,"value":106},{"type":46,"tag":250,"props":24536,"children":24537},{"style":274},[24538],{"type":52,"value":22683},{"type":46,"tag":250,"props":24540,"children":24541},{"class":252,"line":23238},[24542,24546],{"type":46,"tag":250,"props":24543,"children":24544},{"style":375},[24545],{"type":52,"value":9077},{"type":46,"tag":250,"props":24547,"children":24548},{"style":268},[24549],{"type":52,"value":23248},{"type":46,"tag":250,"props":24551,"children":24552},{"class":252,"line":23251},[24553,24557,24561,24565,24569,24573,24577,24581],{"type":46,"tag":250,"props":24554,"children":24555},{"style":375},[24556],{"type":52,"value":10023},{"type":46,"tag":250,"props":24558,"children":24559},{"style":274},[24560],{"type":52,"value":19752},{"type":46,"tag":250,"props":24562,"children":24563},{"style":268},[24564],{"type":52,"value":106},{"type":46,"tag":250,"props":24566,"children":24567},{"style":274},[24568],{"type":52,"value":22716},{"type":46,"tag":250,"props":24570,"children":24571},{"style":375},[24572],{"type":52,"value":10041},{"type":46,"tag":250,"props":24574,"children":24575},{"style":274},[24576],{"type":52,"value":23277},{"type":46,"tag":250,"props":24578,"children":24579},{"style":268},[24580],{"type":52,"value":106},{"type":46,"tag":250,"props":24582,"children":24583},{"style":274},[24584],{"type":52,"value":23286},{"type":46,"tag":250,"props":24586,"children":24587},{"class":252,"line":23289},[24588,24592,24596,24600,24604,24608,24612,24616],{"type":46,"tag":250,"props":24589,"children":24590},{"style":375},[24591],{"type":52,"value":10064},{"type":46,"tag":250,"props":24593,"children":24594},{"style":274},[24595],{"type":52,"value":19752},{"type":46,"tag":250,"props":24597,"children":24598},{"style":268},[24599],{"type":52,"value":106},{"type":46,"tag":250,"props":24601,"children":24602},{"style":274},[24603],{"type":52,"value":22497},{"type":46,"tag":250,"props":24605,"children":24606},{"style":375},[24607],{"type":52,"value":10041},{"type":46,"tag":250,"props":24609,"children":24610},{"style":274},[24611],{"type":52,"value":23277},{"type":46,"tag":250,"props":24613,"children":24614},{"style":268},[24615],{"type":52,"value":106},{"type":46,"tag":250,"props":24617,"children":24618},{"style":274},[24619],{"type":52,"value":22683},{"type":46,"tag":250,"props":24621,"children":24622},{"class":252,"line":23325},[24623,24627,24631,24635,24639,24643,24647,24651,24655,24659],{"type":46,"tag":250,"props":24624,"children":24625},{"style":375},[24626],{"type":52,"value":17462},{"type":46,"tag":250,"props":24628,"children":24629},{"style":274},[24630],{"type":52,"value":19752},{"type":46,"tag":250,"props":24632,"children":24633},{"style":268},[24634],{"type":52,"value":106},{"type":46,"tag":250,"props":24636,"children":24637},{"style":274},[24638],{"type":52,"value":22716},{"type":46,"tag":250,"props":24640,"children":24641},{"style":375},[24642],{"type":52,"value":11066},{"type":46,"tag":250,"props":24644,"children":24645},{"style":268},[24646],{"type":52,"value":151},{"type":46,"tag":250,"props":24648,"children":24649},{"style":274},[24650],{"type":52,"value":19548},{"type":46,"tag":250,"props":24652,"children":24653},{"style":268},[24654],{"type":52,"value":106},{"type":46,"tag":250,"props":24656,"children":24657},{"style":274},[24658],{"type":52,"value":22762},{"type":46,"tag":250,"props":24660,"children":24661},{"style":375},[24662],{"type":52,"value":23367},{"type":46,"tag":429,"props":24664,"children":24665},{"v-slot:snowflake":7},[24666],{"type":46,"tag":240,"props":24667,"children":24669},{"className":9175,"code":24668,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_marketing_roi\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - staging.stg_marketing_spend\n  - staging.stg_web_sessions\n  - staging.stg_orders\ncolumns:\n  - name: channel\n    type: varchar\n    checks:\n      - name: not_null\n@bruin *\u002F\n\nWITH channel_spend AS (\n    SELECT\n        spend_date,\n        channel,\n        sum(spend) AS total_spend,\n        sum(impressions) AS total_impressions,\n        sum(clicks) AS total_clicks,\n        sum(conversions) AS total_conversions\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date, channel\n),\nchannel_sessions AS (\n    SELECT\n        session_date,\n        channel,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_users,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date, channel\n),\nchannel_revenue AS (\n    SELECT\n        order_date::DATE AS order_date,\n        ws.channel,\n        sum(o.order_total) AS attributed_revenue\n    FROM staging.stg_orders o\n    INNER JOIN staging.stg_web_sessions ws\n        ON order_date::DATE = ws.session_date\n    WHERE o.payment_status = 'paid'\n    GROUP BY order_date::DATE, ws.channel\n)\nSELECT\n    cs.spend_date AS report_date,\n    cs.channel,\n    cs.total_spend,\n    cs.total_impressions,\n    cs.total_clicks,\n    cs.total_conversions,\n    sess.sessions,\n    sess.new_users,\n    cr.attributed_revenue,\n    round(cr.attributed_revenue \u002F NULLIF(cs.total_spend, 0), 2) AS roas,\n    round(cs.total_spend \u002F NULLIF(cs.total_conversions, 0), 2) AS cost_per_acquisition,\n    round(cs.total_clicks \u002F NULLIF(cs.total_impressions, 0) * 100, 2) AS click_through_rate\nFROM channel_spend cs\nLEFT JOIN channel_sessions sess\n    ON cs.spend_date = sess.session_date\n    AND cs.channel = sess.channel\nLEFT JOIN channel_revenue cr\n    ON cs.spend_date = cr.order_date\n    AND cs.channel = cr.channel\nORDER BY cs.spend_date DESC, cs.total_spend DESC\n",[24670],{"type":46,"tag":99,"props":24671,"children":24672},{"__ignoreMap":7},[24673,24680,24687,24694,24701,24708,24715,24722,24729,24736,24743,24750,24757,24764,24771,24778,24785,24804,24811,24818,24825,24844,24863,24882,24901,24920,24931,24938,24953,24960,24967,24974,24997,25016,25035,25054,25065,25072,25087,25094,25114,25133,25168,25191,25214,25245,25272,25303,25310,25317,25340,25359,25378,25397,25416,25435,25454,25473,25492,25567,25642,25729,25740,25751,25786,25821,25832,25867,25902],{"type":46,"tag":250,"props":24674,"children":24675},{"class":252,"line":23},[24676],{"type":46,"tag":250,"props":24677,"children":24678},{"style":9187},[24679],{"type":52,"value":9190},{"type":46,"tag":250,"props":24681,"children":24682},{"class":252,"line":285},[24683],{"type":46,"tag":250,"props":24684,"children":24685},{"style":9187},[24686],{"type":52,"value":22030},{"type":46,"tag":250,"props":24688,"children":24689},{"class":252,"line":299},[24690],{"type":46,"tag":250,"props":24691,"children":24692},{"style":9187},[24693],{"type":52,"value":9206},{"type":46,"tag":250,"props":24695,"children":24696},{"class":252,"line":807},[24697],{"type":46,"tag":250,"props":24698,"children":24699},{"style":9187},[24700],{"type":52,"value":9214},{"type":46,"tag":250,"props":24702,"children":24703},{"class":252,"line":820},[24704],{"type":46,"tag":250,"props":24705,"children":24706},{"style":9187},[24707],{"type":52,"value":9222},{"type":46,"tag":250,"props":24709,"children":24710},{"class":252,"line":844},[24711],{"type":46,"tag":250,"props":24712,"children":24713},{"style":9187},[24714],{"type":52,"value":9230},{"type":46,"tag":250,"props":24716,"children":24717},{"class":252,"line":862},[24718],{"type":46,"tag":250,"props":24719,"children":24720},{"style":9187},[24721],{"type":52,"value":22066},{"type":46,"tag":250,"props":24723,"children":24724},{"class":252,"line":11},[24725],{"type":46,"tag":250,"props":24726,"children":24727},{"style":9187},[24728],{"type":52,"value":22074},{"type":46,"tag":250,"props":24730,"children":24731},{"class":252,"line":4649},[24732],{"type":46,"tag":250,"props":24733,"children":24734},{"style":9187},[24735],{"type":52,"value":16980},{"type":46,"tag":250,"props":24737,"children":24738},{"class":252,"line":9257},[24739],{"type":46,"tag":250,"props":24740,"children":24741},{"style":9187},[24742],{"type":52,"value":9254},{"type":46,"tag":250,"props":24744,"children":24745},{"class":252,"line":9266},[24746],{"type":46,"tag":250,"props":24747,"children":24748},{"style":9187},[24749],{"type":52,"value":22096},{"type":46,"tag":250,"props":24751,"children":24752},{"class":252,"line":9275},[24753],{"type":46,"tag":250,"props":24754,"children":24755},{"style":9187},[24756],{"type":52,"value":9272},{"type":46,"tag":250,"props":24758,"children":24759},{"class":252,"line":9284},[24760],{"type":46,"tag":250,"props":24761,"children":24762},{"style":9187},[24763],{"type":52,"value":9281},{"type":46,"tag":250,"props":24765,"children":24766},{"class":252,"line":9293},[24767],{"type":46,"tag":250,"props":24768,"children":24769},{"style":9187},[24770],{"type":52,"value":9290},{"type":46,"tag":250,"props":24772,"children":24773},{"class":252,"line":4121},[24774],{"type":46,"tag":250,"props":24775,"children":24776},{"style":9187},[24777],{"type":52,"value":9377},{"type":46,"tag":250,"props":24779,"children":24780},{"class":252,"line":9310},[24781],{"type":46,"tag":250,"props":24782,"children":24783},{"emptyLinePlaceholder":22},[24784],{"type":52,"value":9386},{"type":46,"tag":250,"props":24786,"children":24787},{"class":252,"line":9319},[24788,24792,24796,24800],{"type":46,"tag":250,"props":24789,"children":24790},{"style":375},[24791],{"type":52,"value":19021},{"type":46,"tag":250,"props":24793,"children":24794},{"style":268},[24795],{"type":52,"value":22143},{"type":46,"tag":250,"props":24797,"children":24798},{"style":375},[24799],{"type":52,"value":9608},{"type":46,"tag":250,"props":24801,"children":24802},{"style":268},[24803],{"type":52,"value":19035},{"type":46,"tag":250,"props":24805,"children":24806},{"class":252,"line":9327},[24807],{"type":46,"tag":250,"props":24808,"children":24809},{"style":375},[24810],{"type":52,"value":19043},{"type":46,"tag":250,"props":24812,"children":24813},{"class":252,"line":9335},[24814],{"type":46,"tag":250,"props":24815,"children":24816},{"style":268},[24817],{"type":52,"value":22166},{"type":46,"tag":250,"props":24819,"children":24820},{"class":252,"line":9344},[24821],{"type":46,"tag":250,"props":24822,"children":24823},{"style":268},[24824],{"type":52,"value":22174},{"type":46,"tag":250,"props":24826,"children":24827},{"class":252,"line":9353},[24828,24832,24836,24840],{"type":46,"tag":250,"props":24829,"children":24830},{"style":274},[24831],{"type":52,"value":22182},{"type":46,"tag":250,"props":24833,"children":24834},{"style":268},[24835],{"type":52,"value":22187},{"type":46,"tag":250,"props":24837,"children":24838},{"style":375},[24839],{"type":52,"value":9608},{"type":46,"tag":250,"props":24841,"children":24842},{"style":268},[24843],{"type":52,"value":22196},{"type":46,"tag":250,"props":24845,"children":24846},{"class":252,"line":9362},[24847,24851,24855,24859],{"type":46,"tag":250,"props":24848,"children":24849},{"style":274},[24850],{"type":52,"value":22182},{"type":46,"tag":250,"props":24852,"children":24853},{"style":268},[24854],{"type":52,"value":22208},{"type":46,"tag":250,"props":24856,"children":24857},{"style":375},[24858],{"type":52,"value":9608},{"type":46,"tag":250,"props":24860,"children":24861},{"style":268},[24862],{"type":52,"value":22217},{"type":46,"tag":250,"props":24864,"children":24865},{"class":252,"line":9371},[24866,24870,24874,24878],{"type":46,"tag":250,"props":24867,"children":24868},{"style":274},[24869],{"type":52,"value":22182},{"type":46,"tag":250,"props":24871,"children":24872},{"style":268},[24873],{"type":52,"value":22229},{"type":46,"tag":250,"props":24875,"children":24876},{"style":375},[24877],{"type":52,"value":9608},{"type":46,"tag":250,"props":24879,"children":24880},{"style":268},[24881],{"type":52,"value":22238},{"type":46,"tag":250,"props":24883,"children":24884},{"class":252,"line":9380},[24885,24889,24893,24897],{"type":46,"tag":250,"props":24886,"children":24887},{"style":274},[24888],{"type":52,"value":22182},{"type":46,"tag":250,"props":24890,"children":24891},{"style":268},[24892],{"type":52,"value":22250},{"type":46,"tag":250,"props":24894,"children":24895},{"style":375},[24896],{"type":52,"value":9608},{"type":46,"tag":250,"props":24898,"children":24899},{"style":268},[24900],{"type":52,"value":22259},{"type":46,"tag":250,"props":24902,"children":24903},{"class":252,"line":9389},[24904,24908,24912,24916],{"type":46,"tag":250,"props":24905,"children":24906},{"style":375},[24907],{"type":52,"value":19155},{"type":46,"tag":250,"props":24909,"children":24910},{"style":274},[24911],{"type":52,"value":17433},{"type":46,"tag":250,"props":24913,"children":24914},{"style":268},[24915],{"type":52,"value":106},{"type":46,"tag":250,"props":24917,"children":24918},{"style":274},[24919],{"type":52,"value":22279},{"type":46,"tag":250,"props":24921,"children":24922},{"class":252,"line":9398},[24923,24927],{"type":46,"tag":250,"props":24924,"children":24925},{"style":375},[24926],{"type":52,"value":19353},{"type":46,"tag":250,"props":24928,"children":24929},{"style":268},[24930],{"type":52,"value":22291},{"type":46,"tag":250,"props":24932,"children":24933},{"class":252,"line":9426},[24934],{"type":46,"tag":250,"props":24935,"children":24936},{"style":268},[24937],{"type":52,"value":19271},{"type":46,"tag":250,"props":24939,"children":24940},{"class":252,"line":9448},[24941,24945,24949],{"type":46,"tag":250,"props":24942,"children":24943},{"style":268},[24944],{"type":52,"value":22306},{"type":46,"tag":250,"props":24946,"children":24947},{"style":375},[24948],{"type":52,"value":9608},{"type":46,"tag":250,"props":24950,"children":24951},{"style":268},[24952],{"type":52,"value":19035},{"type":46,"tag":250,"props":24954,"children":24955},{"class":252,"line":9474},[24956],{"type":46,"tag":250,"props":24957,"children":24958},{"style":375},[24959],{"type":52,"value":19043},{"type":46,"tag":250,"props":24961,"children":24962},{"class":252,"line":9500},[24963],{"type":46,"tag":250,"props":24964,"children":24965},{"style":268},[24966],{"type":52,"value":22329},{"type":46,"tag":250,"props":24968,"children":24969},{"class":252,"line":9525},[24970],{"type":46,"tag":250,"props":24971,"children":24972},{"style":268},[24973],{"type":52,"value":22174},{"type":46,"tag":250,"props":24975,"children":24976},{"class":252,"line":9546},[24977,24981,24985,24989,24993],{"type":46,"tag":250,"props":24978,"children":24979},{"style":274},[24980],{"type":52,"value":22182},{"type":46,"tag":250,"props":24982,"children":24983},{"style":268},[24984],{"type":52,"value":22348},{"type":46,"tag":250,"props":24986,"children":24987},{"style":375},[24988],{"type":52,"value":9608},{"type":46,"tag":250,"props":24990,"children":24991},{"style":375},[24992],{"type":52,"value":22357},{"type":46,"tag":250,"props":24994,"children":24995},{"style":268},[24996],{"type":52,"value":9445},{"type":46,"tag":250,"props":24998,"children":24999},{"class":252,"line":9616},[25000,25004,25008,25012],{"type":46,"tag":250,"props":25001,"children":25002},{"style":274},[25003],{"type":52,"value":22182},{"type":46,"tag":250,"props":25005,"children":25006},{"style":268},[25007],{"type":52,"value":22373},{"type":46,"tag":250,"props":25009,"children":25010},{"style":375},[25011],{"type":52,"value":9608},{"type":46,"tag":250,"props":25013,"children":25014},{"style":268},[25015],{"type":52,"value":15604},{"type":46,"tag":250,"props":25017,"children":25018},{"class":252,"line":9678},[25019,25023,25027,25031],{"type":46,"tag":250,"props":25020,"children":25021},{"style":274},[25022],{"type":52,"value":22182},{"type":46,"tag":250,"props":25024,"children":25025},{"style":268},[25026],{"type":52,"value":22393},{"type":46,"tag":250,"props":25028,"children":25029},{"style":375},[25030],{"type":52,"value":9608},{"type":46,"tag":250,"props":25032,"children":25033},{"style":268},[25034],{"type":52,"value":22402},{"type":46,"tag":250,"props":25036,"children":25037},{"class":252,"line":9740},[25038,25042,25046,25050],{"type":46,"tag":250,"props":25039,"children":25040},{"style":375},[25041],{"type":52,"value":19155},{"type":46,"tag":250,"props":25043,"children":25044},{"style":274},[25045],{"type":52,"value":17433},{"type":46,"tag":250,"props":25047,"children":25048},{"style":268},[25049],{"type":52,"value":106},{"type":46,"tag":250,"props":25051,"children":25052},{"style":274},[25053],{"type":52,"value":22422},{"type":46,"tag":250,"props":25055,"children":25056},{"class":252,"line":9802},[25057,25061],{"type":46,"tag":250,"props":25058,"children":25059},{"style":375},[25060],{"type":52,"value":19353},{"type":46,"tag":250,"props":25062,"children":25063},{"style":268},[25064],{"type":52,"value":22434},{"type":46,"tag":250,"props":25066,"children":25067},{"class":252,"line":9823},[25068],{"type":46,"tag":250,"props":25069,"children":25070},{"style":268},[25071],{"type":52,"value":19271},{"type":46,"tag":250,"props":25073,"children":25074},{"class":252,"line":9844},[25075,25079,25083],{"type":46,"tag":250,"props":25076,"children":25077},{"style":268},[25078],{"type":52,"value":22449},{"type":46,"tag":250,"props":25080,"children":25081},{"style":375},[25082],{"type":52,"value":9608},{"type":46,"tag":250,"props":25084,"children":25085},{"style":268},[25086],{"type":52,"value":19035},{"type":46,"tag":250,"props":25088,"children":25089},{"class":252,"line":9865},[25090],{"type":46,"tag":250,"props":25091,"children":25092},{"style":375},[25093],{"type":52,"value":19043},{"type":46,"tag":250,"props":25095,"children":25096},{"class":252,"line":9911},[25097,25102,25106,25110],{"type":46,"tag":250,"props":25098,"children":25099},{"style":268},[25100],{"type":52,"value":25101},"        order_date::",{"type":46,"tag":250,"props":25103,"children":25104},{"style":375},[25105],{"type":52,"value":11882},{"type":46,"tag":250,"props":25107,"children":25108},{"style":375},[25109],{"type":52,"value":9418},{"type":46,"tag":250,"props":25111,"children":25112},{"style":268},[25113],{"type":52,"value":9497},{"type":46,"tag":250,"props":25115,"children":25116},{"class":252,"line":9937},[25117,25121,25125,25129],{"type":46,"tag":250,"props":25118,"children":25119},{"style":274},[25120],{"type":52,"value":22488},{"type":46,"tag":250,"props":25122,"children":25123},{"style":268},[25124],{"type":52,"value":106},{"type":46,"tag":250,"props":25126,"children":25127},{"style":274},[25128],{"type":52,"value":22497},{"type":46,"tag":250,"props":25130,"children":25131},{"style":268},[25132],{"type":52,"value":9445},{"type":46,"tag":250,"props":25134,"children":25135},{"class":252,"line":9963},[25136,25140,25144,25148,25152,25156,25160,25164],{"type":46,"tag":250,"props":25137,"children":25138},{"style":274},[25139],{"type":52,"value":22182},{"type":46,"tag":250,"props":25141,"children":25142},{"style":268},[25143],{"type":52,"value":9557},{"type":46,"tag":250,"props":25145,"children":25146},{"style":274},[25147],{"type":52,"value":9562},{"type":46,"tag":250,"props":25149,"children":25150},{"style":268},[25151],{"type":52,"value":106},{"type":46,"tag":250,"props":25153,"children":25154},{"style":274},[25155],{"type":52,"value":19621},{"type":46,"tag":250,"props":25157,"children":25158},{"style":268},[25159],{"type":52,"value":10086},{"type":46,"tag":250,"props":25161,"children":25162},{"style":375},[25163],{"type":52,"value":9608},{"type":46,"tag":250,"props":25165,"children":25166},{"style":268},[25167],{"type":52,"value":22537},{"type":46,"tag":250,"props":25169,"children":25170},{"class":252,"line":9991},[25171,25175,25179,25183,25187],{"type":46,"tag":250,"props":25172,"children":25173},{"style":375},[25174],{"type":52,"value":19155},{"type":46,"tag":250,"props":25176,"children":25177},{"style":274},[25178],{"type":52,"value":17433},{"type":46,"tag":250,"props":25180,"children":25181},{"style":268},[25182],{"type":52,"value":106},{"type":46,"tag":250,"props":25184,"children":25185},{"style":274},[25186],{"type":52,"value":18055},{"type":46,"tag":250,"props":25188,"children":25189},{"style":268},[25190],{"type":52,"value":9988},{"type":46,"tag":250,"props":25192,"children":25193},{"class":252,"line":10017},[25194,25198,25202,25206,25210],{"type":46,"tag":250,"props":25195,"children":25196},{"style":375},[25197],{"type":52,"value":19179},{"type":46,"tag":250,"props":25199,"children":25200},{"style":274},[25201],{"type":52,"value":17433},{"type":46,"tag":250,"props":25203,"children":25204},{"style":268},[25205],{"type":52,"value":106},{"type":46,"tag":250,"props":25207,"children":25208},{"style":274},[25209],{"type":52,"value":22580},{"type":46,"tag":250,"props":25211,"children":25212},{"style":268},[25213],{"type":52,"value":22585},{"type":46,"tag":250,"props":25215,"children":25216},{"class":252,"line":10058},[25217,25221,25225,25229,25233,25237,25241],{"type":46,"tag":250,"props":25218,"children":25219},{"style":375},[25220],{"type":52,"value":19204},{"type":46,"tag":250,"props":25222,"children":25223},{"style":268},[25224],{"type":52,"value":18846},{"type":46,"tag":250,"props":25226,"children":25227},{"style":375},[25228],{"type":52,"value":11882},{"type":46,"tag":250,"props":25230,"children":25231},{"style":375},[25232],{"type":52,"value":10041},{"type":46,"tag":250,"props":25234,"children":25235},{"style":274},[25236],{"type":52,"value":22621},{"type":46,"tag":250,"props":25238,"children":25239},{"style":268},[25240],{"type":52,"value":106},{"type":46,"tag":250,"props":25242,"children":25243},{"style":274},[25244],{"type":52,"value":22630},{"type":46,"tag":250,"props":25246,"children":25247},{"class":252,"line":10936},[25248,25252,25256,25260,25264,25268],{"type":46,"tag":250,"props":25249,"children":25250},{"style":375},[25251],{"type":52,"value":19241},{"type":46,"tag":250,"props":25253,"children":25254},{"style":274},[25255],{"type":52,"value":10028},{"type":46,"tag":250,"props":25257,"children":25258},{"style":268},[25259],{"type":52,"value":106},{"type":46,"tag":250,"props":25261,"children":25262},{"style":274},[25263],{"type":52,"value":19254},{"type":46,"tag":250,"props":25265,"children":25266},{"style":375},[25267],{"type":52,"value":10041},{"type":46,"tag":250,"props":25269,"children":25270},{"style":262},[25271],{"type":52,"value":19263},{"type":46,"tag":250,"props":25273,"children":25274},{"class":252,"line":10995},[25275,25279,25283,25287,25291,25295,25299],{"type":46,"tag":250,"props":25276,"children":25277},{"style":375},[25278],{"type":52,"value":19353},{"type":46,"tag":250,"props":25280,"children":25281},{"style":268},[25282],{"type":52,"value":18846},{"type":46,"tag":250,"props":25284,"children":25285},{"style":375},[25286],{"type":52,"value":11882},{"type":46,"tag":250,"props":25288,"children":25289},{"style":268},[25290],{"type":52,"value":151},{"type":46,"tag":250,"props":25292,"children":25293},{"style":274},[25294],{"type":52,"value":22674},{"type":46,"tag":250,"props":25296,"children":25297},{"style":268},[25298],{"type":52,"value":106},{"type":46,"tag":250,"props":25300,"children":25301},{"style":274},[25302],{"type":52,"value":22683},{"type":46,"tag":250,"props":25304,"children":25305},{"class":252,"line":22686},[25306],{"type":46,"tag":250,"props":25307,"children":25308},{"style":268},[25309],{"type":52,"value":10114},{"type":46,"tag":250,"props":25311,"children":25312},{"class":252,"line":22694},[25313],{"type":46,"tag":250,"props":25314,"children":25315},{"style":375},[25316],{"type":52,"value":9395},{"type":46,"tag":250,"props":25318,"children":25319},{"class":252,"line":22702},[25320,25324,25328,25332,25336],{"type":46,"tag":250,"props":25321,"children":25322},{"style":274},[25323],{"type":52,"value":19401},{"type":46,"tag":250,"props":25325,"children":25326},{"style":268},[25327],{"type":52,"value":106},{"type":46,"tag":250,"props":25329,"children":25330},{"style":274},[25331],{"type":52,"value":22716},{"type":46,"tag":250,"props":25333,"children":25334},{"style":375},[25335],{"type":52,"value":9418},{"type":46,"tag":250,"props":25337,"children":25338},{"style":268},[25339],{"type":52,"value":22725},{"type":46,"tag":250,"props":25341,"children":25342},{"class":252,"line":22728},[25343,25347,25351,25355],{"type":46,"tag":250,"props":25344,"children":25345},{"style":274},[25346],{"type":52,"value":19401},{"type":46,"tag":250,"props":25348,"children":25349},{"style":268},[25350],{"type":52,"value":106},{"type":46,"tag":250,"props":25352,"children":25353},{"style":274},[25354],{"type":52,"value":22497},{"type":46,"tag":250,"props":25356,"children":25357},{"style":268},[25358],{"type":52,"value":9445},{"type":46,"tag":250,"props":25360,"children":25361},{"class":252,"line":22748},[25362,25366,25370,25374],{"type":46,"tag":250,"props":25363,"children":25364},{"style":274},[25365],{"type":52,"value":19401},{"type":46,"tag":250,"props":25367,"children":25368},{"style":268},[25369],{"type":52,"value":106},{"type":46,"tag":250,"props":25371,"children":25372},{"style":274},[25373],{"type":52,"value":22762},{"type":46,"tag":250,"props":25375,"children":25376},{"style":268},[25377],{"type":52,"value":9445},{"type":46,"tag":250,"props":25379,"children":25380},{"class":252,"line":22769},[25381,25385,25389,25393],{"type":46,"tag":250,"props":25382,"children":25383},{"style":274},[25384],{"type":52,"value":19401},{"type":46,"tag":250,"props":25386,"children":25387},{"style":268},[25388],{"type":52,"value":106},{"type":46,"tag":250,"props":25390,"children":25391},{"style":274},[25392],{"type":52,"value":22783},{"type":46,"tag":250,"props":25394,"children":25395},{"style":268},[25396],{"type":52,"value":9445},{"type":46,"tag":250,"props":25398,"children":25399},{"class":252,"line":22790},[25400,25404,25408,25412],{"type":46,"tag":250,"props":25401,"children":25402},{"style":274},[25403],{"type":52,"value":19401},{"type":46,"tag":250,"props":25405,"children":25406},{"style":268},[25407],{"type":52,"value":106},{"type":46,"tag":250,"props":25409,"children":25410},{"style":274},[25411],{"type":52,"value":22804},{"type":46,"tag":250,"props":25413,"children":25414},{"style":268},[25415],{"type":52,"value":9445},{"type":46,"tag":250,"props":25417,"children":25418},{"class":252,"line":22811},[25419,25423,25427,25431],{"type":46,"tag":250,"props":25420,"children":25421},{"style":274},[25422],{"type":52,"value":19401},{"type":46,"tag":250,"props":25424,"children":25425},{"style":268},[25426],{"type":52,"value":106},{"type":46,"tag":250,"props":25428,"children":25429},{"style":274},[25430],{"type":52,"value":22825},{"type":46,"tag":250,"props":25432,"children":25433},{"style":268},[25434],{"type":52,"value":9445},{"type":46,"tag":250,"props":25436,"children":25437},{"class":252,"line":22832},[25438,25442,25446,25450],{"type":46,"tag":250,"props":25439,"children":25440},{"style":274},[25441],{"type":52,"value":22838},{"type":46,"tag":250,"props":25443,"children":25444},{"style":268},[25445],{"type":52,"value":106},{"type":46,"tag":250,"props":25447,"children":25448},{"style":274},[25449],{"type":52,"value":15030},{"type":46,"tag":250,"props":25451,"children":25452},{"style":268},[25453],{"type":52,"value":9445},{"type":46,"tag":250,"props":25455,"children":25456},{"class":252,"line":22853},[25457,25461,25465,25469],{"type":46,"tag":250,"props":25458,"children":25459},{"style":274},[25460],{"type":52,"value":22838},{"type":46,"tag":250,"props":25462,"children":25463},{"style":268},[25464],{"type":52,"value":106},{"type":46,"tag":250,"props":25466,"children":25467},{"style":274},[25468],{"type":52,"value":15055},{"type":46,"tag":250,"props":25470,"children":25471},{"style":268},[25472],{"type":52,"value":9445},{"type":46,"tag":250,"props":25474,"children":25475},{"class":252,"line":22873},[25476,25480,25484,25488],{"type":46,"tag":250,"props":25477,"children":25478},{"style":274},[25479],{"type":52,"value":22879},{"type":46,"tag":250,"props":25481,"children":25482},{"style":268},[25483],{"type":52,"value":106},{"type":46,"tag":250,"props":25485,"children":25486},{"style":274},[25487],{"type":52,"value":22888},{"type":46,"tag":250,"props":25489,"children":25490},{"style":268},[25491],{"type":52,"value":9445},{"type":46,"tag":250,"props":25493,"children":25494},{"class":252,"line":22895},[25495,25499,25503,25507,25511,25515,25519,25523,25527,25531,25535,25539,25543,25547,25551,25555,25559,25563],{"type":46,"tag":250,"props":25496,"children":25497},{"style":274},[25498],{"type":52,"value":17313},{"type":46,"tag":250,"props":25500,"children":25501},{"style":268},[25502],{"type":52,"value":9557},{"type":46,"tag":250,"props":25504,"children":25505},{"style":274},[25506],{"type":52,"value":22909},{"type":46,"tag":250,"props":25508,"children":25509},{"style":268},[25510],{"type":52,"value":106},{"type":46,"tag":250,"props":25512,"children":25513},{"style":274},[25514],{"type":52,"value":22888},{"type":46,"tag":250,"props":25516,"children":25517},{"style":375},[25518],{"type":52,"value":9885},{"type":46,"tag":250,"props":25520,"children":25521},{"style":274},[25522],{"type":52,"value":17909},{"type":46,"tag":250,"props":25524,"children":25525},{"style":268},[25526],{"type":52,"value":9557},{"type":46,"tag":250,"props":25528,"children":25529},{"style":274},[25530],{"type":52,"value":19548},{"type":46,"tag":250,"props":25532,"children":25533},{"style":268},[25534],{"type":52,"value":106},{"type":46,"tag":250,"props":25536,"children":25537},{"style":274},[25538],{"type":52,"value":22762},{"type":46,"tag":250,"props":25540,"children":25541},{"style":268},[25542],{"type":52,"value":151},{"type":46,"tag":250,"props":25544,"children":25545},{"style":274},[25546],{"type":52,"value":9899},{"type":46,"tag":250,"props":25548,"children":25549},{"style":268},[25550],{"type":52,"value":17342},{"type":46,"tag":250,"props":25552,"children":25553},{"style":274},[25554],{"type":52,"value":9598},{"type":46,"tag":250,"props":25556,"children":25557},{"style":268},[25558],{"type":52,"value":10086},{"type":46,"tag":250,"props":25560,"children":25561},{"style":375},[25562],{"type":52,"value":9608},{"type":46,"tag":250,"props":25564,"children":25565},{"style":268},[25566],{"type":52,"value":22970},{"type":46,"tag":250,"props":25568,"children":25569},{"class":252,"line":22973},[25570,25574,25578,25582,25586,25590,25594,25598,25602,25606,25610,25614,25618,25622,25626,25630,25634,25638],{"type":46,"tag":250,"props":25571,"children":25572},{"style":274},[25573],{"type":52,"value":17313},{"type":46,"tag":250,"props":25575,"children":25576},{"style":268},[25577],{"type":52,"value":9557},{"type":46,"tag":250,"props":25579,"children":25580},{"style":274},[25581],{"type":52,"value":19548},{"type":46,"tag":250,"props":25583,"children":25584},{"style":268},[25585],{"type":52,"value":106},{"type":46,"tag":250,"props":25587,"children":25588},{"style":274},[25589],{"type":52,"value":22762},{"type":46,"tag":250,"props":25591,"children":25592},{"style":375},[25593],{"type":52,"value":9885},{"type":46,"tag":250,"props":25595,"children":25596},{"style":274},[25597],{"type":52,"value":17909},{"type":46,"tag":250,"props":25599,"children":25600},{"style":268},[25601],{"type":52,"value":9557},{"type":46,"tag":250,"props":25603,"children":25604},{"style":274},[25605],{"type":52,"value":19548},{"type":46,"tag":250,"props":25607,"children":25608},{"style":268},[25609],{"type":52,"value":106},{"type":46,"tag":250,"props":25611,"children":25612},{"style":274},[25613],{"type":52,"value":22825},{"type":46,"tag":250,"props":25615,"children":25616},{"style":268},[25617],{"type":52,"value":151},{"type":46,"tag":250,"props":25619,"children":25620},{"style":274},[25621],{"type":52,"value":9899},{"type":46,"tag":250,"props":25623,"children":25624},{"style":268},[25625],{"type":52,"value":17342},{"type":46,"tag":250,"props":25627,"children":25628},{"style":274},[25629],{"type":52,"value":9598},{"type":46,"tag":250,"props":25631,"children":25632},{"style":268},[25633],{"type":52,"value":10086},{"type":46,"tag":250,"props":25635,"children":25636},{"style":375},[25637],{"type":52,"value":9608},{"type":46,"tag":250,"props":25639,"children":25640},{"style":268},[25641],{"type":52,"value":23047},{"type":46,"tag":250,"props":25643,"children":25644},{"class":252,"line":23050},[25645,25649,25653,25657,25661,25665,25669,25673,25677,25681,25685,25689,25693,25697,25701,25705,25709,25713,25717,25721,25725],{"type":46,"tag":250,"props":25646,"children":25647},{"style":274},[25648],{"type":52,"value":17313},{"type":46,"tag":250,"props":25650,"children":25651},{"style":268},[25652],{"type":52,"value":9557},{"type":46,"tag":250,"props":25654,"children":25655},{"style":274},[25656],{"type":52,"value":19548},{"type":46,"tag":250,"props":25658,"children":25659},{"style":268},[25660],{"type":52,"value":106},{"type":46,"tag":250,"props":25662,"children":25663},{"style":274},[25664],{"type":52,"value":22804},{"type":46,"tag":250,"props":25666,"children":25667},{"style":375},[25668],{"type":52,"value":9885},{"type":46,"tag":250,"props":25670,"children":25671},{"style":274},[25672],{"type":52,"value":17909},{"type":46,"tag":250,"props":25674,"children":25675},{"style":268},[25676],{"type":52,"value":9557},{"type":46,"tag":250,"props":25678,"children":25679},{"style":274},[25680],{"type":52,"value":19548},{"type":46,"tag":250,"props":25682,"children":25683},{"style":268},[25684],{"type":52,"value":106},{"type":46,"tag":250,"props":25686,"children":25687},{"style":274},[25688],{"type":52,"value":22783},{"type":46,"tag":250,"props":25690,"children":25691},{"style":268},[25692],{"type":52,"value":151},{"type":46,"tag":250,"props":25694,"children":25695},{"style":274},[25696],{"type":52,"value":9899},{"type":46,"tag":250,"props":25698,"children":25699},{"style":268},[25700],{"type":52,"value":10086},{"type":46,"tag":250,"props":25702,"children":25703},{"style":375},[25704],{"type":52,"value":15522},{"type":46,"tag":250,"props":25706,"children":25707},{"style":274},[25708],{"type":52,"value":9890},{"type":46,"tag":250,"props":25710,"children":25711},{"style":268},[25712],{"type":52,"value":151},{"type":46,"tag":250,"props":25714,"children":25715},{"style":274},[25716],{"type":52,"value":9598},{"type":46,"tag":250,"props":25718,"children":25719},{"style":268},[25720],{"type":52,"value":10086},{"type":46,"tag":250,"props":25722,"children":25723},{"style":375},[25724],{"type":52,"value":9608},{"type":46,"tag":250,"props":25726,"children":25727},{"style":268},[25728],{"type":52,"value":23136},{"type":46,"tag":250,"props":25730,"children":25731},{"class":252,"line":23139},[25732,25736],{"type":46,"tag":250,"props":25733,"children":25734},{"style":375},[25735],{"type":52,"value":9969},{"type":46,"tag":250,"props":25737,"children":25738},{"style":268},[25739],{"type":52,"value":23149},{"type":46,"tag":250,"props":25741,"children":25742},{"class":252,"line":23152},[25743,25747],{"type":46,"tag":250,"props":25744,"children":25745},{"style":375},[25746],{"type":52,"value":9077},{"type":46,"tag":250,"props":25748,"children":25749},{"style":268},[25750],{"type":52,"value":23162},{"type":46,"tag":250,"props":25752,"children":25753},{"class":252,"line":23165},[25754,25758,25762,25766,25770,25774,25778,25782],{"type":46,"tag":250,"props":25755,"children":25756},{"style":375},[25757],{"type":52,"value":10023},{"type":46,"tag":250,"props":25759,"children":25760},{"style":274},[25761],{"type":52,"value":19752},{"type":46,"tag":250,"props":25763,"children":25764},{"style":268},[25765],{"type":52,"value":106},{"type":46,"tag":250,"props":25767,"children":25768},{"style":274},[25769],{"type":52,"value":22716},{"type":46,"tag":250,"props":25771,"children":25772},{"style":375},[25773],{"type":52,"value":10041},{"type":46,"tag":250,"props":25775,"children":25776},{"style":274},[25777],{"type":52,"value":23191},{"type":46,"tag":250,"props":25779,"children":25780},{"style":268},[25781],{"type":52,"value":106},{"type":46,"tag":250,"props":25783,"children":25784},{"style":274},[25785],{"type":52,"value":22630},{"type":46,"tag":250,"props":25787,"children":25788},{"class":252,"line":23202},[25789,25793,25797,25801,25805,25809,25813,25817],{"type":46,"tag":250,"props":25790,"children":25791},{"style":375},[25792],{"type":52,"value":10064},{"type":46,"tag":250,"props":25794,"children":25795},{"style":274},[25796],{"type":52,"value":19752},{"type":46,"tag":250,"props":25798,"children":25799},{"style":268},[25800],{"type":52,"value":106},{"type":46,"tag":250,"props":25802,"children":25803},{"style":274},[25804],{"type":52,"value":22497},{"type":46,"tag":250,"props":25806,"children":25807},{"style":375},[25808],{"type":52,"value":10041},{"type":46,"tag":250,"props":25810,"children":25811},{"style":274},[25812],{"type":52,"value":23191},{"type":46,"tag":250,"props":25814,"children":25815},{"style":268},[25816],{"type":52,"value":106},{"type":46,"tag":250,"props":25818,"children":25819},{"style":274},[25820],{"type":52,"value":22683},{"type":46,"tag":250,"props":25822,"children":25823},{"class":252,"line":23238},[25824,25828],{"type":46,"tag":250,"props":25825,"children":25826},{"style":375},[25827],{"type":52,"value":9077},{"type":46,"tag":250,"props":25829,"children":25830},{"style":268},[25831],{"type":52,"value":23248},{"type":46,"tag":250,"props":25833,"children":25834},{"class":252,"line":23251},[25835,25839,25843,25847,25851,25855,25859,25863],{"type":46,"tag":250,"props":25836,"children":25837},{"style":375},[25838],{"type":52,"value":10023},{"type":46,"tag":250,"props":25840,"children":25841},{"style":274},[25842],{"type":52,"value":19752},{"type":46,"tag":250,"props":25844,"children":25845},{"style":268},[25846],{"type":52,"value":106},{"type":46,"tag":250,"props":25848,"children":25849},{"style":274},[25850],{"type":52,"value":22716},{"type":46,"tag":250,"props":25852,"children":25853},{"style":375},[25854],{"type":52,"value":10041},{"type":46,"tag":250,"props":25856,"children":25857},{"style":274},[25858],{"type":52,"value":23277},{"type":46,"tag":250,"props":25860,"children":25861},{"style":268},[25862],{"type":52,"value":106},{"type":46,"tag":250,"props":25864,"children":25865},{"style":274},[25866],{"type":52,"value":23286},{"type":46,"tag":250,"props":25868,"children":25869},{"class":252,"line":23289},[25870,25874,25878,25882,25886,25890,25894,25898],{"type":46,"tag":250,"props":25871,"children":25872},{"style":375},[25873],{"type":52,"value":10064},{"type":46,"tag":250,"props":25875,"children":25876},{"style":274},[25877],{"type":52,"value":19752},{"type":46,"tag":250,"props":25879,"children":25880},{"style":268},[25881],{"type":52,"value":106},{"type":46,"tag":250,"props":25883,"children":25884},{"style":274},[25885],{"type":52,"value":22497},{"type":46,"tag":250,"props":25887,"children":25888},{"style":375},[25889],{"type":52,"value":10041},{"type":46,"tag":250,"props":25891,"children":25892},{"style":274},[25893],{"type":52,"value":23277},{"type":46,"tag":250,"props":25895,"children":25896},{"style":268},[25897],{"type":52,"value":106},{"type":46,"tag":250,"props":25899,"children":25900},{"style":274},[25901],{"type":52,"value":22683},{"type":46,"tag":250,"props":25903,"children":25904},{"class":252,"line":23325},[25905,25909,25913,25917,25921,25925,25929,25933,25937,25941],{"type":46,"tag":250,"props":25906,"children":25907},{"style":375},[25908],{"type":52,"value":17462},{"type":46,"tag":250,"props":25910,"children":25911},{"style":274},[25912],{"type":52,"value":19752},{"type":46,"tag":250,"props":25914,"children":25915},{"style":268},[25916],{"type":52,"value":106},{"type":46,"tag":250,"props":25918,"children":25919},{"style":274},[25920],{"type":52,"value":22716},{"type":46,"tag":250,"props":25922,"children":25923},{"style":375},[25924],{"type":52,"value":11066},{"type":46,"tag":250,"props":25926,"children":25927},{"style":268},[25928],{"type":52,"value":151},{"type":46,"tag":250,"props":25930,"children":25931},{"style":274},[25932],{"type":52,"value":19548},{"type":46,"tag":250,"props":25934,"children":25935},{"style":268},[25936],{"type":52,"value":106},{"type":46,"tag":250,"props":25938,"children":25939},{"style":274},[25940],{"type":52,"value":22762},{"type":46,"tag":250,"props":25942,"children":25943},{"style":375},[25944],{"type":52,"value":23367},{"type":46,"tag":220,"props":25946,"children":25948},{"id":25947},"_5-daily-kpis-rpt_daily_kpissql",[25949,25951],{"type":52,"value":25950},"5) Daily KPIs - ",{"type":46,"tag":99,"props":25952,"children":25954},{"className":25953},[],[25955],{"type":52,"value":25956},"rpt_daily_kpis.sql",{"type":46,"tag":55,"props":25958,"children":25959},{},[25960],{"type":52,"value":25961},"A single unified daily view of the whole business. One table, all the numbers that matter.",{"type":46,"tag":55,"props":25963,"children":25964},{},[25965,25966,25975],{"type":52,"value":9155},{"type":46,"tag":80,"props":25967,"children":25968},{},[25969],{"type":46,"tag":99,"props":25970,"children":25972},{"className":25971},[],[25973],{"type":52,"value":25974},"ecommerce\u002Fassets\u002Freports\u002Frpt_daily_kpis.sql",{"type":52,"value":9166},{"type":46,"tag":423,"props":25977,"children":25978},{":variants":425,"group":426},[25979,27242,28488],{"type":46,"tag":429,"props":25980,"children":25981},{"v-slot:clickhouse":7},[25982],{"type":46,"tag":240,"props":25983,"children":25985},{"className":9175,"code":25984,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_kpis\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - reports.rpt_daily_revenue\n  - staging.stg_customers\n  - staging.stg_orders\n  - staging.stg_web_sessions\n  - staging.stg_marketing_spend\ncolumns:\n  - name: kpi_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nWITH daily_customers AS (\n    SELECT\n        toDate(o.order_date) AS order_date,\n        countIf(toDate(c.first_seen_at) = toDate(o.order_date)) AS new_customers,\n        countIf(toDate(c.first_seen_at) \u003C toDate(o.order_date)) AS returning_customers\n    FROM staging.stg_orders o\n    LEFT JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n    GROUP BY toDate(o.order_date)\n),\ndaily_sessions AS (\n    SELECT\n        session_date,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_visitors,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date\n),\ndaily_spend AS (\n    SELECT\n        spend_date,\n        sum(spend) AS total_ad_spend\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date\n)\nSELECT\n    r.order_date AS kpi_date,\n    r.net_revenue,\n    r.total_orders,\n    r.paid_orders,\n    r.avg_order_value,\n    r.cancellation_rate,\n    dc.new_customers,\n    dc.returning_customers,\n    ds.sessions,\n    ds.new_visitors,\n    round(ds.purchases \u002F nullIf(ds.sessions, 0) * 100, 2) AS conversion_rate,\n    sp.total_ad_spend,\n    round(r.net_revenue \u002F nullIf(sp.total_ad_spend, 0), 2) AS overall_roas\nFROM reports.rpt_daily_revenue r\nLEFT JOIN daily_customers dc ON r.order_date = dc.order_date\nLEFT JOIN daily_sessions ds ON r.order_date = ds.session_date\nLEFT JOIN daily_spend sp ON r.order_date = sp.spend_date\nORDER BY kpi_date DESC\n",[25986],{"type":46,"tag":99,"props":25987,"children":25988},{"__ignoreMap":7},[25989,25996,26004,26011,26018,26025,26032,26040,26047,26054,26061,26068,26075,26083,26090,26097,26104,26111,26118,26125,26145,26152,26184,26241,26298,26321,26345,26380,26407,26434,26441,26457,26464,26471,26494,26514,26533,26552,26564,26571,26587,26594,26601,26621,26640,26652,26659,26666,26691,26711,26731,26751,26771,26791,26812,26832,26852,26872,26962,26983,27061,27087,27134,27179,27225],{"type":46,"tag":250,"props":25990,"children":25991},{"class":252,"line":23},[25992],{"type":46,"tag":250,"props":25993,"children":25994},{"style":9187},[25995],{"type":52,"value":9190},{"type":46,"tag":250,"props":25997,"children":25998},{"class":252,"line":285},[25999],{"type":46,"tag":250,"props":26000,"children":26001},{"style":9187},[26002],{"type":52,"value":26003},"name: reports.rpt_daily_kpis\n",{"type":46,"tag":250,"props":26005,"children":26006},{"class":252,"line":299},[26007],{"type":46,"tag":250,"props":26008,"children":26009},{"style":9187},[26010],{"type":52,"value":9206},{"type":46,"tag":250,"props":26012,"children":26013},{"class":252,"line":807},[26014],{"type":46,"tag":250,"props":26015,"children":26016},{"style":9187},[26017],{"type":52,"value":9214},{"type":46,"tag":250,"props":26019,"children":26020},{"class":252,"line":820},[26021],{"type":46,"tag":250,"props":26022,"children":26023},{"style":9187},[26024],{"type":52,"value":9222},{"type":46,"tag":250,"props":26026,"children":26027},{"class":252,"line":844},[26028],{"type":46,"tag":250,"props":26029,"children":26030},{"style":9187},[26031],{"type":52,"value":9230},{"type":46,"tag":250,"props":26033,"children":26034},{"class":252,"line":862},[26035],{"type":46,"tag":250,"props":26036,"children":26037},{"style":9187},[26038],{"type":52,"value":26039},"  - reports.rpt_daily_revenue\n",{"type":46,"tag":250,"props":26041,"children":26042},{"class":252,"line":11},[26043],{"type":46,"tag":250,"props":26044,"children":26045},{"style":9187},[26046],{"type":52,"value":18963},{"type":46,"tag":250,"props":26048,"children":26049},{"class":252,"line":4649},[26050],{"type":46,"tag":250,"props":26051,"children":26052},{"style":9187},[26053],{"type":52,"value":16980},{"type":46,"tag":250,"props":26055,"children":26056},{"class":252,"line":9257},[26057],{"type":46,"tag":250,"props":26058,"children":26059},{"style":9187},[26060],{"type":52,"value":22074},{"type":46,"tag":250,"props":26062,"children":26063},{"class":252,"line":9266},[26064],{"type":46,"tag":250,"props":26065,"children":26066},{"style":9187},[26067],{"type":52,"value":22066},{"type":46,"tag":250,"props":26069,"children":26070},{"class":252,"line":9275},[26071],{"type":46,"tag":250,"props":26072,"children":26073},{"style":9187},[26074],{"type":52,"value":9254},{"type":46,"tag":250,"props":26076,"children":26077},{"class":252,"line":9284},[26078],{"type":46,"tag":250,"props":26079,"children":26080},{"style":9187},[26081],{"type":52,"value":26082},"  - name: kpi_date\n",{"type":46,"tag":250,"props":26084,"children":26085},{"class":252,"line":9293},[26086],{"type":46,"tag":250,"props":26087,"children":26088},{"style":9187},[26089],{"type":52,"value":13288},{"type":46,"tag":250,"props":26091,"children":26092},{"class":252,"line":4121},[26093],{"type":46,"tag":250,"props":26094,"children":26095},{"style":9187},[26096],{"type":52,"value":9281},{"type":46,"tag":250,"props":26098,"children":26099},{"class":252,"line":9310},[26100],{"type":46,"tag":250,"props":26101,"children":26102},{"style":9187},[26103],{"type":52,"value":9290},{"type":46,"tag":250,"props":26105,"children":26106},{"class":252,"line":9319},[26107],{"type":46,"tag":250,"props":26108,"children":26109},{"style":9187},[26110],{"type":52,"value":9299},{"type":46,"tag":250,"props":26112,"children":26113},{"class":252,"line":9327},[26114],{"type":46,"tag":250,"props":26115,"children":26116},{"style":9187},[26117],{"type":52,"value":9377},{"type":46,"tag":250,"props":26119,"children":26120},{"class":252,"line":9335},[26121],{"type":46,"tag":250,"props":26122,"children":26123},{"emptyLinePlaceholder":22},[26124],{"type":52,"value":9386},{"type":46,"tag":250,"props":26126,"children":26127},{"class":252,"line":9344},[26128,26132,26137,26141],{"type":46,"tag":250,"props":26129,"children":26130},{"style":375},[26131],{"type":52,"value":19021},{"type":46,"tag":250,"props":26133,"children":26134},{"style":268},[26135],{"type":52,"value":26136}," daily_customers ",{"type":46,"tag":250,"props":26138,"children":26139},{"style":375},[26140],{"type":52,"value":9608},{"type":46,"tag":250,"props":26142,"children":26143},{"style":268},[26144],{"type":52,"value":19035},{"type":46,"tag":250,"props":26146,"children":26147},{"class":252,"line":9353},[26148],{"type":46,"tag":250,"props":26149,"children":26150},{"style":375},[26151],{"type":52,"value":19043},{"type":46,"tag":250,"props":26153,"children":26154},{"class":252,"line":9362},[26155,26160,26164,26168,26172,26176,26180],{"type":46,"tag":250,"props":26156,"children":26157},{"style":268},[26158],{"type":52,"value":26159},"        toDate(",{"type":46,"tag":250,"props":26161,"children":26162},{"style":274},[26163],{"type":52,"value":9562},{"type":46,"tag":250,"props":26165,"children":26166},{"style":268},[26167],{"type":52,"value":106},{"type":46,"tag":250,"props":26169,"children":26170},{"style":274},[26171],{"type":52,"value":19118},{"type":46,"tag":250,"props":26173,"children":26174},{"style":268},[26175],{"type":52,"value":10086},{"type":46,"tag":250,"props":26177,"children":26178},{"style":375},[26179],{"type":52,"value":9608},{"type":46,"tag":250,"props":26181,"children":26182},{"style":268},[26183],{"type":52,"value":9497},{"type":46,"tag":250,"props":26185,"children":26186},{"class":252,"line":9371},[26187,26192,26196,26200,26204,26208,26212,26216,26220,26224,26228,26232,26236],{"type":46,"tag":250,"props":26188,"children":26189},{"style":268},[26190],{"type":52,"value":26191},"        countIf(toDate(",{"type":46,"tag":250,"props":26193,"children":26194},{"style":274},[26195],{"type":52,"value":10100},{"type":46,"tag":250,"props":26197,"children":26198},{"style":268},[26199],{"type":52,"value":106},{"type":46,"tag":250,"props":26201,"children":26202},{"style":274},[26203],{"type":52,"value":19085},{"type":46,"tag":250,"props":26205,"children":26206},{"style":268},[26207],{"type":52,"value":10086},{"type":46,"tag":250,"props":26209,"children":26210},{"style":375},[26211],{"type":52,"value":10091},{"type":46,"tag":250,"props":26213,"children":26214},{"style":268},[26215],{"type":52,"value":10069},{"type":46,"tag":250,"props":26217,"children":26218},{"style":274},[26219],{"type":52,"value":9562},{"type":46,"tag":250,"props":26221,"children":26222},{"style":268},[26223],{"type":52,"value":106},{"type":46,"tag":250,"props":26225,"children":26226},{"style":274},[26227],{"type":52,"value":19118},{"type":46,"tag":250,"props":26229,"children":26230},{"style":268},[26231],{"type":52,"value":9603},{"type":46,"tag":250,"props":26233,"children":26234},{"style":375},[26235],{"type":52,"value":9608},{"type":46,"tag":250,"props":26237,"children":26238},{"style":268},[26239],{"type":52,"value":26240}," new_customers,\n",{"type":46,"tag":250,"props":26242,"children":26243},{"class":252,"line":9380},[26244,26248,26252,26256,26260,26264,26269,26273,26277,26281,26285,26289,26293],{"type":46,"tag":250,"props":26245,"children":26246},{"style":268},[26247],{"type":52,"value":26191},{"type":46,"tag":250,"props":26249,"children":26250},{"style":274},[26251],{"type":52,"value":10100},{"type":46,"tag":250,"props":26253,"children":26254},{"style":268},[26255],{"type":52,"value":106},{"type":46,"tag":250,"props":26257,"children":26258},{"style":274},[26259],{"type":52,"value":19085},{"type":46,"tag":250,"props":26261,"children":26262},{"style":268},[26263],{"type":52,"value":10086},{"type":46,"tag":250,"props":26265,"children":26266},{"style":375},[26267],{"type":52,"value":26268},"\u003C",{"type":46,"tag":250,"props":26270,"children":26271},{"style":268},[26272],{"type":52,"value":10069},{"type":46,"tag":250,"props":26274,"children":26275},{"style":274},[26276],{"type":52,"value":9562},{"type":46,"tag":250,"props":26278,"children":26279},{"style":268},[26280],{"type":52,"value":106},{"type":46,"tag":250,"props":26282,"children":26283},{"style":274},[26284],{"type":52,"value":19118},{"type":46,"tag":250,"props":26286,"children":26287},{"style":268},[26288],{"type":52,"value":9603},{"type":46,"tag":250,"props":26290,"children":26291},{"style":375},[26292],{"type":52,"value":9608},{"type":46,"tag":250,"props":26294,"children":26295},{"style":268},[26296],{"type":52,"value":26297}," returning_customers\n",{"type":46,"tag":250,"props":26299,"children":26300},{"class":252,"line":9389},[26301,26305,26309,26313,26317],{"type":46,"tag":250,"props":26302,"children":26303},{"style":375},[26304],{"type":52,"value":19155},{"type":46,"tag":250,"props":26306,"children":26307},{"style":274},[26308],{"type":52,"value":17433},{"type":46,"tag":250,"props":26310,"children":26311},{"style":268},[26312],{"type":52,"value":106},{"type":46,"tag":250,"props":26314,"children":26315},{"style":274},[26316],{"type":52,"value":18055},{"type":46,"tag":250,"props":26318,"children":26319},{"style":268},[26320],{"type":52,"value":9988},{"type":46,"tag":250,"props":26322,"children":26323},{"class":252,"line":9398},[26324,26329,26333,26337,26341],{"type":46,"tag":250,"props":26325,"children":26326},{"style":375},[26327],{"type":52,"value":26328},"    LEFT JOIN",{"type":46,"tag":250,"props":26330,"children":26331},{"style":274},[26332],{"type":52,"value":17433},{"type":46,"tag":250,"props":26334,"children":26335},{"style":268},[26336],{"type":52,"value":106},{"type":46,"tag":250,"props":26338,"children":26339},{"style":274},[26340],{"type":52,"value":19192},{"type":46,"tag":250,"props":26342,"children":26343},{"style":268},[26344],{"type":52,"value":10014},{"type":46,"tag":250,"props":26346,"children":26347},{"class":252,"line":9426},[26348,26352,26356,26360,26364,26368,26372,26376],{"type":46,"tag":250,"props":26349,"children":26350},{"style":375},[26351],{"type":52,"value":19204},{"type":46,"tag":250,"props":26353,"children":26354},{"style":274},[26355],{"type":52,"value":10028},{"type":46,"tag":250,"props":26357,"children":26358},{"style":268},[26359],{"type":52,"value":106},{"type":46,"tag":250,"props":26361,"children":26362},{"style":274},[26363],{"type":52,"value":19060},{"type":46,"tag":250,"props":26365,"children":26366},{"style":375},[26367],{"type":52,"value":10041},{"type":46,"tag":250,"props":26369,"children":26370},{"style":274},[26371],{"type":52,"value":10046},{"type":46,"tag":250,"props":26373,"children":26374},{"style":268},[26375],{"type":52,"value":106},{"type":46,"tag":250,"props":26377,"children":26378},{"style":274},[26379],{"type":52,"value":19233},{"type":46,"tag":250,"props":26381,"children":26382},{"class":252,"line":9448},[26383,26387,26391,26395,26399,26403],{"type":46,"tag":250,"props":26384,"children":26385},{"style":375},[26386],{"type":52,"value":19241},{"type":46,"tag":250,"props":26388,"children":26389},{"style":274},[26390],{"type":52,"value":10028},{"type":46,"tag":250,"props":26392,"children":26393},{"style":268},[26394],{"type":52,"value":106},{"type":46,"tag":250,"props":26396,"children":26397},{"style":274},[26398],{"type":52,"value":19254},{"type":46,"tag":250,"props":26400,"children":26401},{"style":375},[26402],{"type":52,"value":10041},{"type":46,"tag":250,"props":26404,"children":26405},{"style":262},[26406],{"type":52,"value":19263},{"type":46,"tag":250,"props":26408,"children":26409},{"class":252,"line":9474},[26410,26414,26418,26422,26426,26430],{"type":46,"tag":250,"props":26411,"children":26412},{"style":375},[26413],{"type":52,"value":19353},{"type":46,"tag":250,"props":26415,"children":26416},{"style":268},[26417],{"type":52,"value":10069},{"type":46,"tag":250,"props":26419,"children":26420},{"style":274},[26421],{"type":52,"value":9562},{"type":46,"tag":250,"props":26423,"children":26424},{"style":268},[26425],{"type":52,"value":106},{"type":46,"tag":250,"props":26427,"children":26428},{"style":274},[26429],{"type":52,"value":19118},{"type":46,"tag":250,"props":26431,"children":26432},{"style":268},[26433],{"type":52,"value":10114},{"type":46,"tag":250,"props":26435,"children":26436},{"class":252,"line":9500},[26437],{"type":46,"tag":250,"props":26438,"children":26439},{"style":268},[26440],{"type":52,"value":19271},{"type":46,"tag":250,"props":26442,"children":26443},{"class":252,"line":9525},[26444,26449,26453],{"type":46,"tag":250,"props":26445,"children":26446},{"style":268},[26447],{"type":52,"value":26448},"daily_sessions ",{"type":46,"tag":250,"props":26450,"children":26451},{"style":375},[26452],{"type":52,"value":9608},{"type":46,"tag":250,"props":26454,"children":26455},{"style":268},[26456],{"type":52,"value":19035},{"type":46,"tag":250,"props":26458,"children":26459},{"class":252,"line":9546},[26460],{"type":46,"tag":250,"props":26461,"children":26462},{"style":375},[26463],{"type":52,"value":19043},{"type":46,"tag":250,"props":26465,"children":26466},{"class":252,"line":9616},[26467],{"type":46,"tag":250,"props":26468,"children":26469},{"style":268},[26470],{"type":52,"value":22329},{"type":46,"tag":250,"props":26472,"children":26473},{"class":252,"line":9678},[26474,26478,26482,26486,26490],{"type":46,"tag":250,"props":26475,"children":26476},{"style":274},[26477],{"type":52,"value":22182},{"type":46,"tag":250,"props":26479,"children":26480},{"style":268},[26481],{"type":52,"value":22348},{"type":46,"tag":250,"props":26483,"children":26484},{"style":375},[26485],{"type":52,"value":9608},{"type":46,"tag":250,"props":26487,"children":26488},{"style":375},[26489],{"type":52,"value":22357},{"type":46,"tag":250,"props":26491,"children":26492},{"style":268},[26493],{"type":52,"value":9445},{"type":46,"tag":250,"props":26495,"children":26496},{"class":252,"line":9740},[26497,26501,26505,26509],{"type":46,"tag":250,"props":26498,"children":26499},{"style":274},[26500],{"type":52,"value":22182},{"type":46,"tag":250,"props":26502,"children":26503},{"style":268},[26504],{"type":52,"value":22373},{"type":46,"tag":250,"props":26506,"children":26507},{"style":375},[26508],{"type":52,"value":9608},{"type":46,"tag":250,"props":26510,"children":26511},{"style":268},[26512],{"type":52,"value":26513}," new_visitors,\n",{"type":46,"tag":250,"props":26515,"children":26516},{"class":252,"line":9802},[26517,26521,26525,26529],{"type":46,"tag":250,"props":26518,"children":26519},{"style":274},[26520],{"type":52,"value":22182},{"type":46,"tag":250,"props":26522,"children":26523},{"style":268},[26524],{"type":52,"value":22393},{"type":46,"tag":250,"props":26526,"children":26527},{"style":375},[26528],{"type":52,"value":9608},{"type":46,"tag":250,"props":26530,"children":26531},{"style":268},[26532],{"type":52,"value":22402},{"type":46,"tag":250,"props":26534,"children":26535},{"class":252,"line":9823},[26536,26540,26544,26548],{"type":46,"tag":250,"props":26537,"children":26538},{"style":375},[26539],{"type":52,"value":19155},{"type":46,"tag":250,"props":26541,"children":26542},{"style":274},[26543],{"type":52,"value":17433},{"type":46,"tag":250,"props":26545,"children":26546},{"style":268},[26547],{"type":52,"value":106},{"type":46,"tag":250,"props":26549,"children":26550},{"style":274},[26551],{"type":52,"value":22422},{"type":46,"tag":250,"props":26553,"children":26554},{"class":252,"line":9844},[26555,26559],{"type":46,"tag":250,"props":26556,"children":26557},{"style":375},[26558],{"type":52,"value":19353},{"type":46,"tag":250,"props":26560,"children":26561},{"style":268},[26562],{"type":52,"value":26563}," session_date\n",{"type":46,"tag":250,"props":26565,"children":26566},{"class":252,"line":9865},[26567],{"type":46,"tag":250,"props":26568,"children":26569},{"style":268},[26570],{"type":52,"value":19271},{"type":46,"tag":250,"props":26572,"children":26573},{"class":252,"line":9911},[26574,26579,26583],{"type":46,"tag":250,"props":26575,"children":26576},{"style":268},[26577],{"type":52,"value":26578},"daily_spend ",{"type":46,"tag":250,"props":26580,"children":26581},{"style":375},[26582],{"type":52,"value":9608},{"type":46,"tag":250,"props":26584,"children":26585},{"style":268},[26586],{"type":52,"value":19035},{"type":46,"tag":250,"props":26588,"children":26589},{"class":252,"line":9937},[26590],{"type":46,"tag":250,"props":26591,"children":26592},{"style":375},[26593],{"type":52,"value":19043},{"type":46,"tag":250,"props":26595,"children":26596},{"class":252,"line":9963},[26597],{"type":46,"tag":250,"props":26598,"children":26599},{"style":268},[26600],{"type":52,"value":22166},{"type":46,"tag":250,"props":26602,"children":26603},{"class":252,"line":9991},[26604,26608,26612,26616],{"type":46,"tag":250,"props":26605,"children":26606},{"style":274},[26607],{"type":52,"value":22182},{"type":46,"tag":250,"props":26609,"children":26610},{"style":268},[26611],{"type":52,"value":22187},{"type":46,"tag":250,"props":26613,"children":26614},{"style":375},[26615],{"type":52,"value":9608},{"type":46,"tag":250,"props":26617,"children":26618},{"style":268},[26619],{"type":52,"value":26620}," total_ad_spend\n",{"type":46,"tag":250,"props":26622,"children":26623},{"class":252,"line":10017},[26624,26628,26632,26636],{"type":46,"tag":250,"props":26625,"children":26626},{"style":375},[26627],{"type":52,"value":19155},{"type":46,"tag":250,"props":26629,"children":26630},{"style":274},[26631],{"type":52,"value":17433},{"type":46,"tag":250,"props":26633,"children":26634},{"style":268},[26635],{"type":52,"value":106},{"type":46,"tag":250,"props":26637,"children":26638},{"style":274},[26639],{"type":52,"value":22279},{"type":46,"tag":250,"props":26641,"children":26642},{"class":252,"line":10058},[26643,26647],{"type":46,"tag":250,"props":26644,"children":26645},{"style":375},[26646],{"type":52,"value":19353},{"type":46,"tag":250,"props":26648,"children":26649},{"style":268},[26650],{"type":52,"value":26651}," spend_date\n",{"type":46,"tag":250,"props":26653,"children":26654},{"class":252,"line":10936},[26655],{"type":46,"tag":250,"props":26656,"children":26657},{"style":268},[26658],{"type":52,"value":10114},{"type":46,"tag":250,"props":26660,"children":26661},{"class":252,"line":10995},[26662],{"type":46,"tag":250,"props":26663,"children":26664},{"style":375},[26665],{"type":52,"value":9395},{"type":46,"tag":250,"props":26667,"children":26668},{"class":252,"line":22686},[26669,26674,26678,26682,26686],{"type":46,"tag":250,"props":26670,"children":26671},{"style":274},[26672],{"type":52,"value":26673},"    r",{"type":46,"tag":250,"props":26675,"children":26676},{"style":268},[26677],{"type":52,"value":106},{"type":46,"tag":250,"props":26679,"children":26680},{"style":274},[26681],{"type":52,"value":19118},{"type":46,"tag":250,"props":26683,"children":26684},{"style":375},[26685],{"type":52,"value":9418},{"type":46,"tag":250,"props":26687,"children":26688},{"style":268},[26689],{"type":52,"value":26690}," kpi_date,\n",{"type":46,"tag":250,"props":26692,"children":26693},{"class":252,"line":22694},[26694,26698,26702,26707],{"type":46,"tag":250,"props":26695,"children":26696},{"style":274},[26697],{"type":52,"value":26673},{"type":46,"tag":250,"props":26699,"children":26700},{"style":268},[26701],{"type":52,"value":106},{"type":46,"tag":250,"props":26703,"children":26704},{"style":274},[26705],{"type":52,"value":26706},"net_revenue",{"type":46,"tag":250,"props":26708,"children":26709},{"style":268},[26710],{"type":52,"value":9445},{"type":46,"tag":250,"props":26712,"children":26713},{"class":252,"line":22702},[26714,26718,26722,26727],{"type":46,"tag":250,"props":26715,"children":26716},{"style":274},[26717],{"type":52,"value":26673},{"type":46,"tag":250,"props":26719,"children":26720},{"style":268},[26721],{"type":52,"value":106},{"type":46,"tag":250,"props":26723,"children":26724},{"style":274},[26725],{"type":52,"value":26726},"total_orders",{"type":46,"tag":250,"props":26728,"children":26729},{"style":268},[26730],{"type":52,"value":9445},{"type":46,"tag":250,"props":26732,"children":26733},{"class":252,"line":22728},[26734,26738,26742,26747],{"type":46,"tag":250,"props":26735,"children":26736},{"style":274},[26737],{"type":52,"value":26673},{"type":46,"tag":250,"props":26739,"children":26740},{"style":268},[26741],{"type":52,"value":106},{"type":46,"tag":250,"props":26743,"children":26744},{"style":274},[26745],{"type":52,"value":26746},"paid_orders",{"type":46,"tag":250,"props":26748,"children":26749},{"style":268},[26750],{"type":52,"value":9445},{"type":46,"tag":250,"props":26752,"children":26753},{"class":252,"line":22748},[26754,26758,26762,26767],{"type":46,"tag":250,"props":26755,"children":26756},{"style":274},[26757],{"type":52,"value":26673},{"type":46,"tag":250,"props":26759,"children":26760},{"style":268},[26761],{"type":52,"value":106},{"type":46,"tag":250,"props":26763,"children":26764},{"style":274},[26765],{"type":52,"value":26766},"avg_order_value",{"type":46,"tag":250,"props":26768,"children":26769},{"style":268},[26770],{"type":52,"value":9445},{"type":46,"tag":250,"props":26772,"children":26773},{"class":252,"line":22769},[26774,26778,26782,26787],{"type":46,"tag":250,"props":26775,"children":26776},{"style":274},[26777],{"type":52,"value":26673},{"type":46,"tag":250,"props":26779,"children":26780},{"style":268},[26781],{"type":52,"value":106},{"type":46,"tag":250,"props":26783,"children":26784},{"style":274},[26785],{"type":52,"value":26786},"cancellation_rate",{"type":46,"tag":250,"props":26788,"children":26789},{"style":268},[26790],{"type":52,"value":9445},{"type":46,"tag":250,"props":26792,"children":26793},{"class":252,"line":22790},[26794,26799,26803,26808],{"type":46,"tag":250,"props":26795,"children":26796},{"style":274},[26797],{"type":52,"value":26798},"    dc",{"type":46,"tag":250,"props":26800,"children":26801},{"style":268},[26802],{"type":52,"value":106},{"type":46,"tag":250,"props":26804,"children":26805},{"style":274},[26806],{"type":52,"value":26807},"new_customers",{"type":46,"tag":250,"props":26809,"children":26810},{"style":268},[26811],{"type":52,"value":9445},{"type":46,"tag":250,"props":26813,"children":26814},{"class":252,"line":22811},[26815,26819,26823,26828],{"type":46,"tag":250,"props":26816,"children":26817},{"style":274},[26818],{"type":52,"value":26798},{"type":46,"tag":250,"props":26820,"children":26821},{"style":268},[26822],{"type":52,"value":106},{"type":46,"tag":250,"props":26824,"children":26825},{"style":274},[26826],{"type":52,"value":26827},"returning_customers",{"type":46,"tag":250,"props":26829,"children":26830},{"style":268},[26831],{"type":52,"value":9445},{"type":46,"tag":250,"props":26833,"children":26834},{"class":252,"line":22832},[26835,26840,26844,26848],{"type":46,"tag":250,"props":26836,"children":26837},{"style":274},[26838],{"type":52,"value":26839},"    ds",{"type":46,"tag":250,"props":26841,"children":26842},{"style":268},[26843],{"type":52,"value":106},{"type":46,"tag":250,"props":26845,"children":26846},{"style":274},[26847],{"type":52,"value":15030},{"type":46,"tag":250,"props":26849,"children":26850},{"style":268},[26851],{"type":52,"value":9445},{"type":46,"tag":250,"props":26853,"children":26854},{"class":252,"line":22853},[26855,26859,26863,26868],{"type":46,"tag":250,"props":26856,"children":26857},{"style":274},[26858],{"type":52,"value":26839},{"type":46,"tag":250,"props":26860,"children":26861},{"style":268},[26862],{"type":52,"value":106},{"type":46,"tag":250,"props":26864,"children":26865},{"style":274},[26866],{"type":52,"value":26867},"new_visitors",{"type":46,"tag":250,"props":26869,"children":26870},{"style":268},[26871],{"type":52,"value":9445},{"type":46,"tag":250,"props":26873,"children":26874},{"class":252,"line":22873},[26875,26879,26883,26888,26892,26897,26901,26905,26909,26913,26917,26921,26925,26929,26933,26937,26941,26945,26949,26953,26957],{"type":46,"tag":250,"props":26876,"children":26877},{"style":274},[26878],{"type":52,"value":17313},{"type":46,"tag":250,"props":26880,"children":26881},{"style":268},[26882],{"type":52,"value":9557},{"type":46,"tag":250,"props":26884,"children":26885},{"style":274},[26886],{"type":52,"value":26887},"ds",{"type":46,"tag":250,"props":26889,"children":26890},{"style":268},[26891],{"type":52,"value":106},{"type":46,"tag":250,"props":26893,"children":26894},{"style":274},[26895],{"type":52,"value":26896},"purchases",{"type":46,"tag":250,"props":26898,"children":26899},{"style":375},[26900],{"type":52,"value":9885},{"type":46,"tag":250,"props":26902,"children":26903},{"style":274},[26904],{"type":52,"value":17328},{"type":46,"tag":250,"props":26906,"children":26907},{"style":268},[26908],{"type":52,"value":9557},{"type":46,"tag":250,"props":26910,"children":26911},{"style":274},[26912],{"type":52,"value":26887},{"type":46,"tag":250,"props":26914,"children":26915},{"style":268},[26916],{"type":52,"value":106},{"type":46,"tag":250,"props":26918,"children":26919},{"style":274},[26920],{"type":52,"value":15030},{"type":46,"tag":250,"props":26922,"children":26923},{"style":268},[26924],{"type":52,"value":151},{"type":46,"tag":250,"props":26926,"children":26927},{"style":274},[26928],{"type":52,"value":9899},{"type":46,"tag":250,"props":26930,"children":26931},{"style":268},[26932],{"type":52,"value":10086},{"type":46,"tag":250,"props":26934,"children":26935},{"style":375},[26936],{"type":52,"value":15522},{"type":46,"tag":250,"props":26938,"children":26939},{"style":274},[26940],{"type":52,"value":9890},{"type":46,"tag":250,"props":26942,"children":26943},{"style":268},[26944],{"type":52,"value":151},{"type":46,"tag":250,"props":26946,"children":26947},{"style":274},[26948],{"type":52,"value":9598},{"type":46,"tag":250,"props":26950,"children":26951},{"style":268},[26952],{"type":52,"value":10086},{"type":46,"tag":250,"props":26954,"children":26955},{"style":375},[26956],{"type":52,"value":9608},{"type":46,"tag":250,"props":26958,"children":26959},{"style":268},[26960],{"type":52,"value":26961}," conversion_rate,\n",{"type":46,"tag":250,"props":26963,"children":26964},{"class":252,"line":22895},[26965,26970,26974,26979],{"type":46,"tag":250,"props":26966,"children":26967},{"style":274},[26968],{"type":52,"value":26969},"    sp",{"type":46,"tag":250,"props":26971,"children":26972},{"style":268},[26973],{"type":52,"value":106},{"type":46,"tag":250,"props":26975,"children":26976},{"style":274},[26977],{"type":52,"value":26978},"total_ad_spend",{"type":46,"tag":250,"props":26980,"children":26981},{"style":268},[26982],{"type":52,"value":9445},{"type":46,"tag":250,"props":26984,"children":26985},{"class":252,"line":22973},[26986,26990,26994,26999,27003,27007,27011,27015,27019,27024,27028,27032,27036,27040,27044,27048,27052,27056],{"type":46,"tag":250,"props":26987,"children":26988},{"style":274},[26989],{"type":52,"value":17313},{"type":46,"tag":250,"props":26991,"children":26992},{"style":268},[26993],{"type":52,"value":9557},{"type":46,"tag":250,"props":26995,"children":26996},{"style":274},[26997],{"type":52,"value":26998},"r",{"type":46,"tag":250,"props":27000,"children":27001},{"style":268},[27002],{"type":52,"value":106},{"type":46,"tag":250,"props":27004,"children":27005},{"style":274},[27006],{"type":52,"value":26706},{"type":46,"tag":250,"props":27008,"children":27009},{"style":375},[27010],{"type":52,"value":9885},{"type":46,"tag":250,"props":27012,"children":27013},{"style":274},[27014],{"type":52,"value":17328},{"type":46,"tag":250,"props":27016,"children":27017},{"style":268},[27018],{"type":52,"value":9557},{"type":46,"tag":250,"props":27020,"children":27021},{"style":274},[27022],{"type":52,"value":27023},"sp",{"type":46,"tag":250,"props":27025,"children":27026},{"style":268},[27027],{"type":52,"value":106},{"type":46,"tag":250,"props":27029,"children":27030},{"style":274},[27031],{"type":52,"value":26978},{"type":46,"tag":250,"props":27033,"children":27034},{"style":268},[27035],{"type":52,"value":151},{"type":46,"tag":250,"props":27037,"children":27038},{"style":274},[27039],{"type":52,"value":9899},{"type":46,"tag":250,"props":27041,"children":27042},{"style":268},[27043],{"type":52,"value":17342},{"type":46,"tag":250,"props":27045,"children":27046},{"style":274},[27047],{"type":52,"value":9598},{"type":46,"tag":250,"props":27049,"children":27050},{"style":268},[27051],{"type":52,"value":10086},{"type":46,"tag":250,"props":27053,"children":27054},{"style":375},[27055],{"type":52,"value":9608},{"type":46,"tag":250,"props":27057,"children":27058},{"style":268},[27059],{"type":52,"value":27060}," overall_roas\n",{"type":46,"tag":250,"props":27062,"children":27063},{"class":252,"line":23050},[27064,27068,27073,27077,27082],{"type":46,"tag":250,"props":27065,"children":27066},{"style":375},[27067],{"type":52,"value":9969},{"type":46,"tag":250,"props":27069,"children":27070},{"style":274},[27071],{"type":52,"value":27072}," reports",{"type":46,"tag":250,"props":27074,"children":27075},{"style":268},[27076],{"type":52,"value":106},{"type":46,"tag":250,"props":27078,"children":27079},{"style":274},[27080],{"type":52,"value":27081},"rpt_daily_revenue",{"type":46,"tag":250,"props":27083,"children":27084},{"style":268},[27085],{"type":52,"value":27086}," r\n",{"type":46,"tag":250,"props":27088,"children":27089},{"class":252,"line":23139},[27090,27094,27099,27104,27109,27113,27117,27121,27126,27130],{"type":46,"tag":250,"props":27091,"children":27092},{"style":375},[27093],{"type":52,"value":9077},{"type":46,"tag":250,"props":27095,"children":27096},{"style":268},[27097],{"type":52,"value":27098}," daily_customers dc ",{"type":46,"tag":250,"props":27100,"children":27101},{"style":375},[27102],{"type":52,"value":27103},"ON",{"type":46,"tag":250,"props":27105,"children":27106},{"style":274},[27107],{"type":52,"value":27108}," r",{"type":46,"tag":250,"props":27110,"children":27111},{"style":268},[27112],{"type":52,"value":106},{"type":46,"tag":250,"props":27114,"children":27115},{"style":274},[27116],{"type":52,"value":19118},{"type":46,"tag":250,"props":27118,"children":27119},{"style":375},[27120],{"type":52,"value":10041},{"type":46,"tag":250,"props":27122,"children":27123},{"style":274},[27124],{"type":52,"value":27125}," dc",{"type":46,"tag":250,"props":27127,"children":27128},{"style":268},[27129],{"type":52,"value":106},{"type":46,"tag":250,"props":27131,"children":27132},{"style":274},[27133],{"type":52,"value":23286},{"type":46,"tag":250,"props":27135,"children":27136},{"class":252,"line":23152},[27137,27141,27146,27150,27154,27158,27162,27166,27171,27175],{"type":46,"tag":250,"props":27138,"children":27139},{"style":375},[27140],{"type":52,"value":9077},{"type":46,"tag":250,"props":27142,"children":27143},{"style":268},[27144],{"type":52,"value":27145}," daily_sessions ds ",{"type":46,"tag":250,"props":27147,"children":27148},{"style":375},[27149],{"type":52,"value":27103},{"type":46,"tag":250,"props":27151,"children":27152},{"style":274},[27153],{"type":52,"value":27108},{"type":46,"tag":250,"props":27155,"children":27156},{"style":268},[27157],{"type":52,"value":106},{"type":46,"tag":250,"props":27159,"children":27160},{"style":274},[27161],{"type":52,"value":19118},{"type":46,"tag":250,"props":27163,"children":27164},{"style":375},[27165],{"type":52,"value":10041},{"type":46,"tag":250,"props":27167,"children":27168},{"style":274},[27169],{"type":52,"value":27170}," ds",{"type":46,"tag":250,"props":27172,"children":27173},{"style":268},[27174],{"type":52,"value":106},{"type":46,"tag":250,"props":27176,"children":27177},{"style":274},[27178],{"type":52,"value":22630},{"type":46,"tag":250,"props":27180,"children":27181},{"class":252,"line":23165},[27182,27186,27191,27195,27199,27203,27207,27211,27216,27220],{"type":46,"tag":250,"props":27183,"children":27184},{"style":375},[27185],{"type":52,"value":9077},{"type":46,"tag":250,"props":27187,"children":27188},{"style":268},[27189],{"type":52,"value":27190}," daily_spend sp ",{"type":46,"tag":250,"props":27192,"children":27193},{"style":375},[27194],{"type":52,"value":27103},{"type":46,"tag":250,"props":27196,"children":27197},{"style":274},[27198],{"type":52,"value":27108},{"type":46,"tag":250,"props":27200,"children":27201},{"style":268},[27202],{"type":52,"value":106},{"type":46,"tag":250,"props":27204,"children":27205},{"style":274},[27206],{"type":52,"value":19118},{"type":46,"tag":250,"props":27208,"children":27209},{"style":375},[27210],{"type":52,"value":10041},{"type":46,"tag":250,"props":27212,"children":27213},{"style":274},[27214],{"type":52,"value":27215}," sp",{"type":46,"tag":250,"props":27217,"children":27218},{"style":268},[27219],{"type":52,"value":106},{"type":46,"tag":250,"props":27221,"children":27222},{"style":274},[27223],{"type":52,"value":27224},"spend_date\n",{"type":46,"tag":250,"props":27226,"children":27227},{"class":252,"line":23202},[27228,27232,27237],{"type":46,"tag":250,"props":27229,"children":27230},{"style":375},[27231],{"type":52,"value":17462},{"type":46,"tag":250,"props":27233,"children":27234},{"style":268},[27235],{"type":52,"value":27236}," kpi_date ",{"type":46,"tag":250,"props":27238,"children":27239},{"style":375},[27240],{"type":52,"value":27241},"DESC\n",{"type":46,"tag":429,"props":27243,"children":27244},{"v-slot:bigquery":7},[27245],{"type":46,"tag":240,"props":27246,"children":27248},{"className":9175,"code":27247,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_kpis\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - reports.rpt_daily_revenue\n  - staging.stg_customers\n  - staging.stg_orders\n  - staging.stg_web_sessions\n  - staging.stg_marketing_spend\ncolumns:\n  - name: kpi_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nWITH daily_customers AS (\n    SELECT\n        DATE(o.order_date) AS order_date,\n        COUNTIF(DATE(c.first_seen_at) = DATE(o.order_date)) AS new_customers,\n        COUNTIF(DATE(c.first_seen_at) \u003C DATE(o.order_date)) AS returning_customers\n    FROM staging.stg_orders o\n    LEFT JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n    GROUP BY DATE(o.order_date)\n),\ndaily_sessions AS (\n    SELECT\n        session_date,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_visitors,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date\n),\ndaily_spend AS (\n    SELECT\n        spend_date,\n        sum(spend) AS total_ad_spend\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date\n)\nSELECT\n    r.order_date AS kpi_date,\n    r.net_revenue,\n    r.total_orders,\n    r.paid_orders,\n    r.avg_order_value,\n    r.cancellation_rate,\n    dc.new_customers,\n    dc.returning_customers,\n    ds.sessions,\n    ds.new_visitors,\n    round(ds.purchases \u002F NULLIF(ds.sessions, 0) * 100, 2) AS conversion_rate,\n    sp.total_ad_spend,\n    round(r.net_revenue \u002F NULLIF(sp.total_ad_spend, 0), 2) AS overall_roas\nFROM reports.rpt_daily_revenue r\nLEFT JOIN daily_customers dc ON r.order_date = dc.order_date\nLEFT JOIN daily_sessions ds ON r.order_date = ds.session_date\nLEFT JOIN daily_spend sp ON r.order_date = sp.spend_date\nORDER BY kpi_date DESC\n",[27249],{"type":46,"tag":99,"props":27250,"children":27251},{"__ignoreMap":7},[27252,27259,27266,27273,27280,27287,27294,27301,27308,27315,27322,27329,27336,27343,27350,27357,27364,27371,27378,27385,27404,27411,27446,27514,27581,27604,27627,27662,27689,27720,27727,27742,27749,27756,27779,27798,27817,27836,27847,27854,27869,27876,27883,27902,27921,27932,27939,27946,27969,27988,28007,28026,28045,28064,28083,28102,28121,28140,28227,28246,28321,28344,28387,28430,28473],{"type":46,"tag":250,"props":27253,"children":27254},{"class":252,"line":23},[27255],{"type":46,"tag":250,"props":27256,"children":27257},{"style":9187},[27258],{"type":52,"value":9190},{"type":46,"tag":250,"props":27260,"children":27261},{"class":252,"line":285},[27262],{"type":46,"tag":250,"props":27263,"children":27264},{"style":9187},[27265],{"type":52,"value":26003},{"type":46,"tag":250,"props":27267,"children":27268},{"class":252,"line":299},[27269],{"type":46,"tag":250,"props":27270,"children":27271},{"style":9187},[27272],{"type":52,"value":9206},{"type":46,"tag":250,"props":27274,"children":27275},{"class":252,"line":807},[27276],{"type":46,"tag":250,"props":27277,"children":27278},{"style":9187},[27279],{"type":52,"value":9214},{"type":46,"tag":250,"props":27281,"children":27282},{"class":252,"line":820},[27283],{"type":46,"tag":250,"props":27284,"children":27285},{"style":9187},[27286],{"type":52,"value":9222},{"type":46,"tag":250,"props":27288,"children":27289},{"class":252,"line":844},[27290],{"type":46,"tag":250,"props":27291,"children":27292},{"style":9187},[27293],{"type":52,"value":9230},{"type":46,"tag":250,"props":27295,"children":27296},{"class":252,"line":862},[27297],{"type":46,"tag":250,"props":27298,"children":27299},{"style":9187},[27300],{"type":52,"value":26039},{"type":46,"tag":250,"props":27302,"children":27303},{"class":252,"line":11},[27304],{"type":46,"tag":250,"props":27305,"children":27306},{"style":9187},[27307],{"type":52,"value":18963},{"type":46,"tag":250,"props":27309,"children":27310},{"class":252,"line":4649},[27311],{"type":46,"tag":250,"props":27312,"children":27313},{"style":9187},[27314],{"type":52,"value":16980},{"type":46,"tag":250,"props":27316,"children":27317},{"class":252,"line":9257},[27318],{"type":46,"tag":250,"props":27319,"children":27320},{"style":9187},[27321],{"type":52,"value":22074},{"type":46,"tag":250,"props":27323,"children":27324},{"class":252,"line":9266},[27325],{"type":46,"tag":250,"props":27326,"children":27327},{"style":9187},[27328],{"type":52,"value":22066},{"type":46,"tag":250,"props":27330,"children":27331},{"class":252,"line":9275},[27332],{"type":46,"tag":250,"props":27333,"children":27334},{"style":9187},[27335],{"type":52,"value":9254},{"type":46,"tag":250,"props":27337,"children":27338},{"class":252,"line":9284},[27339],{"type":46,"tag":250,"props":27340,"children":27341},{"style":9187},[27342],{"type":52,"value":26082},{"type":46,"tag":250,"props":27344,"children":27345},{"class":252,"line":9293},[27346],{"type":46,"tag":250,"props":27347,"children":27348},{"style":9187},[27349],{"type":52,"value":13288},{"type":46,"tag":250,"props":27351,"children":27352},{"class":252,"line":4121},[27353],{"type":46,"tag":250,"props":27354,"children":27355},{"style":9187},[27356],{"type":52,"value":9281},{"type":46,"tag":250,"props":27358,"children":27359},{"class":252,"line":9310},[27360],{"type":46,"tag":250,"props":27361,"children":27362},{"style":9187},[27363],{"type":52,"value":9290},{"type":46,"tag":250,"props":27365,"children":27366},{"class":252,"line":9319},[27367],{"type":46,"tag":250,"props":27368,"children":27369},{"style":9187},[27370],{"type":52,"value":9299},{"type":46,"tag":250,"props":27372,"children":27373},{"class":252,"line":9327},[27374],{"type":46,"tag":250,"props":27375,"children":27376},{"style":9187},[27377],{"type":52,"value":9377},{"type":46,"tag":250,"props":27379,"children":27380},{"class":252,"line":9335},[27381],{"type":46,"tag":250,"props":27382,"children":27383},{"emptyLinePlaceholder":22},[27384],{"type":52,"value":9386},{"type":46,"tag":250,"props":27386,"children":27387},{"class":252,"line":9344},[27388,27392,27396,27400],{"type":46,"tag":250,"props":27389,"children":27390},{"style":375},[27391],{"type":52,"value":19021},{"type":46,"tag":250,"props":27393,"children":27394},{"style":268},[27395],{"type":52,"value":26136},{"type":46,"tag":250,"props":27397,"children":27398},{"style":375},[27399],{"type":52,"value":9608},{"type":46,"tag":250,"props":27401,"children":27402},{"style":268},[27403],{"type":52,"value":19035},{"type":46,"tag":250,"props":27405,"children":27406},{"class":252,"line":9353},[27407],{"type":46,"tag":250,"props":27408,"children":27409},{"style":375},[27410],{"type":52,"value":19043},{"type":46,"tag":250,"props":27412,"children":27413},{"class":252,"line":9362},[27414,27418,27422,27426,27430,27434,27438,27442],{"type":46,"tag":250,"props":27415,"children":27416},{"style":375},[27417],{"type":52,"value":23806},{"type":46,"tag":250,"props":27419,"children":27420},{"style":268},[27421],{"type":52,"value":9557},{"type":46,"tag":250,"props":27423,"children":27424},{"style":274},[27425],{"type":52,"value":9562},{"type":46,"tag":250,"props":27427,"children":27428},{"style":268},[27429],{"type":52,"value":106},{"type":46,"tag":250,"props":27431,"children":27432},{"style":274},[27433],{"type":52,"value":19118},{"type":46,"tag":250,"props":27435,"children":27436},{"style":268},[27437],{"type":52,"value":10086},{"type":46,"tag":250,"props":27439,"children":27440},{"style":375},[27441],{"type":52,"value":9608},{"type":46,"tag":250,"props":27443,"children":27444},{"style":268},[27445],{"type":52,"value":9497},{"type":46,"tag":250,"props":27447,"children":27448},{"class":252,"line":9371},[27449,27454,27458,27462,27466,27470,27474,27478,27482,27486,27490,27494,27498,27502,27506,27510],{"type":46,"tag":250,"props":27450,"children":27451},{"style":268},[27452],{"type":52,"value":27453},"        COUNTIF(",{"type":46,"tag":250,"props":27455,"children":27456},{"style":375},[27457],{"type":52,"value":11882},{"type":46,"tag":250,"props":27459,"children":27460},{"style":268},[27461],{"type":52,"value":9557},{"type":46,"tag":250,"props":27463,"children":27464},{"style":274},[27465],{"type":52,"value":10100},{"type":46,"tag":250,"props":27467,"children":27468},{"style":268},[27469],{"type":52,"value":106},{"type":46,"tag":250,"props":27471,"children":27472},{"style":274},[27473],{"type":52,"value":19085},{"type":46,"tag":250,"props":27475,"children":27476},{"style":268},[27477],{"type":52,"value":10086},{"type":46,"tag":250,"props":27479,"children":27480},{"style":375},[27481],{"type":52,"value":10091},{"type":46,"tag":250,"props":27483,"children":27484},{"style":375},[27485],{"type":52,"value":10885},{"type":46,"tag":250,"props":27487,"children":27488},{"style":268},[27489],{"type":52,"value":9557},{"type":46,"tag":250,"props":27491,"children":27492},{"style":274},[27493],{"type":52,"value":9562},{"type":46,"tag":250,"props":27495,"children":27496},{"style":268},[27497],{"type":52,"value":106},{"type":46,"tag":250,"props":27499,"children":27500},{"style":274},[27501],{"type":52,"value":19118},{"type":46,"tag":250,"props":27503,"children":27504},{"style":268},[27505],{"type":52,"value":9603},{"type":46,"tag":250,"props":27507,"children":27508},{"style":375},[27509],{"type":52,"value":9608},{"type":46,"tag":250,"props":27511,"children":27512},{"style":268},[27513],{"type":52,"value":26240},{"type":46,"tag":250,"props":27515,"children":27516},{"class":252,"line":9380},[27517,27521,27525,27529,27533,27537,27541,27545,27549,27553,27557,27561,27565,27569,27573,27577],{"type":46,"tag":250,"props":27518,"children":27519},{"style":268},[27520],{"type":52,"value":27453},{"type":46,"tag":250,"props":27522,"children":27523},{"style":375},[27524],{"type":52,"value":11882},{"type":46,"tag":250,"props":27526,"children":27527},{"style":268},[27528],{"type":52,"value":9557},{"type":46,"tag":250,"props":27530,"children":27531},{"style":274},[27532],{"type":52,"value":10100},{"type":46,"tag":250,"props":27534,"children":27535},{"style":268},[27536],{"type":52,"value":106},{"type":46,"tag":250,"props":27538,"children":27539},{"style":274},[27540],{"type":52,"value":19085},{"type":46,"tag":250,"props":27542,"children":27543},{"style":268},[27544],{"type":52,"value":10086},{"type":46,"tag":250,"props":27546,"children":27547},{"style":375},[27548],{"type":52,"value":26268},{"type":46,"tag":250,"props":27550,"children":27551},{"style":375},[27552],{"type":52,"value":10885},{"type":46,"tag":250,"props":27554,"children":27555},{"style":268},[27556],{"type":52,"value":9557},{"type":46,"tag":250,"props":27558,"children":27559},{"style":274},[27560],{"type":52,"value":9562},{"type":46,"tag":250,"props":27562,"children":27563},{"style":268},[27564],{"type":52,"value":106},{"type":46,"tag":250,"props":27566,"children":27567},{"style":274},[27568],{"type":52,"value":19118},{"type":46,"tag":250,"props":27570,"children":27571},{"style":268},[27572],{"type":52,"value":9603},{"type":46,"tag":250,"props":27574,"children":27575},{"style":375},[27576],{"type":52,"value":9608},{"type":46,"tag":250,"props":27578,"children":27579},{"style":268},[27580],{"type":52,"value":26297},{"type":46,"tag":250,"props":27582,"children":27583},{"class":252,"line":9389},[27584,27588,27592,27596,27600],{"type":46,"tag":250,"props":27585,"children":27586},{"style":375},[27587],{"type":52,"value":19155},{"type":46,"tag":250,"props":27589,"children":27590},{"style":274},[27591],{"type":52,"value":17433},{"type":46,"tag":250,"props":27593,"children":27594},{"style":268},[27595],{"type":52,"value":106},{"type":46,"tag":250,"props":27597,"children":27598},{"style":274},[27599],{"type":52,"value":18055},{"type":46,"tag":250,"props":27601,"children":27602},{"style":268},[27603],{"type":52,"value":9988},{"type":46,"tag":250,"props":27605,"children":27606},{"class":252,"line":9398},[27607,27611,27615,27619,27623],{"type":46,"tag":250,"props":27608,"children":27609},{"style":375},[27610],{"type":52,"value":26328},{"type":46,"tag":250,"props":27612,"children":27613},{"style":274},[27614],{"type":52,"value":17433},{"type":46,"tag":250,"props":27616,"children":27617},{"style":268},[27618],{"type":52,"value":106},{"type":46,"tag":250,"props":27620,"children":27621},{"style":274},[27622],{"type":52,"value":19192},{"type":46,"tag":250,"props":27624,"children":27625},{"style":268},[27626],{"type":52,"value":10014},{"type":46,"tag":250,"props":27628,"children":27629},{"class":252,"line":9426},[27630,27634,27638,27642,27646,27650,27654,27658],{"type":46,"tag":250,"props":27631,"children":27632},{"style":375},[27633],{"type":52,"value":19204},{"type":46,"tag":250,"props":27635,"children":27636},{"style":274},[27637],{"type":52,"value":10028},{"type":46,"tag":250,"props":27639,"children":27640},{"style":268},[27641],{"type":52,"value":106},{"type":46,"tag":250,"props":27643,"children":27644},{"style":274},[27645],{"type":52,"value":19060},{"type":46,"tag":250,"props":27647,"children":27648},{"style":375},[27649],{"type":52,"value":10041},{"type":46,"tag":250,"props":27651,"children":27652},{"style":274},[27653],{"type":52,"value":10046},{"type":46,"tag":250,"props":27655,"children":27656},{"style":268},[27657],{"type":52,"value":106},{"type":46,"tag":250,"props":27659,"children":27660},{"style":274},[27661],{"type":52,"value":19233},{"type":46,"tag":250,"props":27663,"children":27664},{"class":252,"line":9448},[27665,27669,27673,27677,27681,27685],{"type":46,"tag":250,"props":27666,"children":27667},{"style":375},[27668],{"type":52,"value":19241},{"type":46,"tag":250,"props":27670,"children":27671},{"style":274},[27672],{"type":52,"value":10028},{"type":46,"tag":250,"props":27674,"children":27675},{"style":268},[27676],{"type":52,"value":106},{"type":46,"tag":250,"props":27678,"children":27679},{"style":274},[27680],{"type":52,"value":19254},{"type":46,"tag":250,"props":27682,"children":27683},{"style":375},[27684],{"type":52,"value":10041},{"type":46,"tag":250,"props":27686,"children":27687},{"style":262},[27688],{"type":52,"value":19263},{"type":46,"tag":250,"props":27690,"children":27691},{"class":252,"line":9474},[27692,27696,27700,27704,27708,27712,27716],{"type":46,"tag":250,"props":27693,"children":27694},{"style":375},[27695],{"type":52,"value":19353},{"type":46,"tag":250,"props":27697,"children":27698},{"style":375},[27699],{"type":52,"value":10885},{"type":46,"tag":250,"props":27701,"children":27702},{"style":268},[27703],{"type":52,"value":9557},{"type":46,"tag":250,"props":27705,"children":27706},{"style":274},[27707],{"type":52,"value":9562},{"type":46,"tag":250,"props":27709,"children":27710},{"style":268},[27711],{"type":52,"value":106},{"type":46,"tag":250,"props":27713,"children":27714},{"style":274},[27715],{"type":52,"value":19118},{"type":46,"tag":250,"props":27717,"children":27718},{"style":268},[27719],{"type":52,"value":10114},{"type":46,"tag":250,"props":27721,"children":27722},{"class":252,"line":9500},[27723],{"type":46,"tag":250,"props":27724,"children":27725},{"style":268},[27726],{"type":52,"value":19271},{"type":46,"tag":250,"props":27728,"children":27729},{"class":252,"line":9525},[27730,27734,27738],{"type":46,"tag":250,"props":27731,"children":27732},{"style":268},[27733],{"type":52,"value":26448},{"type":46,"tag":250,"props":27735,"children":27736},{"style":375},[27737],{"type":52,"value":9608},{"type":46,"tag":250,"props":27739,"children":27740},{"style":268},[27741],{"type":52,"value":19035},{"type":46,"tag":250,"props":27743,"children":27744},{"class":252,"line":9546},[27745],{"type":46,"tag":250,"props":27746,"children":27747},{"style":375},[27748],{"type":52,"value":19043},{"type":46,"tag":250,"props":27750,"children":27751},{"class":252,"line":9616},[27752],{"type":46,"tag":250,"props":27753,"children":27754},{"style":268},[27755],{"type":52,"value":22329},{"type":46,"tag":250,"props":27757,"children":27758},{"class":252,"line":9678},[27759,27763,27767,27771,27775],{"type":46,"tag":250,"props":27760,"children":27761},{"style":274},[27762],{"type":52,"value":22182},{"type":46,"tag":250,"props":27764,"children":27765},{"style":268},[27766],{"type":52,"value":22348},{"type":46,"tag":250,"props":27768,"children":27769},{"style":375},[27770],{"type":52,"value":9608},{"type":46,"tag":250,"props":27772,"children":27773},{"style":375},[27774],{"type":52,"value":22357},{"type":46,"tag":250,"props":27776,"children":27777},{"style":268},[27778],{"type":52,"value":9445},{"type":46,"tag":250,"props":27780,"children":27781},{"class":252,"line":9740},[27782,27786,27790,27794],{"type":46,"tag":250,"props":27783,"children":27784},{"style":274},[27785],{"type":52,"value":22182},{"type":46,"tag":250,"props":27787,"children":27788},{"style":268},[27789],{"type":52,"value":22373},{"type":46,"tag":250,"props":27791,"children":27792},{"style":375},[27793],{"type":52,"value":9608},{"type":46,"tag":250,"props":27795,"children":27796},{"style":268},[27797],{"type":52,"value":26513},{"type":46,"tag":250,"props":27799,"children":27800},{"class":252,"line":9802},[27801,27805,27809,27813],{"type":46,"tag":250,"props":27802,"children":27803},{"style":274},[27804],{"type":52,"value":22182},{"type":46,"tag":250,"props":27806,"children":27807},{"style":268},[27808],{"type":52,"value":22393},{"type":46,"tag":250,"props":27810,"children":27811},{"style":375},[27812],{"type":52,"value":9608},{"type":46,"tag":250,"props":27814,"children":27815},{"style":268},[27816],{"type":52,"value":22402},{"type":46,"tag":250,"props":27818,"children":27819},{"class":252,"line":9823},[27820,27824,27828,27832],{"type":46,"tag":250,"props":27821,"children":27822},{"style":375},[27823],{"type":52,"value":19155},{"type":46,"tag":250,"props":27825,"children":27826},{"style":274},[27827],{"type":52,"value":17433},{"type":46,"tag":250,"props":27829,"children":27830},{"style":268},[27831],{"type":52,"value":106},{"type":46,"tag":250,"props":27833,"children":27834},{"style":274},[27835],{"type":52,"value":22422},{"type":46,"tag":250,"props":27837,"children":27838},{"class":252,"line":9844},[27839,27843],{"type":46,"tag":250,"props":27840,"children":27841},{"style":375},[27842],{"type":52,"value":19353},{"type":46,"tag":250,"props":27844,"children":27845},{"style":268},[27846],{"type":52,"value":26563},{"type":46,"tag":250,"props":27848,"children":27849},{"class":252,"line":9865},[27850],{"type":46,"tag":250,"props":27851,"children":27852},{"style":268},[27853],{"type":52,"value":19271},{"type":46,"tag":250,"props":27855,"children":27856},{"class":252,"line":9911},[27857,27861,27865],{"type":46,"tag":250,"props":27858,"children":27859},{"style":268},[27860],{"type":52,"value":26578},{"type":46,"tag":250,"props":27862,"children":27863},{"style":375},[27864],{"type":52,"value":9608},{"type":46,"tag":250,"props":27866,"children":27867},{"style":268},[27868],{"type":52,"value":19035},{"type":46,"tag":250,"props":27870,"children":27871},{"class":252,"line":9937},[27872],{"type":46,"tag":250,"props":27873,"children":27874},{"style":375},[27875],{"type":52,"value":19043},{"type":46,"tag":250,"props":27877,"children":27878},{"class":252,"line":9963},[27879],{"type":46,"tag":250,"props":27880,"children":27881},{"style":268},[27882],{"type":52,"value":22166},{"type":46,"tag":250,"props":27884,"children":27885},{"class":252,"line":9991},[27886,27890,27894,27898],{"type":46,"tag":250,"props":27887,"children":27888},{"style":274},[27889],{"type":52,"value":22182},{"type":46,"tag":250,"props":27891,"children":27892},{"style":268},[27893],{"type":52,"value":22187},{"type":46,"tag":250,"props":27895,"children":27896},{"style":375},[27897],{"type":52,"value":9608},{"type":46,"tag":250,"props":27899,"children":27900},{"style":268},[27901],{"type":52,"value":26620},{"type":46,"tag":250,"props":27903,"children":27904},{"class":252,"line":10017},[27905,27909,27913,27917],{"type":46,"tag":250,"props":27906,"children":27907},{"style":375},[27908],{"type":52,"value":19155},{"type":46,"tag":250,"props":27910,"children":27911},{"style":274},[27912],{"type":52,"value":17433},{"type":46,"tag":250,"props":27914,"children":27915},{"style":268},[27916],{"type":52,"value":106},{"type":46,"tag":250,"props":27918,"children":27919},{"style":274},[27920],{"type":52,"value":22279},{"type":46,"tag":250,"props":27922,"children":27923},{"class":252,"line":10058},[27924,27928],{"type":46,"tag":250,"props":27925,"children":27926},{"style":375},[27927],{"type":52,"value":19353},{"type":46,"tag":250,"props":27929,"children":27930},{"style":268},[27931],{"type":52,"value":26651},{"type":46,"tag":250,"props":27933,"children":27934},{"class":252,"line":10936},[27935],{"type":46,"tag":250,"props":27936,"children":27937},{"style":268},[27938],{"type":52,"value":10114},{"type":46,"tag":250,"props":27940,"children":27941},{"class":252,"line":10995},[27942],{"type":46,"tag":250,"props":27943,"children":27944},{"style":375},[27945],{"type":52,"value":9395},{"type":46,"tag":250,"props":27947,"children":27948},{"class":252,"line":22686},[27949,27953,27957,27961,27965],{"type":46,"tag":250,"props":27950,"children":27951},{"style":274},[27952],{"type":52,"value":26673},{"type":46,"tag":250,"props":27954,"children":27955},{"style":268},[27956],{"type":52,"value":106},{"type":46,"tag":250,"props":27958,"children":27959},{"style":274},[27960],{"type":52,"value":19118},{"type":46,"tag":250,"props":27962,"children":27963},{"style":375},[27964],{"type":52,"value":9418},{"type":46,"tag":250,"props":27966,"children":27967},{"style":268},[27968],{"type":52,"value":26690},{"type":46,"tag":250,"props":27970,"children":27971},{"class":252,"line":22694},[27972,27976,27980,27984],{"type":46,"tag":250,"props":27973,"children":27974},{"style":274},[27975],{"type":52,"value":26673},{"type":46,"tag":250,"props":27977,"children":27978},{"style":268},[27979],{"type":52,"value":106},{"type":46,"tag":250,"props":27981,"children":27982},{"style":274},[27983],{"type":52,"value":26706},{"type":46,"tag":250,"props":27985,"children":27986},{"style":268},[27987],{"type":52,"value":9445},{"type":46,"tag":250,"props":27989,"children":27990},{"class":252,"line":22702},[27991,27995,27999,28003],{"type":46,"tag":250,"props":27992,"children":27993},{"style":274},[27994],{"type":52,"value":26673},{"type":46,"tag":250,"props":27996,"children":27997},{"style":268},[27998],{"type":52,"value":106},{"type":46,"tag":250,"props":28000,"children":28001},{"style":274},[28002],{"type":52,"value":26726},{"type":46,"tag":250,"props":28004,"children":28005},{"style":268},[28006],{"type":52,"value":9445},{"type":46,"tag":250,"props":28008,"children":28009},{"class":252,"line":22728},[28010,28014,28018,28022],{"type":46,"tag":250,"props":28011,"children":28012},{"style":274},[28013],{"type":52,"value":26673},{"type":46,"tag":250,"props":28015,"children":28016},{"style":268},[28017],{"type":52,"value":106},{"type":46,"tag":250,"props":28019,"children":28020},{"style":274},[28021],{"type":52,"value":26746},{"type":46,"tag":250,"props":28023,"children":28024},{"style":268},[28025],{"type":52,"value":9445},{"type":46,"tag":250,"props":28027,"children":28028},{"class":252,"line":22748},[28029,28033,28037,28041],{"type":46,"tag":250,"props":28030,"children":28031},{"style":274},[28032],{"type":52,"value":26673},{"type":46,"tag":250,"props":28034,"children":28035},{"style":268},[28036],{"type":52,"value":106},{"type":46,"tag":250,"props":28038,"children":28039},{"style":274},[28040],{"type":52,"value":26766},{"type":46,"tag":250,"props":28042,"children":28043},{"style":268},[28044],{"type":52,"value":9445},{"type":46,"tag":250,"props":28046,"children":28047},{"class":252,"line":22769},[28048,28052,28056,28060],{"type":46,"tag":250,"props":28049,"children":28050},{"style":274},[28051],{"type":52,"value":26673},{"type":46,"tag":250,"props":28053,"children":28054},{"style":268},[28055],{"type":52,"value":106},{"type":46,"tag":250,"props":28057,"children":28058},{"style":274},[28059],{"type":52,"value":26786},{"type":46,"tag":250,"props":28061,"children":28062},{"style":268},[28063],{"type":52,"value":9445},{"type":46,"tag":250,"props":28065,"children":28066},{"class":252,"line":22790},[28067,28071,28075,28079],{"type":46,"tag":250,"props":28068,"children":28069},{"style":274},[28070],{"type":52,"value":26798},{"type":46,"tag":250,"props":28072,"children":28073},{"style":268},[28074],{"type":52,"value":106},{"type":46,"tag":250,"props":28076,"children":28077},{"style":274},[28078],{"type":52,"value":26807},{"type":46,"tag":250,"props":28080,"children":28081},{"style":268},[28082],{"type":52,"value":9445},{"type":46,"tag":250,"props":28084,"children":28085},{"class":252,"line":22811},[28086,28090,28094,28098],{"type":46,"tag":250,"props":28087,"children":28088},{"style":274},[28089],{"type":52,"value":26798},{"type":46,"tag":250,"props":28091,"children":28092},{"style":268},[28093],{"type":52,"value":106},{"type":46,"tag":250,"props":28095,"children":28096},{"style":274},[28097],{"type":52,"value":26827},{"type":46,"tag":250,"props":28099,"children":28100},{"style":268},[28101],{"type":52,"value":9445},{"type":46,"tag":250,"props":28103,"children":28104},{"class":252,"line":22832},[28105,28109,28113,28117],{"type":46,"tag":250,"props":28106,"children":28107},{"style":274},[28108],{"type":52,"value":26839},{"type":46,"tag":250,"props":28110,"children":28111},{"style":268},[28112],{"type":52,"value":106},{"type":46,"tag":250,"props":28114,"children":28115},{"style":274},[28116],{"type":52,"value":15030},{"type":46,"tag":250,"props":28118,"children":28119},{"style":268},[28120],{"type":52,"value":9445},{"type":46,"tag":250,"props":28122,"children":28123},{"class":252,"line":22853},[28124,28128,28132,28136],{"type":46,"tag":250,"props":28125,"children":28126},{"style":274},[28127],{"type":52,"value":26839},{"type":46,"tag":250,"props":28129,"children":28130},{"style":268},[28131],{"type":52,"value":106},{"type":46,"tag":250,"props":28133,"children":28134},{"style":274},[28135],{"type":52,"value":26867},{"type":46,"tag":250,"props":28137,"children":28138},{"style":268},[28139],{"type":52,"value":9445},{"type":46,"tag":250,"props":28141,"children":28142},{"class":252,"line":22873},[28143,28147,28151,28155,28159,28163,28167,28171,28175,28179,28183,28187,28191,28195,28199,28203,28207,28211,28215,28219,28223],{"type":46,"tag":250,"props":28144,"children":28145},{"style":274},[28146],{"type":52,"value":17313},{"type":46,"tag":250,"props":28148,"children":28149},{"style":268},[28150],{"type":52,"value":9557},{"type":46,"tag":250,"props":28152,"children":28153},{"style":274},[28154],{"type":52,"value":26887},{"type":46,"tag":250,"props":28156,"children":28157},{"style":268},[28158],{"type":52,"value":106},{"type":46,"tag":250,"props":28160,"children":28161},{"style":274},[28162],{"type":52,"value":26896},{"type":46,"tag":250,"props":28164,"children":28165},{"style":375},[28166],{"type":52,"value":9885},{"type":46,"tag":250,"props":28168,"children":28169},{"style":274},[28170],{"type":52,"value":17909},{"type":46,"tag":250,"props":28172,"children":28173},{"style":268},[28174],{"type":52,"value":9557},{"type":46,"tag":250,"props":28176,"children":28177},{"style":274},[28178],{"type":52,"value":26887},{"type":46,"tag":250,"props":28180,"children":28181},{"style":268},[28182],{"type":52,"value":106},{"type":46,"tag":250,"props":28184,"children":28185},{"style":274},[28186],{"type":52,"value":15030},{"type":46,"tag":250,"props":28188,"children":28189},{"style":268},[28190],{"type":52,"value":151},{"type":46,"tag":250,"props":28192,"children":28193},{"style":274},[28194],{"type":52,"value":9899},{"type":46,"tag":250,"props":28196,"children":28197},{"style":268},[28198],{"type":52,"value":10086},{"type":46,"tag":250,"props":28200,"children":28201},{"style":375},[28202],{"type":52,"value":15522},{"type":46,"tag":250,"props":28204,"children":28205},{"style":274},[28206],{"type":52,"value":9890},{"type":46,"tag":250,"props":28208,"children":28209},{"style":268},[28210],{"type":52,"value":151},{"type":46,"tag":250,"props":28212,"children":28213},{"style":274},[28214],{"type":52,"value":9598},{"type":46,"tag":250,"props":28216,"children":28217},{"style":268},[28218],{"type":52,"value":10086},{"type":46,"tag":250,"props":28220,"children":28221},{"style":375},[28222],{"type":52,"value":9608},{"type":46,"tag":250,"props":28224,"children":28225},{"style":268},[28226],{"type":52,"value":26961},{"type":46,"tag":250,"props":28228,"children":28229},{"class":252,"line":22895},[28230,28234,28238,28242],{"type":46,"tag":250,"props":28231,"children":28232},{"style":274},[28233],{"type":52,"value":26969},{"type":46,"tag":250,"props":28235,"children":28236},{"style":268},[28237],{"type":52,"value":106},{"type":46,"tag":250,"props":28239,"children":28240},{"style":274},[28241],{"type":52,"value":26978},{"type":46,"tag":250,"props":28243,"children":28244},{"style":268},[28245],{"type":52,"value":9445},{"type":46,"tag":250,"props":28247,"children":28248},{"class":252,"line":22973},[28249,28253,28257,28261,28265,28269,28273,28277,28281,28285,28289,28293,28297,28301,28305,28309,28313,28317],{"type":46,"tag":250,"props":28250,"children":28251},{"style":274},[28252],{"type":52,"value":17313},{"type":46,"tag":250,"props":28254,"children":28255},{"style":268},[28256],{"type":52,"value":9557},{"type":46,"tag":250,"props":28258,"children":28259},{"style":274},[28260],{"type":52,"value":26998},{"type":46,"tag":250,"props":28262,"children":28263},{"style":268},[28264],{"type":52,"value":106},{"type":46,"tag":250,"props":28266,"children":28267},{"style":274},[28268],{"type":52,"value":26706},{"type":46,"tag":250,"props":28270,"children":28271},{"style":375},[28272],{"type":52,"value":9885},{"type":46,"tag":250,"props":28274,"children":28275},{"style":274},[28276],{"type":52,"value":17909},{"type":46,"tag":250,"props":28278,"children":28279},{"style":268},[28280],{"type":52,"value":9557},{"type":46,"tag":250,"props":28282,"children":28283},{"style":274},[28284],{"type":52,"value":27023},{"type":46,"tag":250,"props":28286,"children":28287},{"style":268},[28288],{"type":52,"value":106},{"type":46,"tag":250,"props":28290,"children":28291},{"style":274},[28292],{"type":52,"value":26978},{"type":46,"tag":250,"props":28294,"children":28295},{"style":268},[28296],{"type":52,"value":151},{"type":46,"tag":250,"props":28298,"children":28299},{"style":274},[28300],{"type":52,"value":9899},{"type":46,"tag":250,"props":28302,"children":28303},{"style":268},[28304],{"type":52,"value":17342},{"type":46,"tag":250,"props":28306,"children":28307},{"style":274},[28308],{"type":52,"value":9598},{"type":46,"tag":250,"props":28310,"children":28311},{"style":268},[28312],{"type":52,"value":10086},{"type":46,"tag":250,"props":28314,"children":28315},{"style":375},[28316],{"type":52,"value":9608},{"type":46,"tag":250,"props":28318,"children":28319},{"style":268},[28320],{"type":52,"value":27060},{"type":46,"tag":250,"props":28322,"children":28323},{"class":252,"line":23050},[28324,28328,28332,28336,28340],{"type":46,"tag":250,"props":28325,"children":28326},{"style":375},[28327],{"type":52,"value":9969},{"type":46,"tag":250,"props":28329,"children":28330},{"style":274},[28331],{"type":52,"value":27072},{"type":46,"tag":250,"props":28333,"children":28334},{"style":268},[28335],{"type":52,"value":106},{"type":46,"tag":250,"props":28337,"children":28338},{"style":274},[28339],{"type":52,"value":27081},{"type":46,"tag":250,"props":28341,"children":28342},{"style":268},[28343],{"type":52,"value":27086},{"type":46,"tag":250,"props":28345,"children":28346},{"class":252,"line":23139},[28347,28351,28355,28359,28363,28367,28371,28375,28379,28383],{"type":46,"tag":250,"props":28348,"children":28349},{"style":375},[28350],{"type":52,"value":9077},{"type":46,"tag":250,"props":28352,"children":28353},{"style":268},[28354],{"type":52,"value":27098},{"type":46,"tag":250,"props":28356,"children":28357},{"style":375},[28358],{"type":52,"value":27103},{"type":46,"tag":250,"props":28360,"children":28361},{"style":274},[28362],{"type":52,"value":27108},{"type":46,"tag":250,"props":28364,"children":28365},{"style":268},[28366],{"type":52,"value":106},{"type":46,"tag":250,"props":28368,"children":28369},{"style":274},[28370],{"type":52,"value":19118},{"type":46,"tag":250,"props":28372,"children":28373},{"style":375},[28374],{"type":52,"value":10041},{"type":46,"tag":250,"props":28376,"children":28377},{"style":274},[28378],{"type":52,"value":27125},{"type":46,"tag":250,"props":28380,"children":28381},{"style":268},[28382],{"type":52,"value":106},{"type":46,"tag":250,"props":28384,"children":28385},{"style":274},[28386],{"type":52,"value":23286},{"type":46,"tag":250,"props":28388,"children":28389},{"class":252,"line":23152},[28390,28394,28398,28402,28406,28410,28414,28418,28422,28426],{"type":46,"tag":250,"props":28391,"children":28392},{"style":375},[28393],{"type":52,"value":9077},{"type":46,"tag":250,"props":28395,"children":28396},{"style":268},[28397],{"type":52,"value":27145},{"type":46,"tag":250,"props":28399,"children":28400},{"style":375},[28401],{"type":52,"value":27103},{"type":46,"tag":250,"props":28403,"children":28404},{"style":274},[28405],{"type":52,"value":27108},{"type":46,"tag":250,"props":28407,"children":28408},{"style":268},[28409],{"type":52,"value":106},{"type":46,"tag":250,"props":28411,"children":28412},{"style":274},[28413],{"type":52,"value":19118},{"type":46,"tag":250,"props":28415,"children":28416},{"style":375},[28417],{"type":52,"value":10041},{"type":46,"tag":250,"props":28419,"children":28420},{"style":274},[28421],{"type":52,"value":27170},{"type":46,"tag":250,"props":28423,"children":28424},{"style":268},[28425],{"type":52,"value":106},{"type":46,"tag":250,"props":28427,"children":28428},{"style":274},[28429],{"type":52,"value":22630},{"type":46,"tag":250,"props":28431,"children":28432},{"class":252,"line":23165},[28433,28437,28441,28445,28449,28453,28457,28461,28465,28469],{"type":46,"tag":250,"props":28434,"children":28435},{"style":375},[28436],{"type":52,"value":9077},{"type":46,"tag":250,"props":28438,"children":28439},{"style":268},[28440],{"type":52,"value":27190},{"type":46,"tag":250,"props":28442,"children":28443},{"style":375},[28444],{"type":52,"value":27103},{"type":46,"tag":250,"props":28446,"children":28447},{"style":274},[28448],{"type":52,"value":27108},{"type":46,"tag":250,"props":28450,"children":28451},{"style":268},[28452],{"type":52,"value":106},{"type":46,"tag":250,"props":28454,"children":28455},{"style":274},[28456],{"type":52,"value":19118},{"type":46,"tag":250,"props":28458,"children":28459},{"style":375},[28460],{"type":52,"value":10041},{"type":46,"tag":250,"props":28462,"children":28463},{"style":274},[28464],{"type":52,"value":27215},{"type":46,"tag":250,"props":28466,"children":28467},{"style":268},[28468],{"type":52,"value":106},{"type":46,"tag":250,"props":28470,"children":28471},{"style":274},[28472],{"type":52,"value":27224},{"type":46,"tag":250,"props":28474,"children":28475},{"class":252,"line":23202},[28476,28480,28484],{"type":46,"tag":250,"props":28477,"children":28478},{"style":375},[28479],{"type":52,"value":17462},{"type":46,"tag":250,"props":28481,"children":28482},{"style":268},[28483],{"type":52,"value":27236},{"type":46,"tag":250,"props":28485,"children":28486},{"style":375},[28487],{"type":52,"value":27241},{"type":46,"tag":429,"props":28489,"children":28490},{"v-slot:snowflake":7},[28491],{"type":46,"tag":240,"props":28492,"children":28494},{"className":9175,"code":28493,"language":9177,"meta":7,"style":7},"\u002F* @bruin\nname: reports.rpt_daily_kpis\ntype: sql\nmaterialization:\n  type: table\ndepends:\n  - reports.rpt_daily_revenue\n  - staging.stg_customers\n  - staging.stg_orders\n  - staging.stg_web_sessions\n  - staging.stg_marketing_spend\ncolumns:\n  - name: kpi_date\n    type: date\n    checks:\n      - name: not_null\n      - name: unique\n@bruin *\u002F\n\nWITH daily_customers AS (\n    SELECT\n        o.order_date::DATE AS order_date,\n        COUNT(CASE WHEN c.first_seen_at::DATE = o.order_date::DATE THEN 1 END) AS new_customers,\n        COUNT(CASE WHEN c.first_seen_at::DATE \u003C o.order_date::DATE THEN 1 END) AS returning_customers\n    FROM staging.stg_orders o\n    LEFT JOIN staging.stg_customers c\n        ON o.customer_email = c.customer_email\n    WHERE o.payment_status = 'paid'\n    GROUP BY o.order_date::DATE\n),\ndaily_sessions AS (\n    SELECT\n        session_date,\n        sum(total_sessions) AS sessions,\n        sum(new_users) AS new_visitors,\n        sum(purchase_events) AS purchases\n    FROM staging.stg_web_sessions\n    GROUP BY session_date\n),\ndaily_spend AS (\n    SELECT\n        spend_date,\n        sum(spend) AS total_ad_spend\n    FROM staging.stg_marketing_spend\n    GROUP BY spend_date\n)\nSELECT\n    r.order_date AS kpi_date,\n    r.net_revenue,\n    r.total_orders,\n    r.paid_orders,\n    r.avg_order_value,\n    r.cancellation_rate,\n    dc.new_customers,\n    dc.returning_customers,\n    ds.sessions,\n    ds.new_visitors,\n    round(ds.purchases \u002F NULLIF(ds.sessions, 0) * 100, 2) AS conversion_rate,\n    sp.total_ad_spend,\n    round(r.net_revenue \u002F NULLIF(sp.total_ad_spend, 0), 2) AS overall_roas\nFROM reports.rpt_daily_revenue r\nLEFT JOIN daily_customers dc ON r.order_date = dc.order_date\nLEFT JOIN daily_sessions ds ON r.order_date = ds.session_date\nLEFT JOIN daily_spend sp ON r.order_date = sp.spend_date\nORDER BY kpi_date DESC\n",[28495],{"type":46,"tag":99,"props":28496,"children":28497},{"__ignoreMap":7},[28498,28505,28512,28519,28526,28533,28540,28547,28554,28561,28568,28575,28582,28589,28596,28603,28610,28617,28624,28631,28650,28657,28688,28776,28864,28887,28910,28945,28972,28999,29006,29021,29028,29035,29058,29077,29096,29115,29126,29133,29148,29155,29162,29181,29200,29211,29218,29225,29248,29267,29286,29305,29324,29343,29362,29381,29400,29419,29506,29525,29600,29623,29666,29709,29752],{"type":46,"tag":250,"props":28499,"children":28500},{"class":252,"line":23},[28501],{"type":46,"tag":250,"props":28502,"children":28503},{"style":9187},[28504],{"type":52,"value":9190},{"type":46,"tag":250,"props":28506,"children":28507},{"class":252,"line":285},[28508],{"type":46,"tag":250,"props":28509,"children":28510},{"style":9187},[28511],{"type":52,"value":26003},{"type":46,"tag":250,"props":28513,"children":28514},{"class":252,"line":299},[28515],{"type":46,"tag":250,"props":28516,"children":28517},{"style":9187},[28518],{"type":52,"value":9206},{"type":46,"tag":250,"props":28520,"children":28521},{"class":252,"line":807},[28522],{"type":46,"tag":250,"props":28523,"children":28524},{"style":9187},[28525],{"type":52,"value":9214},{"type":46,"tag":250,"props":28527,"children":28528},{"class":252,"line":820},[28529],{"type":46,"tag":250,"props":28530,"children":28531},{"style":9187},[28532],{"type":52,"value":9222},{"type":46,"tag":250,"props":28534,"children":28535},{"class":252,"line":844},[28536],{"type":46,"tag":250,"props":28537,"children":28538},{"style":9187},[28539],{"type":52,"value":9230},{"type":46,"tag":250,"props":28541,"children":28542},{"class":252,"line":862},[28543],{"type":46,"tag":250,"props":28544,"children":28545},{"style":9187},[28546],{"type":52,"value":26039},{"type":46,"tag":250,"props":28548,"children":28549},{"class":252,"line":11},[28550],{"type":46,"tag":250,"props":28551,"children":28552},{"style":9187},[28553],{"type":52,"value":18963},{"type":46,"tag":250,"props":28555,"children":28556},{"class":252,"line":4649},[28557],{"type":46,"tag":250,"props":28558,"children":28559},{"style":9187},[28560],{"type":52,"value":16980},{"type":46,"tag":250,"props":28562,"children":28563},{"class":252,"line":9257},[28564],{"type":46,"tag":250,"props":28565,"children":28566},{"style":9187},[28567],{"type":52,"value":22074},{"type":46,"tag":250,"props":28569,"children":28570},{"class":252,"line":9266},[28571],{"type":46,"tag":250,"props":28572,"children":28573},{"style":9187},[28574],{"type":52,"value":22066},{"type":46,"tag":250,"props":28576,"children":28577},{"class":252,"line":9275},[28578],{"type":46,"tag":250,"props":28579,"children":28580},{"style":9187},[28581],{"type":52,"value":9254},{"type":46,"tag":250,"props":28583,"children":28584},{"class":252,"line":9284},[28585],{"type":46,"tag":250,"props":28586,"children":28587},{"style":9187},[28588],{"type":52,"value":26082},{"type":46,"tag":250,"props":28590,"children":28591},{"class":252,"line":9293},[28592],{"type":46,"tag":250,"props":28593,"children":28594},{"style":9187},[28595],{"type":52,"value":13288},{"type":46,"tag":250,"props":28597,"children":28598},{"class":252,"line":4121},[28599],{"type":46,"tag":250,"props":28600,"children":28601},{"style":9187},[28602],{"type":52,"value":9281},{"type":46,"tag":250,"props":28604,"children":28605},{"class":252,"line":9310},[28606],{"type":46,"tag":250,"props":28607,"children":28608},{"style":9187},[28609],{"type":52,"value":9290},{"type":46,"tag":250,"props":28611,"children":28612},{"class":252,"line":9319},[28613],{"type":46,"tag":250,"props":28614,"children":28615},{"style":9187},[28616],{"type":52,"value":9299},{"type":46,"tag":250,"props":28618,"children":28619},{"class":252,"line":9327},[28620],{"type":46,"tag":250,"props":28621,"children":28622},{"style":9187},[28623],{"type":52,"value":9377},{"type":46,"tag":250,"props":28625,"children":28626},{"class":252,"line":9335},[28627],{"type":46,"tag":250,"props":28628,"children":28629},{"emptyLinePlaceholder":22},[28630],{"type":52,"value":9386},{"type":46,"tag":250,"props":28632,"children":28633},{"class":252,"line":9344},[28634,28638,28642,28646],{"type":46,"tag":250,"props":28635,"children":28636},{"style":375},[28637],{"type":52,"value":19021},{"type":46,"tag":250,"props":28639,"children":28640},{"style":268},[28641],{"type":52,"value":26136},{"type":46,"tag":250,"props":28643,"children":28644},{"style":375},[28645],{"type":52,"value":9608},{"type":46,"tag":250,"props":28647,"children":28648},{"style":268},[28649],{"type":52,"value":19035},{"type":46,"tag":250,"props":28651,"children":28652},{"class":252,"line":9353},[28653],{"type":46,"tag":250,"props":28654,"children":28655},{"style":375},[28656],{"type":52,"value":19043},{"type":46,"tag":250,"props":28658,"children":28659},{"class":252,"line":9362},[28660,28664,28668,28672,28676,28680,28684],{"type":46,"tag":250,"props":28661,"children":28662},{"style":274},[28663],{"type":52,"value":19051},{"type":46,"tag":250,"props":28665,"children":28666},{"style":268},[28667],{"type":52,"value":106},{"type":46,"tag":250,"props":28669,"children":28670},{"style":274},[28671],{"type":52,"value":19118},{"type":46,"tag":250,"props":28673,"children":28674},{"style":268},[28675],{"type":52,"value":11877},{"type":46,"tag":250,"props":28677,"children":28678},{"style":375},[28679],{"type":52,"value":11882},{"type":46,"tag":250,"props":28681,"children":28682},{"style":375},[28683],{"type":52,"value":9418},{"type":46,"tag":250,"props":28685,"children":28686},{"style":268},[28687],{"type":52,"value":9497},{"type":46,"tag":250,"props":28689,"children":28690},{"class":252,"line":9371},[28691,28696,28700,28704,28708,28712,28716,28720,28724,28728,28732,28736,28740,28744,28748,28752,28756,28760,28764,28768,28772],{"type":46,"tag":250,"props":28692,"children":28693},{"style":274},[28694],{"type":52,"value":28695},"        COUNT",{"type":46,"tag":250,"props":28697,"children":28698},{"style":268},[28699],{"type":52,"value":9557},{"type":46,"tag":250,"props":28701,"children":28702},{"style":375},[28703],{"type":52,"value":14960},{"type":46,"tag":250,"props":28705,"children":28706},{"style":375},[28707],{"type":52,"value":15554},{"type":46,"tag":250,"props":28709,"children":28710},{"style":274},[28711],{"type":52,"value":10046},{"type":46,"tag":250,"props":28713,"children":28714},{"style":268},[28715],{"type":52,"value":106},{"type":46,"tag":250,"props":28717,"children":28718},{"style":274},[28719],{"type":52,"value":19085},{"type":46,"tag":250,"props":28721,"children":28722},{"style":268},[28723],{"type":52,"value":11877},{"type":46,"tag":250,"props":28725,"children":28726},{"style":375},[28727],{"type":52,"value":11882},{"type":46,"tag":250,"props":28729,"children":28730},{"style":375},[28731],{"type":52,"value":10041},{"type":46,"tag":250,"props":28733,"children":28734},{"style":274},[28735],{"type":52,"value":10028},{"type":46,"tag":250,"props":28737,"children":28738},{"style":268},[28739],{"type":52,"value":106},{"type":46,"tag":250,"props":28741,"children":28742},{"style":274},[28743],{"type":52,"value":19118},{"type":46,"tag":250,"props":28745,"children":28746},{"style":268},[28747],{"type":52,"value":11877},{"type":46,"tag":250,"props":28749,"children":28750},{"style":375},[28751],{"type":52,"value":11882},{"type":46,"tag":250,"props":28753,"children":28754},{"style":375},[28755],{"type":52,"value":15149},{"type":46,"tag":250,"props":28757,"children":28758},{"style":274},[28759],{"type":52,"value":15586},{"type":46,"tag":250,"props":28761,"children":28762},{"style":375},[28763],{"type":52,"value":15591},{"type":46,"tag":250,"props":28765,"children":28766},{"style":268},[28767],{"type":52,"value":10086},{"type":46,"tag":250,"props":28769,"children":28770},{"style":375},[28771],{"type":52,"value":9608},{"type":46,"tag":250,"props":28773,"children":28774},{"style":268},[28775],{"type":52,"value":26240},{"type":46,"tag":250,"props":28777,"children":28778},{"class":252,"line":9380},[28779,28783,28787,28791,28795,28799,28803,28807,28811,28815,28820,28824,28828,28832,28836,28840,28844,28848,28852,28856,28860],{"type":46,"tag":250,"props":28780,"children":28781},{"style":274},[28782],{"type":52,"value":28695},{"type":46,"tag":250,"props":28784,"children":28785},{"style":268},[28786],{"type":52,"value":9557},{"type":46,"tag":250,"props":28788,"children":28789},{"style":375},[28790],{"type":52,"value":14960},{"type":46,"tag":250,"props":28792,"children":28793},{"style":375},[28794],{"type":52,"value":15554},{"type":46,"tag":250,"props":28796,"children":28797},{"style":274},[28798],{"type":52,"value":10046},{"type":46,"tag":250,"props":28800,"children":28801},{"style":268},[28802],{"type":52,"value":106},{"type":46,"tag":250,"props":28804,"children":28805},{"style":274},[28806],{"type":52,"value":19085},{"type":46,"tag":250,"props":28808,"children":28809},{"style":268},[28810],{"type":52,"value":11877},{"type":46,"tag":250,"props":28812,"children":28813},{"style":375},[28814],{"type":52,"value":11882},{"type":46,"tag":250,"props":28816,"children":28817},{"style":375},[28818],{"type":52,"value":28819}," \u003C",{"type":46,"tag":250,"props":28821,"children":28822},{"style":274},[28823],{"type":52,"value":10028},{"type":46,"tag":250,"props":28825,"children":28826},{"style":268},[28827],{"type":52,"value":106},{"type":46,"tag":250,"props":28829,"children":28830},{"style":274},[28831],{"type":52,"value":19118},{"type":46,"tag":250,"props":28833,"children":28834},{"style":268},[28835],{"type":52,"value":11877},{"type":46,"tag":250,"props":28837,"children":28838},{"style":375},[28839],{"type":52,"value":11882},{"type":46,"tag":250,"props":28841,"children":28842},{"style":375},[28843],{"type":52,"value":15149},{"type":46,"tag":250,"props":28845,"children":28846},{"style":274},[28847],{"type":52,"value":15586},{"type":46,"tag":250,"props":28849,"children":28850},{"style":375},[28851],{"type":52,"value":15591},{"type":46,"tag":250,"props":28853,"children":28854},{"style":268},[28855],{"type":52,"value":10086},{"type":46,"tag":250,"props":28857,"children":28858},{"style":375},[28859],{"type":52,"value":9608},{"type":46,"tag":250,"props":28861,"children":28862},{"style":268},[28863],{"type":52,"value":26297},{"type":46,"tag":250,"props":28865,"children":28866},{"class":252,"line":9389},[28867,28871,28875,28879,28883],{"type":46,"tag":250,"props":28868,"children":28869},{"style":375},[28870],{"type":52,"value":19155},{"type":46,"tag":250,"props":28872,"children":28873},{"style":274},[28874],{"type":52,"value":17433},{"type":46,"tag":250,"props":28876,"children":28877},{"style":268},[28878],{"type":52,"value":106},{"type":46,"tag":250,"props":28880,"children":28881},{"style":274},[28882],{"type":52,"value":18055},{"type":46,"tag":250,"props":28884,"children":28885},{"style":268},[28886],{"type":52,"value":9988},{"type":46,"tag":250,"props":28888,"children":28889},{"class":252,"line":9398},[28890,28894,28898,28902,28906],{"type":46,"tag":250,"props":28891,"children":28892},{"style":375},[28893],{"type":52,"value":26328},{"type":46,"tag":250,"props":28895,"children":28896},{"style":274},[28897],{"type":52,"value":17433},{"type":46,"tag":250,"props":28899,"children":28900},{"style":268},[28901],{"type":52,"value":106},{"type":46,"tag":250,"props":28903,"children":28904},{"style":274},[28905],{"type":52,"value":19192},{"type":46,"tag":250,"props":28907,"children":28908},{"style":268},[28909],{"type":52,"value":10014},{"type":46,"tag":250,"props":28911,"children":28912},{"class":252,"line":9426},[28913,28917,28921,28925,28929,28933,28937,28941],{"type":46,"tag":250,"props":28914,"children":28915},{"style":375},[28916],{"type":52,"value":19204},{"type":46,"tag":250,"props":28918,"children":28919},{"style":274},[28920],{"type":52,"value":10028},{"type":46,"tag":250,"props":28922,"children":28923},{"style":268},[28924],{"type":52,"value":106},{"type":46,"tag":250,"props":28926,"children":28927},{"style":274},[28928],{"type":52,"value":19060},{"type":46,"tag":250,"props":28930,"children":28931},{"style":375},[28932],{"type":52,"value":10041},{"type":46,"tag":250,"props":28934,"children":28935},{"style":274},[28936],{"type":52,"value":10046},{"type":46,"tag":250,"props":28938,"children":28939},{"style":268},[28940],{"type":52,"value":106},{"type":46,"tag":250,"props":28942,"children":28943},{"style":274},[28944],{"type":52,"value":19233},{"type":46,"tag":250,"props":28946,"children":28947},{"class":252,"line":9448},[28948,28952,28956,28960,28964,28968],{"type":46,"tag":250,"props":28949,"children":28950},{"style":375},[28951],{"type":52,"value":19241},{"type":46,"tag":250,"props":28953,"children":28954},{"style":274},[28955],{"type":52,"value":10028},{"type":46,"tag":250,"props":28957,"children":28958},{"style":268},[28959],{"type":52,"value":106},{"type":46,"tag":250,"props":28961,"children":28962},{"style":274},[28963],{"type":52,"value":19254},{"type":46,"tag":250,"props":28965,"children":28966},{"style":375},[28967],{"type":52,"value":10041},{"type":46,"tag":250,"props":28969,"children":28970},{"style":262},[28971],{"type":52,"value":19263},{"type":46,"tag":250,"props":28973,"children":28974},{"class":252,"line":9474},[28975,28979,28983,28987,28991,28995],{"type":46,"tag":250,"props":28976,"children":28977},{"style":375},[28978],{"type":52,"value":19353},{"type":46,"tag":250,"props":28980,"children":28981},{"style":274},[28982],{"type":52,"value":10028},{"type":46,"tag":250,"props":28984,"children":28985},{"style":268},[28986],{"type":52,"value":106},{"type":46,"tag":250,"props":28988,"children":28989},{"style":274},[28990],{"type":52,"value":19118},{"type":46,"tag":250,"props":28992,"children":28993},{"style":268},[28994],{"type":52,"value":11877},{"type":46,"tag":250,"props":28996,"children":28997},{"style":375},[28998],{"type":52,"value":11907},{"type":46,"tag":250,"props":29000,"children":29001},{"class":252,"line":9500},[29002],{"type":46,"tag":250,"props":29003,"children":29004},{"style":268},[29005],{"type":52,"value":19271},{"type":46,"tag":250,"props":29007,"children":29008},{"class":252,"line":9525},[29009,29013,29017],{"type":46,"tag":250,"props":29010,"children":29011},{"style":268},[29012],{"type":52,"value":26448},{"type":46,"tag":250,"props":29014,"children":29015},{"style":375},[29016],{"type":52,"value":9608},{"type":46,"tag":250,"props":29018,"children":29019},{"style":268},[29020],{"type":52,"value":19035},{"type":46,"tag":250,"props":29022,"children":29023},{"class":252,"line":9546},[29024],{"type":46,"tag":250,"props":29025,"children":29026},{"style":375},[29027],{"type":52,"value":19043},{"type":46,"tag":250,"props":29029,"children":29030},{"class":252,"line":9616},[29031],{"type":46,"tag":250,"props":29032,"children":29033},{"style":268},[29034],{"type":52,"value":22329},{"type":46,"tag":250,"props":29036,"children":29037},{"class":252,"line":9678},[29038,29042,29046,29050,29054],{"type":46,"tag":250,"props":29039,"children":29040},{"style":274},[29041],{"type":52,"value":22182},{"type":46,"tag":250,"props":29043,"children":29044},{"style":268},[29045],{"type":52,"value":22348},{"type":46,"tag":250,"props":29047,"children":29048},{"style":375},[29049],{"type":52,"value":9608},{"type":46,"tag":250,"props":29051,"children":29052},{"style":375},[29053],{"type":52,"value":22357},{"type":46,"tag":250,"props":29055,"children":29056},{"style":268},[29057],{"type":52,"value":9445},{"type":46,"tag":250,"props":29059,"children":29060},{"class":252,"line":9740},[29061,29065,29069,29073],{"type":46,"tag":250,"props":29062,"children":29063},{"style":274},[29064],{"type":52,"value":22182},{"type":46,"tag":250,"props":29066,"children":29067},{"style":268},[29068],{"type":52,"value":22373},{"type":46,"tag":250,"props":29070,"children":29071},{"style":375},[29072],{"type":52,"value":9608},{"type":46,"tag":250,"props":29074,"children":29075},{"style":268},[29076],{"type":52,"value":26513},{"type":46,"tag":250,"props":29078,"children":29079},{"class":252,"line":9802},[29080,29084,29088,29092],{"type":46,"tag":250,"props":29081,"children":29082},{"style":274},[29083],{"type":52,"value":22182},{"type":46,"tag":250,"props":29085,"children":29086},{"style":268},[29087],{"type":52,"value":22393},{"type":46,"tag":250,"props":29089,"children":29090},{"style":375},[29091],{"type":52,"value":9608},{"type":46,"tag":250,"props":29093,"children":29094},{"style":268},[29095],{"type":52,"value":22402},{"type":46,"tag":250,"props":29097,"children":29098},{"class":252,"line":9823},[29099,29103,29107,29111],{"type":46,"tag":250,"props":29100,"children":29101},{"style":375},[29102],{"type":52,"value":19155},{"type":46,"tag":250,"props":29104,"children":29105},{"style":274},[29106],{"type":52,"value":17433},{"type":46,"tag":250,"props":29108,"children":29109},{"style":268},[29110],{"type":52,"value":106},{"type":46,"tag":250,"props":29112,"children":29113},{"style":274},[29114],{"type":52,"value":22422},{"type":46,"tag":250,"props":29116,"children":29117},{"class":252,"line":9844},[29118,29122],{"type":46,"tag":250,"props":29119,"children":29120},{"style":375},[29121],{"type":52,"value":19353},{"type":46,"tag":250,"props":29123,"children":29124},{"style":268},[29125],{"type":52,"value":26563},{"type":46,"tag":250,"props":29127,"children":29128},{"class":252,"line":9865},[29129],{"type":46,"tag":250,"props":29130,"children":29131},{"style":268},[29132],{"type":52,"value":19271},{"type":46,"tag":250,"props":29134,"children":29135},{"class":252,"line":9911},[29136,29140,29144],{"type":46,"tag":250,"props":29137,"children":29138},{"style":268},[29139],{"type":52,"value":26578},{"type":46,"tag":250,"props":29141,"children":29142},{"style":375},[29143],{"type":52,"value":9608},{"type":46,"tag":250,"props":29145,"children":29146},{"style":268},[29147],{"type":52,"value":19035},{"type":46,"tag":250,"props":29149,"children":29150},{"class":252,"line":9937},[29151],{"type":46,"tag":250,"props":29152,"children":29153},{"style":375},[29154],{"type":52,"value":19043},{"type":46,"tag":250,"props":29156,"children":29157},{"class":252,"line":9963},[29158],{"type":46,"tag":250,"props":29159,"children":29160},{"style":268},[29161],{"type":52,"value":22166},{"type":46,"tag":250,"props":29163,"children":29164},{"class":252,"line":9991},[29165,29169,29173,29177],{"type":46,"tag":250,"props":29166,"children":29167},{"style":274},[29168],{"type":52,"value":22182},{"type":46,"tag":250,"props":29170,"children":29171},{"style":268},[29172],{"type":52,"value":22187},{"type":46,"tag":250,"props":29174,"children":29175},{"style":375},[29176],{"type":52,"value":9608},{"type":46,"tag":250,"props":29178,"children":29179},{"style":268},[29180],{"type":52,"value":26620},{"type":46,"tag":250,"props":29182,"children":29183},{"class":252,"line":10017},[29184,29188,29192,29196],{"type":46,"tag":250,"props":29185,"children":29186},{"style":375},[29187],{"type":52,"value":19155},{"type":46,"tag":250,"props":29189,"children":29190},{"style":274},[29191],{"type":52,"value":17433},{"type":46,"tag":250,"props":29193,"children":29194},{"style":268},[29195],{"type":52,"value":106},{"type":46,"tag":250,"props":29197,"children":29198},{"style":274},[29199],{"type":52,"value":22279},{"type":46,"tag":250,"props":29201,"children":29202},{"class":252,"line":10058},[29203,29207],{"type":46,"tag":250,"props":29204,"children":29205},{"style":375},[29206],{"type":52,"value":19353},{"type":46,"tag":250,"props":29208,"children":29209},{"style":268},[29210],{"type":52,"value":26651},{"type":46,"tag":250,"props":29212,"children":29213},{"class":252,"line":10936},[29214],{"type":46,"tag":250,"props":29215,"children":29216},{"style":268},[29217],{"type":52,"value":10114},{"type":46,"tag":250,"props":29219,"children":29220},{"class":252,"line":10995},[29221],{"type":46,"tag":250,"props":29222,"children":29223},{"style":375},[29224],{"type":52,"value":9395},{"type":46,"tag":250,"props":29226,"children":29227},{"class":252,"line":22686},[29228,29232,29236,29240,29244],{"type":46,"tag":250,"props":29229,"children":29230},{"style":274},[29231],{"type":52,"value":26673},{"type":46,"tag":250,"props":29233,"children":29234},{"style":268},[29235],{"type":52,"value":106},{"type":46,"tag":250,"props":29237,"children":29238},{"style":274},[29239],{"type":52,"value":19118},{"type":46,"tag":250,"props":29241,"children":29242},{"style":375},[29243],{"type":52,"value":9418},{"type":46,"tag":250,"props":29245,"children":29246},{"style":268},[29247],{"type":52,"value":26690},{"type":46,"tag":250,"props":29249,"children":29250},{"class":252,"line":22694},[29251,29255,29259,29263],{"type":46,"tag":250,"props":29252,"children":29253},{"style":274},[29254],{"type":52,"value":26673},{"type":46,"tag":250,"props":29256,"children":29257},{"style":268},[29258],{"type":52,"value":106},{"type":46,"tag":250,"props":29260,"children":29261},{"style":274},[29262],{"type":52,"value":26706},{"type":46,"tag":250,"props":29264,"children":29265},{"style":268},[29266],{"type":52,"value":9445},{"type":46,"tag":250,"props":29268,"children":29269},{"class":252,"line":22702},[29270,29274,29278,29282],{"type":46,"tag":250,"props":29271,"children":29272},{"style":274},[29273],{"type":52,"value":26673},{"type":46,"tag":250,"props":29275,"children":29276},{"style":268},[29277],{"type":52,"value":106},{"type":46,"tag":250,"props":29279,"children":29280},{"style":274},[29281],{"type":52,"value":26726},{"type":46,"tag":250,"props":29283,"children":29284},{"style":268},[29285],{"type":52,"value":9445},{"type":46,"tag":250,"props":29287,"children":29288},{"class":252,"line":22728},[29289,29293,29297,29301],{"type":46,"tag":250,"props":29290,"children":29291},{"style":274},[29292],{"type":52,"value":26673},{"type":46,"tag":250,"props":29294,"children":29295},{"style":268},[29296],{"type":52,"value":106},{"type":46,"tag":250,"props":29298,"children":29299},{"style":274},[29300],{"type":52,"value":26746},{"type":46,"tag":250,"props":29302,"children":29303},{"style":268},[29304],{"type":52,"value":9445},{"type":46,"tag":250,"props":29306,"children":29307},{"class":252,"line":22748},[29308,29312,29316,29320],{"type":46,"tag":250,"props":29309,"children":29310},{"style":274},[29311],{"type":52,"value":26673},{"type":46,"tag":250,"props":29313,"children":29314},{"style":268},[29315],{"type":52,"value":106},{"type":46,"tag":250,"props":29317,"children":29318},{"style":274},[29319],{"type":52,"value":26766},{"type":46,"tag":250,"props":29321,"children":29322},{"style":268},[29323],{"type":52,"value":9445},{"type":46,"tag":250,"props":29325,"children":29326},{"class":252,"line":22769},[29327,29331,29335,29339],{"type":46,"tag":250,"props":29328,"children":29329},{"style":274},[29330],{"type":52,"value":26673},{"type":46,"tag":250,"props":29332,"children":29333},{"style":268},[29334],{"type":52,"value":106},{"type":46,"tag":250,"props":29336,"children":29337},{"style":274},[29338],{"type":52,"value":26786},{"type":46,"tag":250,"props":29340,"children":29341},{"style":268},[29342],{"type":52,"value":9445},{"type":46,"tag":250,"props":29344,"children":29345},{"class":252,"line":22790},[29346,29350,29354,29358],{"type":46,"tag":250,"props":29347,"children":29348},{"style":274},[29349],{"type":52,"value":26798},{"type":46,"tag":250,"props":29351,"children":29352},{"style":268},[29353],{"type":52,"value":106},{"type":46,"tag":250,"props":29355,"children":29356},{"style":274},[29357],{"type":52,"value":26807},{"type":46,"tag":250,"props":29359,"children":29360},{"style":268},[29361],{"type":52,"value":9445},{"type":46,"tag":250,"props":29363,"children":29364},{"class":252,"line":22811},[29365,29369,29373,29377],{"type":46,"tag":250,"props":29366,"children":29367},{"style":274},[29368],{"type":52,"value":26798},{"type":46,"tag":250,"props":29370,"children":29371},{"style":268},[29372],{"type":52,"value":106},{"type":46,"tag":250,"props":29374,"children":29375},{"style":274},[29376],{"type":52,"value":26827},{"type":46,"tag":250,"props":29378,"children":29379},{"style":268},[29380],{"type":52,"value":9445},{"type":46,"tag":250,"props":29382,"children":29383},{"class":252,"line":22832},[29384,29388,29392,29396],{"type":46,"tag":250,"props":29385,"children":29386},{"style":274},[29387],{"type":52,"value":26839},{"type":46,"tag":250,"props":29389,"children":29390},{"style":268},[29391],{"type":52,"value":106},{"type":46,"tag":250,"props":29393,"children":29394},{"style":274},[29395],{"type":52,"value":15030},{"type":46,"tag":250,"props":29397,"children":29398},{"style":268},[29399],{"type":52,"value":9445},{"type":46,"tag":250,"props":29401,"children":29402},{"class":252,"line":22853},[29403,29407,29411,29415],{"type":46,"tag":250,"props":29404,"children":29405},{"style":274},[29406],{"type":52,"value":26839},{"type":46,"tag":250,"props":29408,"children":29409},{"style":268},[29410],{"type":52,"value":106},{"type":46,"tag":250,"props":29412,"children":29413},{"style":274},[29414],{"type":52,"value":26867},{"type":46,"tag":250,"props":29416,"children":29417},{"style":268},[29418],{"type":52,"value":9445},{"type":46,"tag":250,"props":29420,"children":29421},{"class":252,"line":22873},[29422,29426,29430,29434,29438,29442,29446,29450,29454,29458,29462,29466,29470,29474,29478,29482,29486,29490,29494,29498,29502],{"type":46,"tag":250,"props":29423,"children":29424},{"style":274},[29425],{"type":52,"value":17313},{"type":46,"tag":250,"props":29427,"children":29428},{"style":268},[29429],{"type":52,"value":9557},{"type":46,"tag":250,"props":29431,"children":29432},{"style":274},[29433],{"type":52,"value":26887},{"type":46,"tag":250,"props":29435,"children":29436},{"style":268},[29437],{"type":52,"value":106},{"type":46,"tag":250,"props":29439,"children":29440},{"style":274},[29441],{"type":52,"value":26896},{"type":46,"tag":250,"props":29443,"children":29444},{"style":375},[29445],{"type":52,"value":9885},{"type":46,"tag":250,"props":29447,"children":29448},{"style":274},[29449],{"type":52,"value":17909},{"type":46,"tag":250,"props":29451,"children":29452},{"style":268},[29453],{"type":52,"value":9557},{"type":46,"tag":250,"props":29455,"children":29456},{"style":274},[29457],{"type":52,"value":26887},{"type":46,"tag":250,"props":29459,"children":29460},{"style":268},[29461],{"type":52,"value":106},{"type":46,"tag":250,"props":29463,"children":29464},{"style":274},[29465],{"type":52,"value":15030},{"type":46,"tag":250,"props":29467,"children":29468},{"style":268},[29469],{"type":52,"value":151},{"type":46,"tag":250,"props":29471,"children":29472},{"style":274},[29473],{"type":52,"value":9899},{"type":46,"tag":250,"props":29475,"children":29476},{"style":268},[29477],{"type":52,"value":10086},{"type":46,"tag":250,"props":29479,"children":29480},{"style":375},[29481],{"type":52,"value":15522},{"type":46,"tag":250,"props":29483,"children":29484},{"style":274},[29485],{"type":52,"value":9890},{"type":46,"tag":250,"props":29487,"children":29488},{"style":268},[29489],{"type":52,"value":151},{"type":46,"tag":250,"props":29491,"children":29492},{"style":274},[29493],{"type":52,"value":9598},{"type":46,"tag":250,"props":29495,"children":29496},{"style":268},[29497],{"type":52,"value":10086},{"type":46,"tag":250,"props":29499,"children":29500},{"style":375},[29501],{"type":52,"value":9608},{"type":46,"tag":250,"props":29503,"children":29504},{"style":268},[29505],{"type":52,"value":26961},{"type":46,"tag":250,"props":29507,"children":29508},{"class":252,"line":22895},[29509,29513,29517,29521],{"type":46,"tag":250,"props":29510,"children":29511},{"style":274},[29512],{"type":52,"value":26969},{"type":46,"tag":250,"props":29514,"children":29515},{"style":268},[29516],{"type":52,"value":106},{"type":46,"tag":250,"props":29518,"children":29519},{"style":274},[29520],{"type":52,"value":26978},{"type":46,"tag":250,"props":29522,"children":29523},{"style":268},[29524],{"type":52,"value":9445},{"type":46,"tag":250,"props":29526,"children":29527},{"class":252,"line":22973},[29528,29532,29536,29540,29544,29548,29552,29556,29560,29564,29568,29572,29576,29580,29584,29588,29592,29596],{"type":46,"tag":250,"props":29529,"children":29530},{"style":274},[29531],{"type":52,"value":17313},{"type":46,"tag":250,"props":29533,"children":29534},{"style":268},[29535],{"type":52,"value":9557},{"type":46,"tag":250,"props":29537,"children":29538},{"style":274},[29539],{"type":52,"value":26998},{"type":46,"tag":250,"props":29541,"children":29542},{"style":268},[29543],{"type":52,"value":106},{"type":46,"tag":250,"props":29545,"children":29546},{"style":274},[29547],{"type":52,"value":26706},{"type":46,"tag":250,"props":29549,"children":29550},{"style":375},[29551],{"type":52,"value":9885},{"type":46,"tag":250,"props":29553,"children":29554},{"style":274},[29555],{"type":52,"value":17909},{"type":46,"tag":250,"props":29557,"children":29558},{"style":268},[29559],{"type":52,"value":9557},{"type":46,"tag":250,"props":29561,"children":29562},{"style":274},[29563],{"type":52,"value":27023},{"type":46,"tag":250,"props":29565,"children":29566},{"style":268},[29567],{"type":52,"value":106},{"type":46,"tag":250,"props":29569,"children":29570},{"style":274},[29571],{"type":52,"value":26978},{"type":46,"tag":250,"props":29573,"children":29574},{"style":268},[29575],{"type":52,"value":151},{"type":46,"tag":250,"props":29577,"children":29578},{"style":274},[29579],{"type":52,"value":9899},{"type":46,"tag":250,"props":29581,"children":29582},{"style":268},[29583],{"type":52,"value":17342},{"type":46,"tag":250,"props":29585,"children":29586},{"style":274},[29587],{"type":52,"value":9598},{"type":46,"tag":250,"props":29589,"children":29590},{"style":268},[29591],{"type":52,"value":10086},{"type":46,"tag":250,"props":29593,"children":29594},{"style":375},[29595],{"type":52,"value":9608},{"type":46,"tag":250,"props":29597,"children":29598},{"style":268},[29599],{"type":52,"value":27060},{"type":46,"tag":250,"props":29601,"children":29602},{"class":252,"line":23050},[29603,29607,29611,29615,29619],{"type":46,"tag":250,"props":29604,"children":29605},{"style":375},[29606],{"type":52,"value":9969},{"type":46,"tag":250,"props":29608,"children":29609},{"style":274},[29610],{"type":52,"value":27072},{"type":46,"tag":250,"props":29612,"children":29613},{"style":268},[29614],{"type":52,"value":106},{"type":46,"tag":250,"props":29616,"children":29617},{"style":274},[29618],{"type":52,"value":27081},{"type":46,"tag":250,"props":29620,"children":29621},{"style":268},[29622],{"type":52,"value":27086},{"type":46,"tag":250,"props":29624,"children":29625},{"class":252,"line":23139},[29626,29630,29634,29638,29642,29646,29650,29654,29658,29662],{"type":46,"tag":250,"props":29627,"children":29628},{"style":375},[29629],{"type":52,"value":9077},{"type":46,"tag":250,"props":29631,"children":29632},{"style":268},[29633],{"type":52,"value":27098},{"type":46,"tag":250,"props":29635,"children":29636},{"style":375},[29637],{"type":52,"value":27103},{"type":46,"tag":250,"props":29639,"children":29640},{"style":274},[29641],{"type":52,"value":27108},{"type":46,"tag":250,"props":29643,"children":29644},{"style":268},[29645],{"type":52,"value":106},{"type":46,"tag":250,"props":29647,"children":29648},{"style":274},[29649],{"type":52,"value":19118},{"type":46,"tag":250,"props":29651,"children":29652},{"style":375},[29653],{"type":52,"value":10041},{"type":46,"tag":250,"props":29655,"children":29656},{"style":274},[29657],{"type":52,"value":27125},{"type":46,"tag":250,"props":29659,"children":29660},{"style":268},[29661],{"type":52,"value":106},{"type":46,"tag":250,"props":29663,"children":29664},{"style":274},[29665],{"type":52,"value":23286},{"type":46,"tag":250,"props":29667,"children":29668},{"class":252,"line":23152},[29669,29673,29677,29681,29685,29689,29693,29697,29701,29705],{"type":46,"tag":250,"props":29670,"children":29671},{"style":375},[29672],{"type":52,"value":9077},{"type":46,"tag":250,"props":29674,"children":29675},{"style":268},[29676],{"type":52,"value":27145},{"type":46,"tag":250,"props":29678,"children":29679},{"style":375},[29680],{"type":52,"value":27103},{"type":46,"tag":250,"props":29682,"children":29683},{"style":274},[29684],{"type":52,"value":27108},{"type":46,"tag":250,"props":29686,"children":29687},{"style":268},[29688],{"type":52,"value":106},{"type":46,"tag":250,"props":29690,"children":29691},{"style":274},[29692],{"type":52,"value":19118},{"type":46,"tag":250,"props":29694,"children":29695},{"style":375},[29696],{"type":52,"value":10041},{"type":46,"tag":250,"props":29698,"children":29699},{"style":274},[29700],{"type":52,"value":27170},{"type":46,"tag":250,"props":29702,"children":29703},{"style":268},[29704],{"type":52,"value":106},{"type":46,"tag":250,"props":29706,"children":29707},{"style":274},[29708],{"type":52,"value":22630},{"type":46,"tag":250,"props":29710,"children":29711},{"class":252,"line":23165},[29712,29716,29720,29724,29728,29732,29736,29740,29744,29748],{"type":46,"tag":250,"props":29713,"children":29714},{"style":375},[29715],{"type":52,"value":9077},{"type":46,"tag":250,"props":29717,"children":29718},{"style":268},[29719],{"type":52,"value":27190},{"type":46,"tag":250,"props":29721,"children":29722},{"style":375},[29723],{"type":52,"value":27103},{"type":46,"tag":250,"props":29725,"children":29726},{"style":274},[29727],{"type":52,"value":27108},{"type":46,"tag":250,"props":29729,"children":29730},{"style":268},[29731],{"type":52,"value":106},{"type":46,"tag":250,"props":29733,"children":29734},{"style":274},[29735],{"type":52,"value":19118},{"type":46,"tag":250,"props":29737,"children":29738},{"style":375},[29739],{"type":52,"value":10041},{"type":46,"tag":250,"props":29741,"children":29742},{"style":274},[29743],{"type":52,"value":27215},{"type":46,"tag":250,"props":29745,"children":29746},{"style":268},[29747],{"type":52,"value":106},{"type":46,"tag":250,"props":29749,"children":29750},{"style":274},[29751],{"type":52,"value":27224},{"type":46,"tag":250,"props":29753,"children":29754},{"class":252,"line":23202},[29755,29759,29763],{"type":46,"tag":250,"props":29756,"children":29757},{"style":375},[29758],{"type":52,"value":17462},{"type":46,"tag":250,"props":29760,"children":29761},{"style":268},[29762],{"type":52,"value":27236},{"type":46,"tag":250,"props":29764,"children":29765},{"style":375},[29766],{"type":52,"value":27241},{"type":46,"tag":220,"props":29768,"children":29770},{"id":29769},"run-the-full-pipeline-end-to-end",[29771],{"type":52,"value":29772},"Run the full pipeline end-to-end",{"type":46,"tag":55,"props":29774,"children":29775},{},[29776],{"type":52,"value":29777},"Run the entire pipeline - ingestion, staging, and reports - in one command:",{"type":46,"tag":240,"props":29779,"children":29780},{"className":242,"code":8519,"language":244,"meta":7,"style":7},[29781],{"type":46,"tag":99,"props":29782,"children":29783},{"__ignoreMap":7},[29784],{"type":46,"tag":250,"props":29785,"children":29786},{"class":252,"line":23},[29787,29791,29795,29799,29803,29807,29811],{"type":46,"tag":250,"props":29788,"children":29789},{"style":256},[29790],{"type":52,"value":305},{"type":46,"tag":250,"props":29792,"children":29793},{"style":262},[29794],{"type":52,"value":8535},{"type":46,"tag":250,"props":29796,"children":29797},{"style":274},[29798],{"type":52,"value":8540},{"type":46,"tag":250,"props":29800,"children":29801},{"style":262},[29802],{"type":52,"value":8545},{"type":46,"tag":250,"props":29804,"children":29805},{"style":274},[29806],{"type":52,"value":8550},{"type":46,"tag":250,"props":29808,"children":29809},{"style":262},[29810],{"type":52,"value":8555},{"type":46,"tag":250,"props":29812,"children":29813},{"style":262},[29814],{"type":52,"value":1510},{"type":46,"tag":55,"props":29816,"children":29817},{},[29818,29820,29825,29827,29831],{"type":52,"value":29819},"Bruin executes everything in dependency order: ",{"type":46,"tag":88,"props":29821,"children":29822},{"href":161},[29823],{"type":52,"value":29824},"ingestor assets",{"type":52,"value":29826}," first, then staging, then reports. ",{"type":46,"tag":88,"props":29828,"children":29829},{"href":161},[29830],{"type":52,"value":8796},{"type":52,"value":29832}," run after each asset.",{"type":46,"tag":55,"props":29834,"children":29835},{},[29836],{"type":52,"value":29837},"If your test month looks good, run a full backfill:",{"type":46,"tag":240,"props":29839,"children":29841},{"className":242,"code":29840,"language":244,"meta":7,"style":7},"bruin run --start-date 2024-01-01 --end-date 2025-04-01 .\n",[29842],{"type":46,"tag":99,"props":29843,"children":29844},{"__ignoreMap":7},[29845],{"type":46,"tag":250,"props":29846,"children":29847},{"class":252,"line":23},[29848,29852,29856,29860,29864,29868,29873],{"type":46,"tag":250,"props":29849,"children":29850},{"style":256},[29851],{"type":52,"value":305},{"type":46,"tag":250,"props":29853,"children":29854},{"style":262},[29855],{"type":52,"value":8535},{"type":46,"tag":250,"props":29857,"children":29858},{"style":274},[29859],{"type":52,"value":8540},{"type":46,"tag":250,"props":29861,"children":29862},{"style":262},[29863],{"type":52,"value":8692},{"type":46,"tag":250,"props":29865,"children":29866},{"style":274},[29867],{"type":52,"value":8550},{"type":46,"tag":250,"props":29869,"children":29870},{"style":262},[29871],{"type":52,"value":29872}," 2025-04-01",{"type":46,"tag":250,"props":29874,"children":29875},{"style":262},[29876],{"type":52,"value":1510},{"type":46,"tag":55,"props":29878,"children":29879},{},[29880,29882,29888],{"type":52,"value":29881},"You can also use ",{"type":46,"tag":99,"props":29883,"children":29885},{"className":29884},[],[29886],{"type":52,"value":29887},"--full-refresh",{"type":52,"value":29889}," to drop and recreate all tables from scratch if you need a clean slate:",{"type":46,"tag":240,"props":29891,"children":29893},{"className":242,"code":29892,"language":244,"meta":7,"style":7},"bruin run --full-refresh --start-date 2024-01-01 --end-date 2025-04-01 .\n",[29894],{"type":46,"tag":99,"props":29895,"children":29896},{"__ignoreMap":7},[29897],{"type":46,"tag":250,"props":29898,"children":29899},{"class":252,"line":23},[29900,29904,29908,29913,29917,29921,29925,29929],{"type":46,"tag":250,"props":29901,"children":29902},{"style":256},[29903],{"type":52,"value":305},{"type":46,"tag":250,"props":29905,"children":29906},{"style":262},[29907],{"type":52,"value":8535},{"type":46,"tag":250,"props":29909,"children":29910},{"style":274},[29911],{"type":52,"value":29912}," --full-refresh",{"type":46,"tag":250,"props":29914,"children":29915},{"style":274},[29916],{"type":52,"value":8540},{"type":46,"tag":250,"props":29918,"children":29919},{"style":262},[29920],{"type":52,"value":8692},{"type":46,"tag":250,"props":29922,"children":29923},{"style":274},[29924],{"type":52,"value":8550},{"type":46,"tag":250,"props":29926,"children":29927},{"style":262},[29928],{"type":52,"value":29872},{"type":46,"tag":250,"props":29930,"children":29931},{"style":262},[29932],{"type":52,"value":1510},{"type":46,"tag":55,"props":29934,"children":29935},{},[29936],{"type":52,"value":29937},"Validate the full pipeline:",{"type":46,"tag":240,"props":29939,"children":29940},{"className":242,"code":1489,"language":244,"meta":7,"style":7},[29941],{"type":46,"tag":99,"props":29942,"children":29943},{"__ignoreMap":7},[29944],{"type":46,"tag":250,"props":29945,"children":29946},{"class":252,"line":23},[29947,29951,29955],{"type":46,"tag":250,"props":29948,"children":29949},{"style":256},[29950],{"type":52,"value":305},{"type":46,"tag":250,"props":29952,"children":29953},{"style":262},[29954],{"type":52,"value":1505},{"type":46,"tag":250,"props":29956,"children":29957},{"style":262},[29958],{"type":52,"value":1510},{"type":46,"tag":220,"props":29960,"children":29962},{"id":29961},"verify-results-with-claude-code",[29963],{"type":52,"value":29964},"Verify results with Claude Code",{"type":46,"tag":55,"props":29966,"children":29967},{},[29968],{"type":52,"value":29969},"After the pipeline runs, ask Claude Code to spot-check the reports:",{"type":46,"tag":1434,"props":29971,"children":29972},{},[29973],{"type":46,"tag":55,"props":29974,"children":29975},{},[29976],{"type":52,"value":29977},"Query reports.rpt_daily_revenue for the last 7 days and show me the results. Does anything look off?",{"type":46,"tag":1434,"props":29979,"children":29980},{},[29981],{"type":46,"tag":55,"props":29982,"children":29983},{},[29984],{"type":52,"value":29985},"Check if rpt_customer_cohorts has data for the last 6 months. Show me the retention rate for the most recent cohort.",{"type":46,"tag":1434,"props":29987,"children":29988},{},[29989],{"type":46,"tag":55,"props":29990,"children":29991},{},[29992],{"type":52,"value":29993},"Run bruin validate on the project and summarize any quality check failures.",{"type":46,"tag":55,"props":29995,"children":29996},{},[29997],{"type":52,"value":29998},"If a report looks wrong, Claude Code can compare the report output against the staging tables to find the issue:",{"type":46,"tag":1434,"props":30000,"children":30001},{},[30002],{"type":46,"tag":55,"props":30003,"children":30004},{},[30005],{"type":52,"value":30006},"The rpt_marketing_roi table shows zero attributed_revenue for Facebook. Query the staging tables to trace where the data is dropping off.",{"type":46,"tag":47,"props":30008,"children":30009},{"id":1531},[30010],{"type":52,"value":1534},{"type":46,"tag":72,"props":30012,"children":30013},{},[30014,30024,30034,30043],{"type":46,"tag":76,"props":30015,"children":30016},{},[30017,30022],{"type":46,"tag":80,"props":30018,"children":30019},{},[30020],{"type":52,"value":30021},"5 report tables",{"type":52,"value":30023}," that turn clean staging data into business metrics",{"type":46,"tag":76,"props":30025,"children":30026},{},[30027,30032],{"type":46,"tag":80,"props":30028,"children":30029},{},[30030],{"type":52,"value":30031},"Three-layer pipeline:",{"type":52,"value":30033}," ingestion, staging, reports - all orchestrated by Bruin",{"type":46,"tag":76,"props":30035,"children":30036},{},[30037,30041],{"type":46,"tag":80,"props":30038,"children":30039},{},[30040],{"type":52,"value":16715},{"type":52,"value":30042}," make sure reports only run after their staging inputs are fresh",{"type":46,"tag":76,"props":30044,"children":30045},{},[30046,30050],{"type":46,"tag":80,"props":30047,"children":30048},{},[30049],{"type":52,"value":8796},{"type":52,"value":30051}," on every report table catch issues before anyone sees bad numbers",{"type":46,"tag":55,"props":30053,"children":30054},{},[30055],{"type":52,"value":30056},"Next, you'll add an AI layer so anyone on your team can query this data in plain language.",{"type":46,"tag":1541,"props":30058,"children":30059},{},[30060],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":30062},[30063,30064,30065,30080],{"id":49,"depth":285,"text":53},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":30066},[30067,30068,30070,30072,30074,30076,30078,30079],{"id":16851,"depth":299,"text":16854},{"id":16888,"depth":299,"text":30069},"1) Daily revenue - rpt_daily_revenue.sql",{"id":18864,"depth":299,"text":30071},"2) Customer cohorts - rpt_customer_cohorts.sql",{"id":21707,"depth":299,"text":30073},"3) Product performance - rpt_product_performance.sql",{"id":21974,"depth":299,"text":30075},"4) Marketing ROI - rpt_marketing_roi.sql",{"id":25947,"depth":299,"text":30077},"5) Daily KPIs - rpt_daily_kpis.sql",{"id":29769,"depth":299,"text":29772},{"id":29961,"depth":299,"text":29964},{"id":1531,"depth":285,"text":1534},"content:tutorials:ecommerce-pipeline:build-reports.md","tutorials\u002Fecommerce-pipeline\u002Fbuild-reports.md","tutorials\u002Fecommerce-pipeline\u002Fbuild-reports",{"_path":30085,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":30086,"description":30087,"date":10,"readingTime":9257,"category":12,"tags":30088,"variants":30091,"difficulty":8788,"module":5,"subSteps":22,"step":820,"journeys":30092,"learnMore":30093,"author":30106,"body":30107,"_type":1560,"_id":32034,"_source":1562,"_file":32035,"_stem":32036,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fai-analyst","Set Up Your AI Data Analyst","Enhance your pipeline with AI-generated metadata, create an ecommerce-specific AGENTS.md, and deploy an AI analyst your team can use locally or in Slack.",[14,15,30089,408,16,17,18,19,30090,20],"Bruin AI","Slack",[17,18,19],[26,27],[30094,30097,30100,30103],{"label":30095,"url":30096},"Bruin MCP best practices","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fgetting-started\u002Fbruin-mcp.html#best-practices-for-ai-agents",{"label":30098,"url":30099},"AI enhance command reference","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fcommands\u002Fai-enhance.html",{"label":30101,"url":30102},"AI Data Analyst module","\u002Flearn\u002Fai-data-analyst",{"label":30104,"url":30105},"Cloud + Slack AI analyst tutorial","\u002Flearn\u002Fcloud-slack",{"name":39,"role":40,"image":41},{"type":43,"children":30108,"toc":32022},[30109,30113,30151,30155,30160,30172,30176,30182,30194,30223,30235,30241,30266,30271,30279,30284,31502,31508,31520,31528,31536,31544,31552,31587,31595,31607,31613,31625,31656,31668,31674,31679,31687,31719,31825,31833,31881,31889,31927,31935,31940,31948,31960,31964,32013,32018],{"type":46,"tag":47,"props":30110,"children":30111},{"id":49},[30112],{"type":52,"value":53},{"type":46,"tag":30114,"props":30115,"children":30116},"ol",{},[30117,30128,30141,30146],{"type":46,"tag":76,"props":30118,"children":30119},{},[30120,30122],{"type":52,"value":30121},"Auto-generate metadata for every asset using ",{"type":46,"tag":99,"props":30123,"children":30125},{"className":30124},[],[30126],{"type":52,"value":30127},"bruin ai enhance",{"type":46,"tag":76,"props":30129,"children":30130},{},[30131,30133,30139],{"type":52,"value":30132},"Create an ",{"type":46,"tag":99,"props":30134,"children":30136},{"className":30135},[],[30137],{"type":52,"value":30138},"AGENTS.md",{"type":52,"value":30140}," with ecommerce-specific context",{"type":46,"tag":76,"props":30142,"children":30143},{},[30144],{"type":52,"value":30145},"Ask your local AI analyst real business questions",{"type":46,"tag":76,"props":30147,"children":30148},{},[30149],{"type":52,"value":30150},"Deploy the analyst to Bruin Cloud so your team can use it in Slack or Teams",{"type":46,"tag":47,"props":30152,"children":30153},{"id":183},[30154],{"type":52,"value":186},{"type":46,"tag":55,"props":30156,"children":30157},{},[30158],{"type":52,"value":30159},"Your pipeline produces clean data and reports, but right now the only way to get answers is to write SQL. The AI analyst lets anyone on your team ask questions in plain language and get answers backed by real data.",{"type":46,"tag":55,"props":30161,"children":30162},{},[30163,30165,30170],{"type":52,"value":30164},"The missing piece is context. A general-purpose AI doesn't know that \"ROAS\" means return on ad spend, that Stripe amounts are in cents, or that guest checkouts have a NULL customer email. The ",{"type":46,"tag":99,"props":30166,"children":30168},{"className":30167},[],[30169],{"type":52,"value":30138},{"type":52,"value":30171}," file fills that gap.",{"type":46,"tag":47,"props":30173,"children":30174},{"id":215},[30175],{"type":52,"value":218},{"type":46,"tag":220,"props":30177,"children":30179},{"id":30178},"_1-enhance-all-assets-with-ai-metadata",[30180],{"type":52,"value":30181},"1) Enhance all assets with AI metadata",{"type":46,"tag":55,"props":30183,"children":30184},{},[30185,30187,30192],{"type":52,"value":30186},"Run ",{"type":46,"tag":99,"props":30188,"children":30190},{"className":30189},[],[30191],{"type":52,"value":30127},{"type":52,"value":30193}," to auto-generate descriptions, column metadata, and quality check suggestions for every asset:",{"type":46,"tag":240,"props":30195,"children":30197},{"className":242,"code":30196,"language":244,"meta":7,"style":7},"bruin ai enhance ecommerce\u002F\n",[30198],{"type":46,"tag":99,"props":30199,"children":30200},{"__ignoreMap":7},[30201],{"type":46,"tag":250,"props":30202,"children":30203},{"class":252,"line":23},[30204,30208,30213,30218],{"type":46,"tag":250,"props":30205,"children":30206},{"style":256},[30207],{"type":52,"value":305},{"type":46,"tag":250,"props":30209,"children":30210},{"style":262},[30211],{"type":52,"value":30212}," ai",{"type":46,"tag":250,"props":30214,"children":30215},{"style":262},[30216],{"type":52,"value":30217}," enhance",{"type":46,"tag":250,"props":30219,"children":30220},{"style":262},[30221],{"type":52,"value":30222}," ecommerce\u002F\n",{"type":46,"tag":55,"props":30224,"children":30225},{},[30226,30228,30233],{"type":52,"value":30227},"This reads your SQL, figures out what each asset does, and writes descriptions into the asset files. Review the output - it's usually accurate but sometimes suggests ",{"type":46,"tag":99,"props":30229,"children":30231},{"className":30230},[],[30232],{"type":52,"value":16698},{"type":52,"value":30234}," checks on columns that aren't actually unique.",{"type":46,"tag":220,"props":30236,"children":30238},{"id":30237},"_2-create-your-agentsmd",[30239],{"type":52,"value":30240},"2) Create your AGENTS.md",{"type":46,"tag":55,"props":30242,"children":30243},{},[30244,30245,30250,30252,30257,30259,30264],{"type":52,"value":30132},{"type":46,"tag":99,"props":30246,"children":30248},{"className":30247},[],[30249],{"type":52,"value":30138},{"type":52,"value":30251}," file at the ",{"type":46,"tag":80,"props":30253,"children":30254},{},[30255],{"type":52,"value":30256},"root of your Bruin project",{"type":52,"value":30258}," - the directory where ",{"type":46,"tag":99,"props":30260,"children":30262},{"className":30261},[],[30263],{"type":52,"value":350},{"type":52,"value":30265}," lives. Claude Code reads this file automatically when it starts a session in your project directory.",{"type":46,"tag":55,"props":30267,"children":30268},{},[30269],{"type":52,"value":30270},"You can ask Claude Code to help draft it:",{"type":46,"tag":1434,"props":30272,"children":30273},{},[30274],{"type":46,"tag":55,"props":30275,"children":30276},{},[30277],{"type":52,"value":30278},"Create an AGENTS.md file for this ecommerce analytics project. Include data access rules using bruin query with the warehouse connection name from our pipeline, a glossary of ecommerce terms (AOV, ROAS, LTV, etc.), and data caveats like Stripe amounts being in cents and guest checkouts having null customer_email.",{"type":46,"tag":55,"props":30280,"children":30281},{},[30282],{"type":52,"value":30283},"Here's what the file should look like. Replace the connection name with the one you set up in Step 1:",{"type":46,"tag":423,"props":30285,"children":30286},{":variants":425,"group":426},[30287,30724,31113],{"type":46,"tag":429,"props":30288,"children":30289},{"v-slot:clickhouse":7},[30290],{"type":46,"tag":240,"props":30291,"children":30294},{"className":30292,"code":30293,"language":1560,"meta":7,"style":7},"language-markdown shiki shiki-themes github-dark","# AGENTS.md\n\n## Data access\n- Use `bruin query --connection clickhouse-default --query \"\u003CSQL>\"` for all data access\n- Always show the SQL query and explain your reasoning before executing it\n- Add `LIMIT 10` to your SQL when exploring unfamiliar tables or testing complex queries\n- Read the `assets\u002F` directory to understand available tables and their schemas before querying\n- This is a **read-only** environment - never run INSERT, UPDATE, DELETE, or DROP statements\n\n\u003C!-- Customize this list to match the sources you actually connected in Step 1.\n     The example below includes Shopify, Stripe, Klaviyo, Facebook Ads, and GA4.\n     Remove any you don't use and add any additional sources (e.g., TikTok Ads, Pinterest, Zendesk). -->\n## Project overview\nThis is an ecommerce analytics pipeline ingesting data from Shopify (orders,\ncustomers, products, inventory), Stripe (payments, refunds, payouts),\nKlaviyo (email campaigns, flows), Facebook Ads (campaigns, ad insights),\nand GA4 (sessions, events) into your data warehouse.\n\nThe pipeline has three layers:\n- **raw.*** - ingested data from SaaS sources (do not query directly for reporting)\n- **staging.*** - cleaned, deduplicated, joined tables\n- **reports.*** - aggregated business metrics and KPIs\n\n## Domain glossary\n- **AOV** - Average Order Value: net revenue divided by number of paid orders\n- **GMV** - Gross Merchandise Value: total order value before returns and discounts\n- **NMV** - Net Merchandise Value: GMV minus returns, cancellations, and discounts\n- **ROAS** - Return on Ad Spend: attributed revenue divided by ad spend\n- **CAC** - Customer Acquisition Cost: total marketing spend divided by new customers\n- **LTV** - Lifetime Value: total revenue from a customer across all orders\n- **Conversion Rate** - percentage of website sessions resulting in a completed purchase\n- **Cart Abandonment** - percentage of sessions with add-to-cart but no purchase\n- **Repeat Purchase Rate** - percentage of customers with more than one order\n- **Churn** - customers with no order in the past 90 days\n- **SKU** - Stock Keeping Unit: unique identifier for a product variant\n- **Basket Size** - number of items in a single order\n\n## Data caveats\n- All timestamps are in **UTC**\n- Stripe amounts are in **cents** - divide by 100 for dollar values\n- `customer_email` is `NULL` for guest checkouts (~15-20% of orders)\n- Refund window is **30 days** - recent revenue figures may be revised downward\n- Inventory data syncs every **4 hours** - not real-time\n- Shopify `order_total` includes tax and shipping; use `subtotal` for product revenue only\n- Facebook Ads data has a **24-48 hour attribution delay**\n- Klaviyo campaigns have no direct spend - they appear with $0 spend in marketing reports\n\n## Query guidelines\n- For revenue, always use **NMV** (net of returns) unless explicitly asked for GMV\n- Exclude test orders: `WHERE customer_email NOT LIKE '%@test.%'`\n- Use a **12-month lookback window** for LTV calculations by default\n- For marketing attribution, use `reports.rpt_marketing_roi` - do not attempt to join raw ad data with orders directly\n- For daily KPIs, use `reports.rpt_daily_kpis` as the single source of truth\n- Prefer `staging.*` tables over `raw.*` for any analysis\n",[30295],{"type":46,"tag":99,"props":30296,"children":30297},{"__ignoreMap":7},[30298,30306,30313,30321,30329,30337,30345,30353,30361,30368,30376,30384,30392,30400,30408,30416,30424,30432,30439,30447,30455,30463,30471,30478,30486,30494,30502,30510,30518,30526,30534,30542,30550,30558,30566,30574,30582,30589,30597,30605,30613,30621,30629,30637,30645,30653,30661,30668,30676,30684,30692,30700,30708,30716],{"type":46,"tag":250,"props":30299,"children":30300},{"class":252,"line":23},[30301],{"type":46,"tag":250,"props":30302,"children":30303},{},[30304],{"type":52,"value":30305},"# AGENTS.md\n",{"type":46,"tag":250,"props":30307,"children":30308},{"class":252,"line":285},[30309],{"type":46,"tag":250,"props":30310,"children":30311},{"emptyLinePlaceholder":22},[30312],{"type":52,"value":9386},{"type":46,"tag":250,"props":30314,"children":30315},{"class":252,"line":299},[30316],{"type":46,"tag":250,"props":30317,"children":30318},{},[30319],{"type":52,"value":30320},"## Data access\n",{"type":46,"tag":250,"props":30322,"children":30323},{"class":252,"line":807},[30324],{"type":46,"tag":250,"props":30325,"children":30326},{},[30327],{"type":52,"value":30328},"- Use `bruin query --connection clickhouse-default --query \"\u003CSQL>\"` for all data access\n",{"type":46,"tag":250,"props":30330,"children":30331},{"class":252,"line":820},[30332],{"type":46,"tag":250,"props":30333,"children":30334},{},[30335],{"type":52,"value":30336},"- Always show the SQL query and explain your reasoning before executing it\n",{"type":46,"tag":250,"props":30338,"children":30339},{"class":252,"line":844},[30340],{"type":46,"tag":250,"props":30341,"children":30342},{},[30343],{"type":52,"value":30344},"- Add `LIMIT 10` to your SQL when exploring unfamiliar tables or testing complex queries\n",{"type":46,"tag":250,"props":30346,"children":30347},{"class":252,"line":862},[30348],{"type":46,"tag":250,"props":30349,"children":30350},{},[30351],{"type":52,"value":30352},"- Read the `assets\u002F` directory to understand available tables and their schemas before querying\n",{"type":46,"tag":250,"props":30354,"children":30355},{"class":252,"line":11},[30356],{"type":46,"tag":250,"props":30357,"children":30358},{},[30359],{"type":52,"value":30360},"- This is a **read-only** environment - never run INSERT, UPDATE, DELETE, or DROP statements\n",{"type":46,"tag":250,"props":30362,"children":30363},{"class":252,"line":4649},[30364],{"type":46,"tag":250,"props":30365,"children":30366},{"emptyLinePlaceholder":22},[30367],{"type":52,"value":9386},{"type":46,"tag":250,"props":30369,"children":30370},{"class":252,"line":9257},[30371],{"type":46,"tag":250,"props":30372,"children":30373},{},[30374],{"type":52,"value":30375},"\u003C!-- Customize this list to match the sources you actually connected in Step 1.\n",{"type":46,"tag":250,"props":30377,"children":30378},{"class":252,"line":9266},[30379],{"type":46,"tag":250,"props":30380,"children":30381},{},[30382],{"type":52,"value":30383},"     The example below includes Shopify, Stripe, Klaviyo, Facebook Ads, and GA4.\n",{"type":46,"tag":250,"props":30385,"children":30386},{"class":252,"line":9275},[30387],{"type":46,"tag":250,"props":30388,"children":30389},{},[30390],{"type":52,"value":30391},"     Remove any you don't use and add any additional sources (e.g., TikTok Ads, Pinterest, Zendesk). -->\n",{"type":46,"tag":250,"props":30393,"children":30394},{"class":252,"line":9284},[30395],{"type":46,"tag":250,"props":30396,"children":30397},{},[30398],{"type":52,"value":30399},"## Project overview\n",{"type":46,"tag":250,"props":30401,"children":30402},{"class":252,"line":9293},[30403],{"type":46,"tag":250,"props":30404,"children":30405},{},[30406],{"type":52,"value":30407},"This is an ecommerce analytics pipeline ingesting data from Shopify (orders,\n",{"type":46,"tag":250,"props":30409,"children":30410},{"class":252,"line":4121},[30411],{"type":46,"tag":250,"props":30412,"children":30413},{},[30414],{"type":52,"value":30415},"customers, products, inventory), Stripe (payments, refunds, payouts),\n",{"type":46,"tag":250,"props":30417,"children":30418},{"class":252,"line":9310},[30419],{"type":46,"tag":250,"props":30420,"children":30421},{},[30422],{"type":52,"value":30423},"Klaviyo (email campaigns, flows), Facebook Ads (campaigns, ad insights),\n",{"type":46,"tag":250,"props":30425,"children":30426},{"class":252,"line":9319},[30427],{"type":46,"tag":250,"props":30428,"children":30429},{},[30430],{"type":52,"value":30431},"and GA4 (sessions, events) into your data warehouse.\n",{"type":46,"tag":250,"props":30433,"children":30434},{"class":252,"line":9327},[30435],{"type":46,"tag":250,"props":30436,"children":30437},{"emptyLinePlaceholder":22},[30438],{"type":52,"value":9386},{"type":46,"tag":250,"props":30440,"children":30441},{"class":252,"line":9335},[30442],{"type":46,"tag":250,"props":30443,"children":30444},{},[30445],{"type":52,"value":30446},"The pipeline has three layers:\n",{"type":46,"tag":250,"props":30448,"children":30449},{"class":252,"line":9344},[30450],{"type":46,"tag":250,"props":30451,"children":30452},{},[30453],{"type":52,"value":30454},"- **raw.*** - ingested data from SaaS sources (do not query directly for reporting)\n",{"type":46,"tag":250,"props":30456,"children":30457},{"class":252,"line":9353},[30458],{"type":46,"tag":250,"props":30459,"children":30460},{},[30461],{"type":52,"value":30462},"- **staging.*** - cleaned, deduplicated, joined tables\n",{"type":46,"tag":250,"props":30464,"children":30465},{"class":252,"line":9362},[30466],{"type":46,"tag":250,"props":30467,"children":30468},{},[30469],{"type":52,"value":30470},"- **reports.*** - aggregated business metrics and KPIs\n",{"type":46,"tag":250,"props":30472,"children":30473},{"class":252,"line":9371},[30474],{"type":46,"tag":250,"props":30475,"children":30476},{"emptyLinePlaceholder":22},[30477],{"type":52,"value":9386},{"type":46,"tag":250,"props":30479,"children":30480},{"class":252,"line":9380},[30481],{"type":46,"tag":250,"props":30482,"children":30483},{},[30484],{"type":52,"value":30485},"## Domain glossary\n",{"type":46,"tag":250,"props":30487,"children":30488},{"class":252,"line":9389},[30489],{"type":46,"tag":250,"props":30490,"children":30491},{},[30492],{"type":52,"value":30493},"- **AOV** - Average Order Value: net revenue divided by number of paid orders\n",{"type":46,"tag":250,"props":30495,"children":30496},{"class":252,"line":9398},[30497],{"type":46,"tag":250,"props":30498,"children":30499},{},[30500],{"type":52,"value":30501},"- **GMV** - Gross Merchandise Value: total order value before returns and discounts\n",{"type":46,"tag":250,"props":30503,"children":30504},{"class":252,"line":9426},[30505],{"type":46,"tag":250,"props":30506,"children":30507},{},[30508],{"type":52,"value":30509},"- **NMV** - Net Merchandise Value: GMV minus returns, cancellations, and discounts\n",{"type":46,"tag":250,"props":30511,"children":30512},{"class":252,"line":9448},[30513],{"type":46,"tag":250,"props":30514,"children":30515},{},[30516],{"type":52,"value":30517},"- **ROAS** - Return on Ad Spend: attributed revenue divided by ad spend\n",{"type":46,"tag":250,"props":30519,"children":30520},{"class":252,"line":9474},[30521],{"type":46,"tag":250,"props":30522,"children":30523},{},[30524],{"type":52,"value":30525},"- **CAC** - Customer Acquisition Cost: total marketing spend divided by new customers\n",{"type":46,"tag":250,"props":30527,"children":30528},{"class":252,"line":9500},[30529],{"type":46,"tag":250,"props":30530,"children":30531},{},[30532],{"type":52,"value":30533},"- **LTV** - Lifetime Value: total revenue from a customer across all orders\n",{"type":46,"tag":250,"props":30535,"children":30536},{"class":252,"line":9525},[30537],{"type":46,"tag":250,"props":30538,"children":30539},{},[30540],{"type":52,"value":30541},"- **Conversion Rate** - percentage of website sessions resulting in a completed purchase\n",{"type":46,"tag":250,"props":30543,"children":30544},{"class":252,"line":9546},[30545],{"type":46,"tag":250,"props":30546,"children":30547},{},[30548],{"type":52,"value":30549},"- **Cart Abandonment** - percentage of sessions with add-to-cart but no purchase\n",{"type":46,"tag":250,"props":30551,"children":30552},{"class":252,"line":9616},[30553],{"type":46,"tag":250,"props":30554,"children":30555},{},[30556],{"type":52,"value":30557},"- **Repeat Purchase Rate** - percentage of customers with more than one order\n",{"type":46,"tag":250,"props":30559,"children":30560},{"class":252,"line":9678},[30561],{"type":46,"tag":250,"props":30562,"children":30563},{},[30564],{"type":52,"value":30565},"- **Churn** - customers with no order in the past 90 days\n",{"type":46,"tag":250,"props":30567,"children":30568},{"class":252,"line":9740},[30569],{"type":46,"tag":250,"props":30570,"children":30571},{},[30572],{"type":52,"value":30573},"- **SKU** - Stock Keeping Unit: unique identifier for a product variant\n",{"type":46,"tag":250,"props":30575,"children":30576},{"class":252,"line":9802},[30577],{"type":46,"tag":250,"props":30578,"children":30579},{},[30580],{"type":52,"value":30581},"- **Basket Size** - number of items in a single order\n",{"type":46,"tag":250,"props":30583,"children":30584},{"class":252,"line":9823},[30585],{"type":46,"tag":250,"props":30586,"children":30587},{"emptyLinePlaceholder":22},[30588],{"type":52,"value":9386},{"type":46,"tag":250,"props":30590,"children":30591},{"class":252,"line":9844},[30592],{"type":46,"tag":250,"props":30593,"children":30594},{},[30595],{"type":52,"value":30596},"## Data caveats\n",{"type":46,"tag":250,"props":30598,"children":30599},{"class":252,"line":9865},[30600],{"type":46,"tag":250,"props":30601,"children":30602},{},[30603],{"type":52,"value":30604},"- All timestamps are in **UTC**\n",{"type":46,"tag":250,"props":30606,"children":30607},{"class":252,"line":9911},[30608],{"type":46,"tag":250,"props":30609,"children":30610},{},[30611],{"type":52,"value":30612},"- Stripe amounts are in **cents** - divide by 100 for dollar values\n",{"type":46,"tag":250,"props":30614,"children":30615},{"class":252,"line":9937},[30616],{"type":46,"tag":250,"props":30617,"children":30618},{},[30619],{"type":52,"value":30620},"- `customer_email` is `NULL` for guest checkouts (~15-20% of orders)\n",{"type":46,"tag":250,"props":30622,"children":30623},{"class":252,"line":9963},[30624],{"type":46,"tag":250,"props":30625,"children":30626},{},[30627],{"type":52,"value":30628},"- Refund window is **30 days** - recent revenue figures may be revised downward\n",{"type":46,"tag":250,"props":30630,"children":30631},{"class":252,"line":9991},[30632],{"type":46,"tag":250,"props":30633,"children":30634},{},[30635],{"type":52,"value":30636},"- Inventory data syncs every **4 hours** - not real-time\n",{"type":46,"tag":250,"props":30638,"children":30639},{"class":252,"line":10017},[30640],{"type":46,"tag":250,"props":30641,"children":30642},{},[30643],{"type":52,"value":30644},"- Shopify `order_total` includes tax and shipping; use `subtotal` for product revenue only\n",{"type":46,"tag":250,"props":30646,"children":30647},{"class":252,"line":10058},[30648],{"type":46,"tag":250,"props":30649,"children":30650},{},[30651],{"type":52,"value":30652},"- Facebook Ads data has a **24-48 hour attribution delay**\n",{"type":46,"tag":250,"props":30654,"children":30655},{"class":252,"line":10936},[30656],{"type":46,"tag":250,"props":30657,"children":30658},{},[30659],{"type":52,"value":30660},"- Klaviyo campaigns have no direct spend - they appear with $0 spend in marketing reports\n",{"type":46,"tag":250,"props":30662,"children":30663},{"class":252,"line":10995},[30664],{"type":46,"tag":250,"props":30665,"children":30666},{"emptyLinePlaceholder":22},[30667],{"type":52,"value":9386},{"type":46,"tag":250,"props":30669,"children":30670},{"class":252,"line":22686},[30671],{"type":46,"tag":250,"props":30672,"children":30673},{},[30674],{"type":52,"value":30675},"## Query guidelines\n",{"type":46,"tag":250,"props":30677,"children":30678},{"class":252,"line":22694},[30679],{"type":46,"tag":250,"props":30680,"children":30681},{},[30682],{"type":52,"value":30683},"- For revenue, always use **NMV** (net of returns) unless explicitly asked for GMV\n",{"type":46,"tag":250,"props":30685,"children":30686},{"class":252,"line":22702},[30687],{"type":46,"tag":250,"props":30688,"children":30689},{},[30690],{"type":52,"value":30691},"- Exclude test orders: `WHERE customer_email NOT LIKE '%@test.%'`\n",{"type":46,"tag":250,"props":30693,"children":30694},{"class":252,"line":22728},[30695],{"type":46,"tag":250,"props":30696,"children":30697},{},[30698],{"type":52,"value":30699},"- Use a **12-month lookback window** for LTV calculations by default\n",{"type":46,"tag":250,"props":30701,"children":30702},{"class":252,"line":22748},[30703],{"type":46,"tag":250,"props":30704,"children":30705},{},[30706],{"type":52,"value":30707},"- For marketing attribution, use `reports.rpt_marketing_roi` - do not attempt to join raw ad data with orders directly\n",{"type":46,"tag":250,"props":30709,"children":30710},{"class":252,"line":22769},[30711],{"type":46,"tag":250,"props":30712,"children":30713},{},[30714],{"type":52,"value":30715},"- For daily KPIs, use `reports.rpt_daily_kpis` as the single source of truth\n",{"type":46,"tag":250,"props":30717,"children":30718},{"class":252,"line":22790},[30719],{"type":46,"tag":250,"props":30720,"children":30721},{},[30722],{"type":52,"value":30723},"- Prefer `staging.*` tables over `raw.*` for any analysis\n",{"type":46,"tag":429,"props":30725,"children":30726},{"v-slot:bigquery":7},[30727],{"type":46,"tag":240,"props":30728,"children":30730},{"className":30292,"code":30729,"language":1560,"meta":7,"style":7},"# AGENTS.md\n\n## Data access\n- Use `bruin query --connection bigquery-default --query \"\u003CSQL>\"` for all data access\n- Always show the SQL query and explain your reasoning before executing it\n- Add `LIMIT 10` to your SQL when exploring unfamiliar tables or testing complex queries\n- Read the `assets\u002F` directory to understand available tables and their schemas before querying\n- This is a **read-only** environment - never run INSERT, UPDATE, DELETE, or DROP statements\n\n\u003C!-- Customize this list to match the sources you actually connected in Step 1.\n     The example below includes Shopify, Stripe, Klaviyo, Facebook Ads, and GA4.\n     Remove any you don't use and add any additional sources (e.g., TikTok Ads, Pinterest, Zendesk). -->\n## Project overview\nThis is an ecommerce analytics pipeline ingesting data from Shopify (orders,\ncustomers, products, inventory), Stripe (payments, refunds, payouts),\nKlaviyo (email campaigns, flows), Facebook Ads (campaigns, ad insights),\nand GA4 (sessions, events) into your data warehouse.\n\nThe pipeline has three layers:\n- **raw.*** - ingested data from SaaS sources (do not query directly for reporting)\n- **staging.*** - cleaned, deduplicated, joined tables\n- **reports.*** - aggregated business metrics and KPIs\n\n## Domain glossary\n- **AOV** - Average Order Value: net revenue divided by number of paid orders\n- **GMV** - Gross Merchandise Value: total order value before returns and discounts\n- **NMV** - Net Merchandise Value: GMV minus returns, cancellations, and discounts\n- **ROAS** - Return on Ad Spend: attributed revenue divided by ad spend\n- **CAC** - Customer Acquisition Cost: total marketing spend divided by new customers\n- **LTV** - Lifetime Value: total revenue from a customer across all orders\n- **Conversion Rate** - percentage of website sessions resulting in a completed purchase\n- **Cart Abandonment** - percentage of sessions with add-to-cart but no purchase\n- **Repeat Purchase Rate** - percentage of customers with more than one order\n- **Churn** - customers with no order in the past 90 days\n- **SKU** - Stock Keeping Unit: unique identifier for a product variant\n- **Basket Size** - number of items in a single order\n\n## Data caveats\n- All timestamps are in **UTC**\n- Stripe amounts are in **cents** - divide by 100 for dollar values\n- `customer_email` is `NULL` for guest checkouts (~15-20% of orders)\n- Refund window is **30 days** - recent revenue figures may be revised downward\n- Inventory data syncs every **4 hours** - not real-time\n- Shopify `order_total` includes tax and shipping; use `subtotal` for product revenue only\n- Facebook Ads data has a **24-48 hour attribution delay**\n- Klaviyo campaigns have no direct spend - they appear with $0 spend in marketing reports\n\n## Query guidelines\n- For revenue, always use **NMV** (net of returns) unless explicitly asked for GMV\n- Exclude test orders: `WHERE customer_email NOT LIKE '%@test.%'`\n- Use a **12-month lookback window** for LTV calculations by default\n- For marketing attribution, use `reports.rpt_marketing_roi` - do not attempt to join raw ad data with orders directly\n- For daily KPIs, use `reports.rpt_daily_kpis` as the single source of truth\n- Prefer `staging.*` tables over `raw.*` for any analysis\n",[30731],{"type":46,"tag":99,"props":30732,"children":30733},{"__ignoreMap":7},[30734,30741,30748,30755,30763,30770,30777,30784,30791,30798,30805,30812,30819,30826,30833,30840,30847,30854,30861,30868,30875,30882,30889,30896,30903,30910,30917,30924,30931,30938,30945,30952,30959,30966,30973,30980,30987,30994,31001,31008,31015,31022,31029,31036,31043,31050,31057,31064,31071,31078,31085,31092,31099,31106],{"type":46,"tag":250,"props":30735,"children":30736},{"class":252,"line":23},[30737],{"type":46,"tag":250,"props":30738,"children":30739},{},[30740],{"type":52,"value":30305},{"type":46,"tag":250,"props":30742,"children":30743},{"class":252,"line":285},[30744],{"type":46,"tag":250,"props":30745,"children":30746},{"emptyLinePlaceholder":22},[30747],{"type":52,"value":9386},{"type":46,"tag":250,"props":30749,"children":30750},{"class":252,"line":299},[30751],{"type":46,"tag":250,"props":30752,"children":30753},{},[30754],{"type":52,"value":30320},{"type":46,"tag":250,"props":30756,"children":30757},{"class":252,"line":807},[30758],{"type":46,"tag":250,"props":30759,"children":30760},{},[30761],{"type":52,"value":30762},"- Use `bruin query --connection bigquery-default --query \"\u003CSQL>\"` for all data access\n",{"type":46,"tag":250,"props":30764,"children":30765},{"class":252,"line":820},[30766],{"type":46,"tag":250,"props":30767,"children":30768},{},[30769],{"type":52,"value":30336},{"type":46,"tag":250,"props":30771,"children":30772},{"class":252,"line":844},[30773],{"type":46,"tag":250,"props":30774,"children":30775},{},[30776],{"type":52,"value":30344},{"type":46,"tag":250,"props":30778,"children":30779},{"class":252,"line":862},[30780],{"type":46,"tag":250,"props":30781,"children":30782},{},[30783],{"type":52,"value":30352},{"type":46,"tag":250,"props":30785,"children":30786},{"class":252,"line":11},[30787],{"type":46,"tag":250,"props":30788,"children":30789},{},[30790],{"type":52,"value":30360},{"type":46,"tag":250,"props":30792,"children":30793},{"class":252,"line":4649},[30794],{"type":46,"tag":250,"props":30795,"children":30796},{"emptyLinePlaceholder":22},[30797],{"type":52,"value":9386},{"type":46,"tag":250,"props":30799,"children":30800},{"class":252,"line":9257},[30801],{"type":46,"tag":250,"props":30802,"children":30803},{},[30804],{"type":52,"value":30375},{"type":46,"tag":250,"props":30806,"children":30807},{"class":252,"line":9266},[30808],{"type":46,"tag":250,"props":30809,"children":30810},{},[30811],{"type":52,"value":30383},{"type":46,"tag":250,"props":30813,"children":30814},{"class":252,"line":9275},[30815],{"type":46,"tag":250,"props":30816,"children":30817},{},[30818],{"type":52,"value":30391},{"type":46,"tag":250,"props":30820,"children":30821},{"class":252,"line":9284},[30822],{"type":46,"tag":250,"props":30823,"children":30824},{},[30825],{"type":52,"value":30399},{"type":46,"tag":250,"props":30827,"children":30828},{"class":252,"line":9293},[30829],{"type":46,"tag":250,"props":30830,"children":30831},{},[30832],{"type":52,"value":30407},{"type":46,"tag":250,"props":30834,"children":30835},{"class":252,"line":4121},[30836],{"type":46,"tag":250,"props":30837,"children":30838},{},[30839],{"type":52,"value":30415},{"type":46,"tag":250,"props":30841,"children":30842},{"class":252,"line":9310},[30843],{"type":46,"tag":250,"props":30844,"children":30845},{},[30846],{"type":52,"value":30423},{"type":46,"tag":250,"props":30848,"children":30849},{"class":252,"line":9319},[30850],{"type":46,"tag":250,"props":30851,"children":30852},{},[30853],{"type":52,"value":30431},{"type":46,"tag":250,"props":30855,"children":30856},{"class":252,"line":9327},[30857],{"type":46,"tag":250,"props":30858,"children":30859},{"emptyLinePlaceholder":22},[30860],{"type":52,"value":9386},{"type":46,"tag":250,"props":30862,"children":30863},{"class":252,"line":9335},[30864],{"type":46,"tag":250,"props":30865,"children":30866},{},[30867],{"type":52,"value":30446},{"type":46,"tag":250,"props":30869,"children":30870},{"class":252,"line":9344},[30871],{"type":46,"tag":250,"props":30872,"children":30873},{},[30874],{"type":52,"value":30454},{"type":46,"tag":250,"props":30876,"children":30877},{"class":252,"line":9353},[30878],{"type":46,"tag":250,"props":30879,"children":30880},{},[30881],{"type":52,"value":30462},{"type":46,"tag":250,"props":30883,"children":30884},{"class":252,"line":9362},[30885],{"type":46,"tag":250,"props":30886,"children":30887},{},[30888],{"type":52,"value":30470},{"type":46,"tag":250,"props":30890,"children":30891},{"class":252,"line":9371},[30892],{"type":46,"tag":250,"props":30893,"children":30894},{"emptyLinePlaceholder":22},[30895],{"type":52,"value":9386},{"type":46,"tag":250,"props":30897,"children":30898},{"class":252,"line":9380},[30899],{"type":46,"tag":250,"props":30900,"children":30901},{},[30902],{"type":52,"value":30485},{"type":46,"tag":250,"props":30904,"children":30905},{"class":252,"line":9389},[30906],{"type":46,"tag":250,"props":30907,"children":30908},{},[30909],{"type":52,"value":30493},{"type":46,"tag":250,"props":30911,"children":30912},{"class":252,"line":9398},[30913],{"type":46,"tag":250,"props":30914,"children":30915},{},[30916],{"type":52,"value":30501},{"type":46,"tag":250,"props":30918,"children":30919},{"class":252,"line":9426},[30920],{"type":46,"tag":250,"props":30921,"children":30922},{},[30923],{"type":52,"value":30509},{"type":46,"tag":250,"props":30925,"children":30926},{"class":252,"line":9448},[30927],{"type":46,"tag":250,"props":30928,"children":30929},{},[30930],{"type":52,"value":30517},{"type":46,"tag":250,"props":30932,"children":30933},{"class":252,"line":9474},[30934],{"type":46,"tag":250,"props":30935,"children":30936},{},[30937],{"type":52,"value":30525},{"type":46,"tag":250,"props":30939,"children":30940},{"class":252,"line":9500},[30941],{"type":46,"tag":250,"props":30942,"children":30943},{},[30944],{"type":52,"value":30533},{"type":46,"tag":250,"props":30946,"children":30947},{"class":252,"line":9525},[30948],{"type":46,"tag":250,"props":30949,"children":30950},{},[30951],{"type":52,"value":30541},{"type":46,"tag":250,"props":30953,"children":30954},{"class":252,"line":9546},[30955],{"type":46,"tag":250,"props":30956,"children":30957},{},[30958],{"type":52,"value":30549},{"type":46,"tag":250,"props":30960,"children":30961},{"class":252,"line":9616},[30962],{"type":46,"tag":250,"props":30963,"children":30964},{},[30965],{"type":52,"value":30557},{"type":46,"tag":250,"props":30967,"children":30968},{"class":252,"line":9678},[30969],{"type":46,"tag":250,"props":30970,"children":30971},{},[30972],{"type":52,"value":30565},{"type":46,"tag":250,"props":30974,"children":30975},{"class":252,"line":9740},[30976],{"type":46,"tag":250,"props":30977,"children":30978},{},[30979],{"type":52,"value":30573},{"type":46,"tag":250,"props":30981,"children":30982},{"class":252,"line":9802},[30983],{"type":46,"tag":250,"props":30984,"children":30985},{},[30986],{"type":52,"value":30581},{"type":46,"tag":250,"props":30988,"children":30989},{"class":252,"line":9823},[30990],{"type":46,"tag":250,"props":30991,"children":30992},{"emptyLinePlaceholder":22},[30993],{"type":52,"value":9386},{"type":46,"tag":250,"props":30995,"children":30996},{"class":252,"line":9844},[30997],{"type":46,"tag":250,"props":30998,"children":30999},{},[31000],{"type":52,"value":30596},{"type":46,"tag":250,"props":31002,"children":31003},{"class":252,"line":9865},[31004],{"type":46,"tag":250,"props":31005,"children":31006},{},[31007],{"type":52,"value":30604},{"type":46,"tag":250,"props":31009,"children":31010},{"class":252,"line":9911},[31011],{"type":46,"tag":250,"props":31012,"children":31013},{},[31014],{"type":52,"value":30612},{"type":46,"tag":250,"props":31016,"children":31017},{"class":252,"line":9937},[31018],{"type":46,"tag":250,"props":31019,"children":31020},{},[31021],{"type":52,"value":30620},{"type":46,"tag":250,"props":31023,"children":31024},{"class":252,"line":9963},[31025],{"type":46,"tag":250,"props":31026,"children":31027},{},[31028],{"type":52,"value":30628},{"type":46,"tag":250,"props":31030,"children":31031},{"class":252,"line":9991},[31032],{"type":46,"tag":250,"props":31033,"children":31034},{},[31035],{"type":52,"value":30636},{"type":46,"tag":250,"props":31037,"children":31038},{"class":252,"line":10017},[31039],{"type":46,"tag":250,"props":31040,"children":31041},{},[31042],{"type":52,"value":30644},{"type":46,"tag":250,"props":31044,"children":31045},{"class":252,"line":10058},[31046],{"type":46,"tag":250,"props":31047,"children":31048},{},[31049],{"type":52,"value":30652},{"type":46,"tag":250,"props":31051,"children":31052},{"class":252,"line":10936},[31053],{"type":46,"tag":250,"props":31054,"children":31055},{},[31056],{"type":52,"value":30660},{"type":46,"tag":250,"props":31058,"children":31059},{"class":252,"line":10995},[31060],{"type":46,"tag":250,"props":31061,"children":31062},{"emptyLinePlaceholder":22},[31063],{"type":52,"value":9386},{"type":46,"tag":250,"props":31065,"children":31066},{"class":252,"line":22686},[31067],{"type":46,"tag":250,"props":31068,"children":31069},{},[31070],{"type":52,"value":30675},{"type":46,"tag":250,"props":31072,"children":31073},{"class":252,"line":22694},[31074],{"type":46,"tag":250,"props":31075,"children":31076},{},[31077],{"type":52,"value":30683},{"type":46,"tag":250,"props":31079,"children":31080},{"class":252,"line":22702},[31081],{"type":46,"tag":250,"props":31082,"children":31083},{},[31084],{"type":52,"value":30691},{"type":46,"tag":250,"props":31086,"children":31087},{"class":252,"line":22728},[31088],{"type":46,"tag":250,"props":31089,"children":31090},{},[31091],{"type":52,"value":30699},{"type":46,"tag":250,"props":31093,"children":31094},{"class":252,"line":22748},[31095],{"type":46,"tag":250,"props":31096,"children":31097},{},[31098],{"type":52,"value":30707},{"type":46,"tag":250,"props":31100,"children":31101},{"class":252,"line":22769},[31102],{"type":46,"tag":250,"props":31103,"children":31104},{},[31105],{"type":52,"value":30715},{"type":46,"tag":250,"props":31107,"children":31108},{"class":252,"line":22790},[31109],{"type":46,"tag":250,"props":31110,"children":31111},{},[31112],{"type":52,"value":30723},{"type":46,"tag":429,"props":31114,"children":31115},{"v-slot:snowflake":7},[31116],{"type":46,"tag":240,"props":31117,"children":31119},{"className":30292,"code":31118,"language":1560,"meta":7,"style":7},"# AGENTS.md\n\n## Data access\n- Use `bruin query --connection snowflake-default --query \"\u003CSQL>\"` for all data access\n- Always show the SQL query and explain your reasoning before executing it\n- Add `LIMIT 10` to your SQL when exploring unfamiliar tables or testing complex queries\n- Read the `assets\u002F` directory to understand available tables and their schemas before querying\n- This is a **read-only** environment - never run INSERT, UPDATE, DELETE, or DROP statements\n\n\u003C!-- Customize this list to match the sources you actually connected in Step 1.\n     The example below includes Shopify, Stripe, Klaviyo, Facebook Ads, and GA4.\n     Remove any you don't use and add any additional sources (e.g., TikTok Ads, Pinterest, Zendesk). -->\n## Project overview\nThis is an ecommerce analytics pipeline ingesting data from Shopify (orders,\ncustomers, products, inventory), Stripe (payments, refunds, payouts),\nKlaviyo (email campaigns, flows), Facebook Ads (campaigns, ad insights),\nand GA4 (sessions, events) into your data warehouse.\n\nThe pipeline has three layers:\n- **raw.*** - ingested data from SaaS sources (do not query directly for reporting)\n- **staging.*** - cleaned, deduplicated, joined tables\n- **reports.*** - aggregated business metrics and KPIs\n\n## Domain glossary\n- **AOV** - Average Order Value: net revenue divided by number of paid orders\n- **GMV** - Gross Merchandise Value: total order value before returns and discounts\n- **NMV** - Net Merchandise Value: GMV minus returns, cancellations, and discounts\n- **ROAS** - Return on Ad Spend: attributed revenue divided by ad spend\n- **CAC** - Customer Acquisition Cost: total marketing spend divided by new customers\n- **LTV** - Lifetime Value: total revenue from a customer across all orders\n- **Conversion Rate** - percentage of website sessions resulting in a completed purchase\n- **Cart Abandonment** - percentage of sessions with add-to-cart but no purchase\n- **Repeat Purchase Rate** - percentage of customers with more than one order\n- **Churn** - customers with no order in the past 90 days\n- **SKU** - Stock Keeping Unit: unique identifier for a product variant\n- **Basket Size** - number of items in a single order\n\n## Data caveats\n- All timestamps are in **UTC**\n- Stripe amounts are in **cents** - divide by 100 for dollar values\n- `customer_email` is `NULL` for guest checkouts (~15-20% of orders)\n- Refund window is **30 days** - recent revenue figures may be revised downward\n- Inventory data syncs every **4 hours** - not real-time\n- Shopify `order_total` includes tax and shipping; use `subtotal` for product revenue only\n- Facebook Ads data has a **24-48 hour attribution delay**\n- Klaviyo campaigns have no direct spend - they appear with $0 spend in marketing reports\n\n## Query guidelines\n- For revenue, always use **NMV** (net of returns) unless explicitly asked for GMV\n- Exclude test orders: `WHERE customer_email NOT LIKE '%@test.%'`\n- Use a **12-month lookback window** for LTV calculations by default\n- For marketing attribution, use `reports.rpt_marketing_roi` - do not attempt to join raw ad data with orders directly\n- For daily KPIs, use `reports.rpt_daily_kpis` as the single source of truth\n- Prefer `staging.*` tables over `raw.*` for any analysis\n",[31120],{"type":46,"tag":99,"props":31121,"children":31122},{"__ignoreMap":7},[31123,31130,31137,31144,31152,31159,31166,31173,31180,31187,31194,31201,31208,31215,31222,31229,31236,31243,31250,31257,31264,31271,31278,31285,31292,31299,31306,31313,31320,31327,31334,31341,31348,31355,31362,31369,31376,31383,31390,31397,31404,31411,31418,31425,31432,31439,31446,31453,31460,31467,31474,31481,31488,31495],{"type":46,"tag":250,"props":31124,"children":31125},{"class":252,"line":23},[31126],{"type":46,"tag":250,"props":31127,"children":31128},{},[31129],{"type":52,"value":30305},{"type":46,"tag":250,"props":31131,"children":31132},{"class":252,"line":285},[31133],{"type":46,"tag":250,"props":31134,"children":31135},{"emptyLinePlaceholder":22},[31136],{"type":52,"value":9386},{"type":46,"tag":250,"props":31138,"children":31139},{"class":252,"line":299},[31140],{"type":46,"tag":250,"props":31141,"children":31142},{},[31143],{"type":52,"value":30320},{"type":46,"tag":250,"props":31145,"children":31146},{"class":252,"line":807},[31147],{"type":46,"tag":250,"props":31148,"children":31149},{},[31150],{"type":52,"value":31151},"- Use `bruin query --connection snowflake-default --query \"\u003CSQL>\"` for all data access\n",{"type":46,"tag":250,"props":31153,"children":31154},{"class":252,"line":820},[31155],{"type":46,"tag":250,"props":31156,"children":31157},{},[31158],{"type":52,"value":30336},{"type":46,"tag":250,"props":31160,"children":31161},{"class":252,"line":844},[31162],{"type":46,"tag":250,"props":31163,"children":31164},{},[31165],{"type":52,"value":30344},{"type":46,"tag":250,"props":31167,"children":31168},{"class":252,"line":862},[31169],{"type":46,"tag":250,"props":31170,"children":31171},{},[31172],{"type":52,"value":30352},{"type":46,"tag":250,"props":31174,"children":31175},{"class":252,"line":11},[31176],{"type":46,"tag":250,"props":31177,"children":31178},{},[31179],{"type":52,"value":30360},{"type":46,"tag":250,"props":31181,"children":31182},{"class":252,"line":4649},[31183],{"type":46,"tag":250,"props":31184,"children":31185},{"emptyLinePlaceholder":22},[31186],{"type":52,"value":9386},{"type":46,"tag":250,"props":31188,"children":31189},{"class":252,"line":9257},[31190],{"type":46,"tag":250,"props":31191,"children":31192},{},[31193],{"type":52,"value":30375},{"type":46,"tag":250,"props":31195,"children":31196},{"class":252,"line":9266},[31197],{"type":46,"tag":250,"props":31198,"children":31199},{},[31200],{"type":52,"value":30383},{"type":46,"tag":250,"props":31202,"children":31203},{"class":252,"line":9275},[31204],{"type":46,"tag":250,"props":31205,"children":31206},{},[31207],{"type":52,"value":30391},{"type":46,"tag":250,"props":31209,"children":31210},{"class":252,"line":9284},[31211],{"type":46,"tag":250,"props":31212,"children":31213},{},[31214],{"type":52,"value":30399},{"type":46,"tag":250,"props":31216,"children":31217},{"class":252,"line":9293},[31218],{"type":46,"tag":250,"props":31219,"children":31220},{},[31221],{"type":52,"value":30407},{"type":46,"tag":250,"props":31223,"children":31224},{"class":252,"line":4121},[31225],{"type":46,"tag":250,"props":31226,"children":31227},{},[31228],{"type":52,"value":30415},{"type":46,"tag":250,"props":31230,"children":31231},{"class":252,"line":9310},[31232],{"type":46,"tag":250,"props":31233,"children":31234},{},[31235],{"type":52,"value":30423},{"type":46,"tag":250,"props":31237,"children":31238},{"class":252,"line":9319},[31239],{"type":46,"tag":250,"props":31240,"children":31241},{},[31242],{"type":52,"value":30431},{"type":46,"tag":250,"props":31244,"children":31245},{"class":252,"line":9327},[31246],{"type":46,"tag":250,"props":31247,"children":31248},{"emptyLinePlaceholder":22},[31249],{"type":52,"value":9386},{"type":46,"tag":250,"props":31251,"children":31252},{"class":252,"line":9335},[31253],{"type":46,"tag":250,"props":31254,"children":31255},{},[31256],{"type":52,"value":30446},{"type":46,"tag":250,"props":31258,"children":31259},{"class":252,"line":9344},[31260],{"type":46,"tag":250,"props":31261,"children":31262},{},[31263],{"type":52,"value":30454},{"type":46,"tag":250,"props":31265,"children":31266},{"class":252,"line":9353},[31267],{"type":46,"tag":250,"props":31268,"children":31269},{},[31270],{"type":52,"value":30462},{"type":46,"tag":250,"props":31272,"children":31273},{"class":252,"line":9362},[31274],{"type":46,"tag":250,"props":31275,"children":31276},{},[31277],{"type":52,"value":30470},{"type":46,"tag":250,"props":31279,"children":31280},{"class":252,"line":9371},[31281],{"type":46,"tag":250,"props":31282,"children":31283},{"emptyLinePlaceholder":22},[31284],{"type":52,"value":9386},{"type":46,"tag":250,"props":31286,"children":31287},{"class":252,"line":9380},[31288],{"type":46,"tag":250,"props":31289,"children":31290},{},[31291],{"type":52,"value":30485},{"type":46,"tag":250,"props":31293,"children":31294},{"class":252,"line":9389},[31295],{"type":46,"tag":250,"props":31296,"children":31297},{},[31298],{"type":52,"value":30493},{"type":46,"tag":250,"props":31300,"children":31301},{"class":252,"line":9398},[31302],{"type":46,"tag":250,"props":31303,"children":31304},{},[31305],{"type":52,"value":30501},{"type":46,"tag":250,"props":31307,"children":31308},{"class":252,"line":9426},[31309],{"type":46,"tag":250,"props":31310,"children":31311},{},[31312],{"type":52,"value":30509},{"type":46,"tag":250,"props":31314,"children":31315},{"class":252,"line":9448},[31316],{"type":46,"tag":250,"props":31317,"children":31318},{},[31319],{"type":52,"value":30517},{"type":46,"tag":250,"props":31321,"children":31322},{"class":252,"line":9474},[31323],{"type":46,"tag":250,"props":31324,"children":31325},{},[31326],{"type":52,"value":30525},{"type":46,"tag":250,"props":31328,"children":31329},{"class":252,"line":9500},[31330],{"type":46,"tag":250,"props":31331,"children":31332},{},[31333],{"type":52,"value":30533},{"type":46,"tag":250,"props":31335,"children":31336},{"class":252,"line":9525},[31337],{"type":46,"tag":250,"props":31338,"children":31339},{},[31340],{"type":52,"value":30541},{"type":46,"tag":250,"props":31342,"children":31343},{"class":252,"line":9546},[31344],{"type":46,"tag":250,"props":31345,"children":31346},{},[31347],{"type":52,"value":30549},{"type":46,"tag":250,"props":31349,"children":31350},{"class":252,"line":9616},[31351],{"type":46,"tag":250,"props":31352,"children":31353},{},[31354],{"type":52,"value":30557},{"type":46,"tag":250,"props":31356,"children":31357},{"class":252,"line":9678},[31358],{"type":46,"tag":250,"props":31359,"children":31360},{},[31361],{"type":52,"value":30565},{"type":46,"tag":250,"props":31363,"children":31364},{"class":252,"line":9740},[31365],{"type":46,"tag":250,"props":31366,"children":31367},{},[31368],{"type":52,"value":30573},{"type":46,"tag":250,"props":31370,"children":31371},{"class":252,"line":9802},[31372],{"type":46,"tag":250,"props":31373,"children":31374},{},[31375],{"type":52,"value":30581},{"type":46,"tag":250,"props":31377,"children":31378},{"class":252,"line":9823},[31379],{"type":46,"tag":250,"props":31380,"children":31381},{"emptyLinePlaceholder":22},[31382],{"type":52,"value":9386},{"type":46,"tag":250,"props":31384,"children":31385},{"class":252,"line":9844},[31386],{"type":46,"tag":250,"props":31387,"children":31388},{},[31389],{"type":52,"value":30596},{"type":46,"tag":250,"props":31391,"children":31392},{"class":252,"line":9865},[31393],{"type":46,"tag":250,"props":31394,"children":31395},{},[31396],{"type":52,"value":30604},{"type":46,"tag":250,"props":31398,"children":31399},{"class":252,"line":9911},[31400],{"type":46,"tag":250,"props":31401,"children":31402},{},[31403],{"type":52,"value":30612},{"type":46,"tag":250,"props":31405,"children":31406},{"class":252,"line":9937},[31407],{"type":46,"tag":250,"props":31408,"children":31409},{},[31410],{"type":52,"value":30620},{"type":46,"tag":250,"props":31412,"children":31413},{"class":252,"line":9963},[31414],{"type":46,"tag":250,"props":31415,"children":31416},{},[31417],{"type":52,"value":30628},{"type":46,"tag":250,"props":31419,"children":31420},{"class":252,"line":9991},[31421],{"type":46,"tag":250,"props":31422,"children":31423},{},[31424],{"type":52,"value":30636},{"type":46,"tag":250,"props":31426,"children":31427},{"class":252,"line":10017},[31428],{"type":46,"tag":250,"props":31429,"children":31430},{},[31431],{"type":52,"value":30644},{"type":46,"tag":250,"props":31433,"children":31434},{"class":252,"line":10058},[31435],{"type":46,"tag":250,"props":31436,"children":31437},{},[31438],{"type":52,"value":30652},{"type":46,"tag":250,"props":31440,"children":31441},{"class":252,"line":10936},[31442],{"type":46,"tag":250,"props":31443,"children":31444},{},[31445],{"type":52,"value":30660},{"type":46,"tag":250,"props":31447,"children":31448},{"class":252,"line":10995},[31449],{"type":46,"tag":250,"props":31450,"children":31451},{"emptyLinePlaceholder":22},[31452],{"type":52,"value":9386},{"type":46,"tag":250,"props":31454,"children":31455},{"class":252,"line":22686},[31456],{"type":46,"tag":250,"props":31457,"children":31458},{},[31459],{"type":52,"value":30675},{"type":46,"tag":250,"props":31461,"children":31462},{"class":252,"line":22694},[31463],{"type":46,"tag":250,"props":31464,"children":31465},{},[31466],{"type":52,"value":30683},{"type":46,"tag":250,"props":31468,"children":31469},{"class":252,"line":22702},[31470],{"type":46,"tag":250,"props":31471,"children":31472},{},[31473],{"type":52,"value":30691},{"type":46,"tag":250,"props":31475,"children":31476},{"class":252,"line":22728},[31477],{"type":46,"tag":250,"props":31478,"children":31479},{},[31480],{"type":52,"value":30699},{"type":46,"tag":250,"props":31482,"children":31483},{"class":252,"line":22748},[31484],{"type":46,"tag":250,"props":31485,"children":31486},{},[31487],{"type":52,"value":30707},{"type":46,"tag":250,"props":31489,"children":31490},{"class":252,"line":22769},[31491],{"type":46,"tag":250,"props":31492,"children":31493},{},[31494],{"type":52,"value":30715},{"type":46,"tag":250,"props":31496,"children":31497},{"class":252,"line":22790},[31498],{"type":46,"tag":250,"props":31499,"children":31500},{},[31501],{"type":52,"value":30723},{"type":46,"tag":220,"props":31503,"children":31505},{"id":31504},"_3-ask-claude-code-real-business-questions",[31506],{"type":52,"value":31507},"3) Ask Claude Code real business questions",{"type":46,"tag":55,"props":31509,"children":31510},{},[31511,31513,31518],{"type":52,"value":31512},"With the Bruin MCP connected and ",{"type":46,"tag":99,"props":31514,"children":31516},{"className":31515},[],[31517],{"type":52,"value":30138},{"type":52,"value":31519}," in place, Claude Code is now your ecommerce data analyst. Try these:",{"type":46,"tag":1434,"props":31521,"children":31522},{},[31523],{"type":46,"tag":55,"props":31524,"children":31525},{},[31526],{"type":52,"value":31527},"What was our revenue last week compared to the week before? Break it down by day.",{"type":46,"tag":1434,"props":31529,"children":31530},{},[31531],{"type":46,"tag":55,"props":31532,"children":31533},{},[31534],{"type":52,"value":31535},"Which marketing channel had the best ROAS in the past 30 days?",{"type":46,"tag":1434,"props":31537,"children":31538},{},[31539],{"type":46,"tag":55,"props":31540,"children":31541},{},[31542],{"type":52,"value":31543},"Show me the customer cohort retention curve for customers acquired in January.",{"type":46,"tag":1434,"props":31545,"children":31546},{},[31547],{"type":46,"tag":55,"props":31548,"children":31549},{},[31550],{"type":52,"value":31551},"What are our top 10 products by revenue this month, and what's their cancellation rate?",{"type":46,"tag":1434,"props":31553,"children":31554},{},[31555],{"type":46,"tag":55,"props":31556,"children":31557},{},[31558,31563,31565,31571,31573,31578,31580,31585],{"type":46,"tag":80,"props":31559,"children":31560},{},[31561],{"type":52,"value":31562},"Note:",{"type":52,"value":31564}," The ",{"type":46,"tag":99,"props":31566,"children":31568},{"className":31567},[],[31569],{"type":52,"value":31570},"rpt_product_performance",{"type":52,"value":31572}," report currently shows catalog data from ",{"type":46,"tag":99,"props":31574,"children":31576},{"className":31575},[],[31577],{"type":52,"value":21742},{"type":52,"value":31579}," only. To get revenue-per-product metrics, expand the pipeline with a ",{"type":46,"tag":99,"props":31581,"children":31583},{"className":31582},[],[31584],{"type":52,"value":9030},{"type":52,"value":31586}," asset that flattens Shopify's nested line item JSON, then ask Claude Code to rebuild this report with order-level data.",{"type":46,"tag":1434,"props":31588,"children":31589},{},[31590],{"type":46,"tag":55,"props":31591,"children":31592},{},[31593],{"type":52,"value":31594},"What's our conversion rate trend over the past 3 months?",{"type":46,"tag":55,"props":31596,"children":31597},{},[31598,31600,31605],{"type":52,"value":31599},"Claude Code uses the Bruin MCP to query your warehouse directly, reading the ",{"type":46,"tag":99,"props":31601,"children":31603},{"className":31602},[],[31604],{"type":52,"value":30138},{"type":52,"value":31606}," for context on your domain terms and data quirks before writing SQL.",{"type":46,"tag":220,"props":31608,"children":31610},{"id":31609},"_4-iterate-on-agentsmd",[31611],{"type":52,"value":31612},"4) Iterate on AGENTS.md",{"type":46,"tag":55,"props":31614,"children":31615},{},[31616,31618,31623],{"type":52,"value":31617},"When the agent gets something wrong - wrong column, wrong metric definition, expensive query - add a correction to ",{"type":46,"tag":99,"props":31619,"children":31621},{"className":31620},[],[31622],{"type":52,"value":30138},{"type":52,"value":31624},". For example:",{"type":46,"tag":240,"props":31626,"children":31628},{"className":30292,"code":31627,"language":1560,"meta":7,"style":7},"## Known issues\n- The `stg_orders.order_total` includes tax. For product-only revenue, use `subtotal` instead.\n- When computing repeat purchase rate, count by `customer_email`, not by `order_id`.\n",[31629],{"type":46,"tag":99,"props":31630,"children":31631},{"__ignoreMap":7},[31632,31640,31648],{"type":46,"tag":250,"props":31633,"children":31634},{"class":252,"line":23},[31635],{"type":46,"tag":250,"props":31636,"children":31637},{},[31638],{"type":52,"value":31639},"## Known issues\n",{"type":46,"tag":250,"props":31641,"children":31642},{"class":252,"line":285},[31643],{"type":46,"tag":250,"props":31644,"children":31645},{},[31646],{"type":52,"value":31647},"- The `stg_orders.order_total` includes tax. For product-only revenue, use `subtotal` instead.\n",{"type":46,"tag":250,"props":31649,"children":31650},{"class":252,"line":299},[31651],{"type":46,"tag":250,"props":31652,"children":31653},{},[31654],{"type":52,"value":31655},"- When computing repeat purchase rate, count by `customer_email`, not by `order_id`.\n",{"type":46,"tag":55,"props":31657,"children":31658},{},[31659,31661,31666],{"type":52,"value":31660},"The more you use it, the better your ",{"type":46,"tag":99,"props":31662,"children":31664},{"className":31663},[],[31665],{"type":52,"value":30138},{"type":52,"value":31667}," gets. When the agent makes a mistake, that's a sign something is missing from the context file.",{"type":46,"tag":220,"props":31669,"children":31671},{"id":31670},"_5-deploy-to-bruin-cloud",[31672],{"type":52,"value":31673},"5) Deploy to Bruin Cloud",{"type":46,"tag":55,"props":31675,"children":31676},{},[31677],{"type":52,"value":31678},"Now let's make this available to the whole team - in Slack or Teams, not just locally.",{"type":46,"tag":55,"props":31680,"children":31681},{},[31682],{"type":46,"tag":80,"props":31683,"children":31684},{},[31685],{"type":52,"value":31686},"Push your project to GitHub:",{"type":46,"tag":1434,"props":31688,"children":31689},{},[31690],{"type":46,"tag":55,"props":31691,"children":31692},{},[31693,31697,31698,31703,31705,31710,31712,31717],{"type":46,"tag":80,"props":31694,"children":31695},{},[31696],{"type":52,"value":31562},{"type":52,"value":516},{"type":46,"tag":99,"props":31699,"children":31701},{"className":31700},[],[31702],{"type":52,"value":350},{"type":52,"value":31704}," contains your connection credentials. ",{"type":46,"tag":99,"props":31706,"children":31708},{"className":31707},[],[31709],{"type":52,"value":236},{"type":52,"value":31711}," adds it to ",{"type":46,"tag":99,"props":31713,"children":31715},{"className":31714},[],[31716],{"type":52,"value":399},{"type":52,"value":31718}," by default - verify it's there before pushing.",{"type":46,"tag":240,"props":31720,"children":31722},{"className":242,"code":31721,"language":244,"meta":7,"style":7},"git add -A -- ':!.bruin.yml'\ngit commit -m \"ecommerce analytics pipeline\"\ngit remote add origin https:\u002F\u002Fgithub.com\u002Fyour-org\u002Fecommerce-analytics.git\ngit push -u origin main\n",[31723],{"type":46,"tag":99,"props":31724,"children":31725},{"__ignoreMap":7},[31726,31751,31773,31799],{"type":46,"tag":250,"props":31727,"children":31728},{"class":252,"line":23},[31729,31733,31737,31742,31746],{"type":46,"tag":250,"props":31730,"children":31731},{"style":256},[31732],{"type":52,"value":291},{"type":46,"tag":250,"props":31734,"children":31735},{"style":262},[31736],{"type":52,"value":1408},{"type":46,"tag":250,"props":31738,"children":31739},{"style":274},[31740],{"type":52,"value":31741}," -A",{"type":46,"tag":250,"props":31743,"children":31744},{"style":274},[31745],{"type":52,"value":1418},{"type":46,"tag":250,"props":31747,"children":31748},{"style":262},[31749],{"type":52,"value":31750}," ':!.bruin.yml'\n",{"type":46,"tag":250,"props":31752,"children":31753},{"class":252,"line":285},[31754,31758,31763,31768],{"type":46,"tag":250,"props":31755,"children":31756},{"style":256},[31757],{"type":52,"value":291},{"type":46,"tag":250,"props":31759,"children":31760},{"style":262},[31761],{"type":52,"value":31762}," commit",{"type":46,"tag":250,"props":31764,"children":31765},{"style":274},[31766],{"type":52,"value":31767}," -m",{"type":46,"tag":250,"props":31769,"children":31770},{"style":262},[31771],{"type":52,"value":31772}," \"ecommerce analytics pipeline\"\n",{"type":46,"tag":250,"props":31774,"children":31775},{"class":252,"line":299},[31776,31780,31785,31789,31794],{"type":46,"tag":250,"props":31777,"children":31778},{"style":256},[31779],{"type":52,"value":291},{"type":46,"tag":250,"props":31781,"children":31782},{"style":262},[31783],{"type":52,"value":31784}," remote",{"type":46,"tag":250,"props":31786,"children":31787},{"style":262},[31788],{"type":52,"value":1408},{"type":46,"tag":250,"props":31790,"children":31791},{"style":262},[31792],{"type":52,"value":31793}," origin",{"type":46,"tag":250,"props":31795,"children":31796},{"style":262},[31797],{"type":52,"value":31798}," https:\u002F\u002Fgithub.com\u002Fyour-org\u002Fecommerce-analytics.git\n",{"type":46,"tag":250,"props":31800,"children":31801},{"class":252,"line":807},[31802,31806,31811,31816,31820],{"type":46,"tag":250,"props":31803,"children":31804},{"style":256},[31805],{"type":52,"value":291},{"type":46,"tag":250,"props":31807,"children":31808},{"style":262},[31809],{"type":52,"value":31810}," push",{"type":46,"tag":250,"props":31812,"children":31813},{"style":274},[31814],{"type":52,"value":31815}," -u",{"type":46,"tag":250,"props":31817,"children":31818},{"style":262},[31819],{"type":52,"value":31793},{"type":46,"tag":250,"props":31821,"children":31822},{"style":262},[31823],{"type":52,"value":31824}," main\n",{"type":46,"tag":55,"props":31826,"children":31827},{},[31828],{"type":46,"tag":80,"props":31829,"children":31830},{},[31831],{"type":52,"value":31832},"Add the repo to Bruin Cloud:",{"type":46,"tag":30114,"props":31834,"children":31835},{},[31836,31853,31858,31871,31876],{"type":46,"tag":76,"props":31837,"children":31838},{},[31839,31841,31846,31848],{"type":52,"value":31840},"Go to ",{"type":46,"tag":88,"props":31842,"children":31844},{"href":404,"rel":31843},[92],[31845],{"type":52,"value":408},{"type":52,"value":31847},", open ",{"type":46,"tag":80,"props":31849,"children":31850},{},[31851],{"type":52,"value":31852},"Team Settings > Projects",{"type":46,"tag":76,"props":31854,"children":31855},{},[31856],{"type":52,"value":31857},"Add your GitHub repository",{"type":46,"tag":76,"props":31859,"children":31860},{},[31861,31863,31869],{"type":52,"value":31862},"Enable the ",{"type":46,"tag":99,"props":31864,"children":31866},{"className":31865},[],[31867],{"type":52,"value":31868},"ecommerce",{"type":52,"value":31870}," pipeline",{"type":46,"tag":76,"props":31872,"children":31873},{},[31874],{"type":52,"value":31875},"Configure your connections (warehouse, Shopify, Stripe, etc.) in the Cloud environment",{"type":46,"tag":76,"props":31877,"children":31878},{},[31879],{"type":52,"value":31880},"Run the pipeline to confirm it works",{"type":46,"tag":55,"props":31882,"children":31883},{},[31884],{"type":46,"tag":80,"props":31885,"children":31886},{},[31887],{"type":52,"value":31888},"Create the Slack\u002FTeams AI agent:",{"type":46,"tag":30114,"props":31890,"children":31891},{},[31892,31901,31912,31917,31922],{"type":46,"tag":76,"props":31893,"children":31894},{},[31895,31896],{"type":52,"value":31840},{"type":46,"tag":80,"props":31897,"children":31898},{},[31899],{"type":52,"value":31900},"Agents > Create Agent",{"type":46,"tag":76,"props":31902,"children":31903},{},[31904,31906,31911],{"type":52,"value":31905},"Select your repo and the ",{"type":46,"tag":99,"props":31907,"children":31909},{"className":31908},[],[31910],{"type":52,"value":31868},{"type":52,"value":31870},{"type":46,"tag":76,"props":31913,"children":31914},{},[31915],{"type":52,"value":31916},"Add your Slack (or Teams) credentials",{"type":46,"tag":76,"props":31918,"children":31919},{},[31920],{"type":52,"value":31921},"Name the agent, e.g. \"Ecommerce Analyst\"",{"type":46,"tag":76,"props":31923,"children":31924},{},[31925],{"type":52,"value":31926},"Select the target channel where your team asks data questions",{"type":46,"tag":55,"props":31928,"children":31929},{},[31930],{"type":46,"tag":80,"props":31931,"children":31932},{},[31933],{"type":52,"value":31934},"Test in Slack:",{"type":46,"tag":55,"props":31936,"children":31937},{},[31938],{"type":52,"value":31939},"Mention the agent in your channel:",{"type":46,"tag":1434,"props":31941,"children":31942},{},[31943],{"type":46,"tag":55,"props":31944,"children":31945},{},[31946],{"type":52,"value":31947},"@Ecommerce Analyst What was our revenue yesterday?",{"type":46,"tag":55,"props":31949,"children":31950},{},[31951,31953,31958],{"type":52,"value":31952},"The agent queries your warehouse using the same ",{"type":46,"tag":99,"props":31954,"children":31956},{"className":31955},[],[31957],{"type":52,"value":30138},{"type":52,"value":31959}," context and responds with an answer. Anyone on the team can ask questions without writing SQL.",{"type":46,"tag":47,"props":31961,"children":31962},{"id":1531},[31963],{"type":52,"value":1534},{"type":46,"tag":72,"props":31965,"children":31966},{},[31967,31980,31993,32003],{"type":46,"tag":76,"props":31968,"children":31969},{},[31970,31978],{"type":46,"tag":80,"props":31971,"children":31972},{},[31973],{"type":46,"tag":99,"props":31974,"children":31976},{"className":31975},[],[31977],{"type":52,"value":30127},{"type":52,"value":31979}," auto-generated metadata for all your pipeline assets",{"type":46,"tag":76,"props":31981,"children":31982},{},[31983,31991],{"type":46,"tag":80,"props":31984,"children":31985},{},[31986],{"type":46,"tag":99,"props":31987,"children":31989},{"className":31988},[],[31990],{"type":52,"value":30138},{"type":52,"value":31992}," gives the AI analyst ecommerce-specific domain knowledge",{"type":46,"tag":76,"props":31994,"children":31995},{},[31996,32001],{"type":46,"tag":80,"props":31997,"children":31998},{},[31999],{"type":52,"value":32000},"Local AI analyst",{"type":52,"value":32002}," with Claude Code answering business questions through Bruin MCP",{"type":46,"tag":76,"props":32004,"children":32005},{},[32006,32011],{"type":46,"tag":80,"props":32007,"children":32008},{},[32009],{"type":52,"value":32010},"Cloud AI analyst",{"type":52,"value":32012}," runs on Bruin Cloud and responds to questions in Slack or Teams",{"type":46,"tag":55,"props":32014,"children":32015},{},[32016],{"type":52,"value":32017},"Next up, you'll build interactive dashboards using the same AI agent in Bruin Cloud.",{"type":46,"tag":1541,"props":32019,"children":32020},{},[32021],{"type":52,"value":1545},{"title":7,"searchDepth":285,"depth":285,"links":32023},[32024,32025,32026,32033],{"id":49,"depth":285,"text":53},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":32027},[32028,32029,32030,32031,32032],{"id":30178,"depth":299,"text":30181},{"id":30237,"depth":299,"text":30240},{"id":31504,"depth":299,"text":31507},{"id":31609,"depth":299,"text":31612},{"id":31670,"depth":299,"text":31673},{"id":1531,"depth":285,"text":1534},"content:tutorials:ecommerce-pipeline:ai-analyst.md","tutorials\u002Fecommerce-pipeline\u002Fai-analyst.md","tutorials\u002Fecommerce-pipeline\u002Fai-analyst",{"_path":32038,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":32039,"description":32040,"date":10,"readingTime":820,"category":12,"tags":32041,"difficulty":21,"module":5,"subSteps":22,"step":844,"journeys":32043,"learnMore":32044,"author":32051,"body":32052,"_type":1560,"_id":32481,"_source":1562,"_file":32482,"_stem":32483,"_extension":1565},"\u002Ftutorials\u002Fecommerce-pipeline\u002Fdashboards","Build Ecommerce Dashboards","Use the Bruin Cloud AI agent to generate interactive ecommerce dashboards - revenue trends, customer cohorts, marketing ROI, and product performance - from natural language.",[408,30089,32042,20],"Dashboards",[26,27],[32045,32048],{"label":32046,"url":32047},"AI Dashboard Builder tutorial","\u002Flearn\u002Fbruin-dashboards",{"label":32049,"url":32050},"Bruin Cloud overview","https:\u002F\u002Fgetbruin.com\u002Fdocs\u002Fbruin\u002Fcloud\u002Foverview.html",{"name":39,"role":40,"image":41},{"type":43,"children":32053,"toc":32467},[32054,32058,32063,32067,32072,32084,32088,32094,32105,32111,32116,32124,32137,32143,32147,32155,32168,32174,32178,32186,32199,32205,32209,32217,32230,32236,32241,32276,32281,32285,32290,32333,32336,32342,32347,32410,32422,32430],{"type":46,"tag":47,"props":32055,"children":32056},{"id":49},[32057],{"type":52,"value":53},{"type":46,"tag":55,"props":32059,"children":32060},{},[32061],{"type":52,"value":32062},"Use the Bruin Cloud AI Dashboard Builder to create four ecommerce dashboards from natural language prompts. No SQL, no chart configuration - just describe what you want to see.",{"type":46,"tag":47,"props":32064,"children":32065},{"id":183},[32066],{"type":52,"value":186},{"type":46,"tag":55,"props":32068,"children":32069},{},[32070],{"type":52,"value":32071},"Reports in a database are useful for analysts, but most people want dashboards. A founder wants to check revenue trends. A marketing manager wants ROAS by channel. A product lead wants to know which SKUs are underperforming.",{"type":46,"tag":55,"props":32073,"children":32074},{},[32075,32077,32082],{"type":52,"value":32076},"The AI Dashboard Builder creates charts from your report tables based on what you ask for. It reads your ",{"type":46,"tag":99,"props":32078,"children":32080},{"className":32079},[],[32081],{"type":52,"value":30138},{"type":52,"value":32083}," context, so it uses the right metrics and definitions.",{"type":46,"tag":47,"props":32085,"children":32086},{"id":215},[32087],{"type":52,"value":218},{"type":46,"tag":220,"props":32089,"children":32091},{"id":32090},"_1-open-the-dashboards-page",[32092],{"type":52,"value":32093},"1) Open the Dashboards page",{"type":46,"tag":55,"props":32095,"children":32096},{},[32097,32099,32103],{"type":52,"value":32098},"Go to the ",{"type":46,"tag":80,"props":32100,"children":32101},{},[32102],{"type":52,"value":32042},{"type":52,"value":32104}," section in Bruin Cloud. Make sure your pipeline has run at least once so the report tables have data.",{"type":46,"tag":220,"props":32106,"children":32108},{"id":32107},"_2-executive-kpis-dashboard",[32109],{"type":52,"value":32110},"2) Executive KPIs dashboard",{"type":46,"tag":55,"props":32112,"children":32113},{},[32114],{"type":52,"value":32115},"Ask the AI agent:",{"type":46,"tag":1434,"props":32117,"children":32118},{},[32119],{"type":46,"tag":55,"props":32120,"children":32121},{},[32122],{"type":52,"value":32123},"Build an executive dashboard showing daily revenue, order count, AOV, and new vs returning customers for the last 30 days with week-over-week comparison.",{"type":46,"tag":55,"props":32125,"children":32126},{},[32127,32129,32135],{"type":52,"value":32128},"The agent generates SQL against your ",{"type":46,"tag":99,"props":32130,"children":32132},{"className":32131},[],[32133],{"type":52,"value":32134},"reports.rpt_daily_kpis",{"type":52,"value":32136}," table and creates line charts, KPI cards, and comparison metrics.",{"type":46,"tag":220,"props":32138,"children":32140},{"id":32139},"_3-marketing-performance-dashboard",[32141],{"type":52,"value":32142},"3) Marketing performance dashboard",{"type":46,"tag":55,"props":32144,"children":32145},{},[32146],{"type":52,"value":32115},{"type":46,"tag":1434,"props":32148,"children":32149},{},[32150],{"type":46,"tag":55,"props":32151,"children":32152},{},[32153],{"type":52,"value":32154},"Show me marketing performance by channel - ROAS, spend, and attributed revenue for Facebook Ads and email, with a trend chart for the last 90 days.",{"type":46,"tag":55,"props":32156,"children":32157},{},[32158,32160,32166],{"type":52,"value":32159},"This pulls from ",{"type":46,"tag":99,"props":32161,"children":32163},{"className":32162},[],[32164],{"type":52,"value":32165},"reports.rpt_marketing_roi",{"type":52,"value":32167}," and creates a multi-channel comparison with spend efficiency metrics.",{"type":46,"tag":220,"props":32169,"children":32171},{"id":32170},"_4-customer-cohorts-dashboard",[32172],{"type":52,"value":32173},"4) Customer cohorts dashboard",{"type":46,"tag":55,"props":32175,"children":32176},{},[32177],{"type":52,"value":32115},{"type":46,"tag":1434,"props":32179,"children":32180},{},[32181],{"type":46,"tag":55,"props":32182,"children":32183},{},[32184],{"type":52,"value":32185},"Create a cohort retention chart showing monthly customer retention rates for the last 6 cohorts, plus lifetime value by cohort.",{"type":46,"tag":55,"props":32187,"children":32188},{},[32189,32191,32197],{"type":52,"value":32190},"This uses ",{"type":46,"tag":99,"props":32192,"children":32194},{"className":32193},[],[32195],{"type":52,"value":32196},"reports.rpt_customer_cohorts",{"type":52,"value":32198}," to build a retention heatmap and LTV trend.",{"type":46,"tag":220,"props":32200,"children":32202},{"id":32201},"_5-product-performance-dashboard",[32203],{"type":52,"value":32204},"5) Product performance dashboard",{"type":46,"tag":55,"props":32206,"children":32207},{},[32208],{"type":52,"value":32115},{"type":46,"tag":1434,"props":32210,"children":32211},{},[32212],{"type":46,"tag":55,"props":32213,"children":32214},{},[32215],{"type":52,"value":32216},"Show top 20 products by revenue with their cancellation rate, and a category-level revenue breakdown.",{"type":46,"tag":55,"props":32218,"children":32219},{},[32220,32222,32228],{"type":52,"value":32221},"This queries ",{"type":46,"tag":99,"props":32223,"children":32225},{"className":32224},[],[32226],{"type":52,"value":32227},"reports.rpt_product_performance",{"type":52,"value":32229}," to create a ranked product table and a category breakdown chart.",{"type":46,"tag":220,"props":32231,"children":32233},{"id":32232},"_6-iterate-and-ask-questions",[32234],{"type":52,"value":32235},"6) Iterate and ask questions",{"type":46,"tag":55,"props":32237,"children":32238},{},[32239],{"type":52,"value":32240},"The AI agent is conversational. You can refine any dashboard:",{"type":46,"tag":72,"props":32242,"children":32243},{},[32244,32254,32266],{"type":46,"tag":76,"props":32245,"children":32246},{},[32247,32249],{"type":52,"value":32248},"Click on a chart to bring it into context, then ask: ",{"type":46,"tag":1036,"props":32250,"children":32251},{},[32252],{"type":52,"value":32253},"\"Change this to a bar chart instead\"",{"type":46,"tag":76,"props":32255,"children":32256},{},[32257,32259,32264],{"type":52,"value":32258},"Ask follow-up questions: ",{"type":46,"tag":1036,"props":32260,"children":32261},{},[32262],{"type":52,"value":32263},"\"Why did revenue dip last Tuesday?\"",{"type":52,"value":32265}," - the agent analyzes the data instead of building another chart",{"type":46,"tag":76,"props":32267,"children":32268},{},[32269,32271],{"type":52,"value":32270},"Add new charts: ",{"type":46,"tag":1036,"props":32272,"children":32273},{},[32274],{"type":52,"value":32275},"\"Add a chart showing refund rate by product category\"",{"type":46,"tag":55,"props":32277,"children":32278},{},[32279],{"type":52,"value":32280},"Every chart is backed by a visible SQL query you can inspect and verify.",{"type":46,"tag":47,"props":32282,"children":32283},{"id":1531},[32284],{"type":52,"value":1534},{"type":46,"tag":55,"props":32286,"children":32287},{},[32288],{"type":52,"value":32289},"You now have four interactive ecommerce dashboards that update as your pipeline runs daily:",{"type":46,"tag":30114,"props":32291,"children":32292},{},[32293,32303,32313,32323],{"type":46,"tag":76,"props":32294,"children":32295},{},[32296,32301],{"type":46,"tag":80,"props":32297,"children":32298},{},[32299],{"type":52,"value":32300},"Executive KPIs",{"type":52,"value":32302}," - daily revenue, orders, AOV, customer mix",{"type":46,"tag":76,"props":32304,"children":32305},{},[32306,32311],{"type":46,"tag":80,"props":32307,"children":32308},{},[32309],{"type":52,"value":32310},"Marketing Performance",{"type":52,"value":32312}," - spend, ROAS, and revenue by channel",{"type":46,"tag":76,"props":32314,"children":32315},{},[32316,32321],{"type":46,"tag":80,"props":32317,"children":32318},{},[32319],{"type":52,"value":32320},"Customer Cohorts",{"type":52,"value":32322}," - retention rates and LTV by cohort",{"type":46,"tag":76,"props":32324,"children":32325},{},[32326,32331],{"type":46,"tag":80,"props":32327,"children":32328},{},[32329],{"type":52,"value":32330},"Product Performance",{"type":52,"value":32332}," - top products and category breakdown",{"type":46,"tag":4373,"props":32334,"children":32335},{},[],{"type":46,"tag":47,"props":32337,"children":32339},{"id":32338},"thats-the-full-stack",[32340],{"type":52,"value":32341},"That's the full stack",{"type":46,"tag":55,"props":32343,"children":32344},{},[32345],{"type":52,"value":32346},"Over the course of this module, you built:",{"type":46,"tag":72,"props":32348,"children":32349},{},[32350,32360,32370,32380,32390,32400],{"type":46,"tag":76,"props":32351,"children":32352},{},[32353,32358],{"type":46,"tag":80,"props":32354,"children":32355},{},[32356],{"type":52,"value":32357},"Data ingestion",{"type":52,"value":32359}," from 5 SaaS sources (Shopify and your selected tools) into your data warehouse",{"type":46,"tag":76,"props":32361,"children":32362},{},[32363,32368],{"type":46,"tag":80,"props":32364,"children":32365},{},[32366],{"type":52,"value":32367},"A staging layer",{"type":52,"value":32369}," that cleans, deduplicates, and joins data across all sources",{"type":46,"tag":76,"props":32371,"children":32372},{},[32373,32378],{"type":46,"tag":80,"props":32374,"children":32375},{},[32376],{"type":52,"value":32377},"Business reports",{"type":52,"value":32379}," for revenue, cohorts, products, marketing ROI, and daily KPIs",{"type":46,"tag":76,"props":32381,"children":32382},{},[32383,32388],{"type":46,"tag":80,"props":32384,"children":32385},{},[32386],{"type":52,"value":32387},"A local AI analyst",{"type":52,"value":32389}," that answers questions through Bruin MCP",{"type":46,"tag":76,"props":32391,"children":32392},{},[32393,32398],{"type":46,"tag":80,"props":32394,"children":32395},{},[32396],{"type":52,"value":32397},"A cloud AI analyst",{"type":52,"value":32399}," your team can talk to in Slack or Teams",{"type":46,"tag":76,"props":32401,"children":32402},{},[32403,32408],{"type":46,"tag":80,"props":32404,"children":32405},{},[32406],{"type":52,"value":32407},"Interactive dashboards",{"type":52,"value":32409}," built from natural language in Bruin Cloud",{"type":46,"tag":55,"props":32411,"children":32412},{},[32413,32415,32420],{"type":52,"value":32414},"The pipeline runs daily on schedule. Your team can ask questions without writing SQL. And the ",{"type":46,"tag":99,"props":32416,"children":32418},{"className":32417},[],[32419],{"type":52,"value":30138},{"type":52,"value":32421}," file improves every time you add to it.",{"type":46,"tag":55,"props":32423,"children":32424},{},[32425],{"type":46,"tag":80,"props":32426,"children":32427},{},[32428],{"type":52,"value":32429},"Where to go from here:",{"type":46,"tag":72,"props":32431,"children":32432},{},[32433,32438,32450,32455],{"type":46,"tag":76,"props":32434,"children":32435},{},[32436],{"type":52,"value":32437},"Add more data sources as your stack grows",{"type":46,"tag":76,"props":32439,"children":32440},{},[32441,32443,32448],{"type":52,"value":32442},"Add new terms and caveats to ",{"type":46,"tag":99,"props":32444,"children":32446},{"className":32445},[],[32447],{"type":52,"value":30138},{"type":52,"value":32449}," as you discover them",{"type":46,"tag":76,"props":32451,"children":32452},{},[32453],{"type":52,"value":32454},"Build additional dashboards for specific teams (marketing, ops, finance)",{"type":46,"tag":76,"props":32456,"children":32457},{},[32458,32460,32465],{"type":52,"value":32459},"Check out the ",{"type":46,"tag":88,"props":32461,"children":32462},{"href":138},[32463],{"type":52,"value":32464},"Bruin Core Concepts",{"type":52,"value":32466}," module if you want to go deeper on pipelines, assets, and variables",{"title":7,"searchDepth":285,"depth":285,"links":32468},[32469,32470,32471,32479,32480],{"id":49,"depth":285,"text":53},{"id":183,"depth":285,"text":186},{"id":215,"depth":285,"text":218,"children":32472},[32473,32474,32475,32476,32477,32478],{"id":32090,"depth":299,"text":32093},{"id":32107,"depth":299,"text":32110},{"id":32139,"depth":299,"text":32142},{"id":32170,"depth":299,"text":32173},{"id":32201,"depth":299,"text":32204},{"id":32232,"depth":299,"text":32235},{"id":1531,"depth":285,"text":1534},{"id":32338,"depth":285,"text":32341},"content:tutorials:ecommerce-pipeline:dashboards.md","tutorials\u002Fecommerce-pipeline\u002Fdashboards.md","tutorials\u002Fecommerce-pipeline\u002Fdashboards",1776143482313]