Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

fix(marketing): preserve search console metric aggregation (#120685)

Javier Bahamondesc7c6d601d7fc
diff --git a/docs/internal/marketing-source-suggestions.md b/docs/internal/marketing-source-suggestions.md
index 71acfa741018..a00bb0ae07d8 100644
--- a/docs/internal/marketing-source-suggestions.md
+++ b/docs/internal/marketing-source-suggestions.md
@@ -109,7 +109,10 @@ Ad-level reporting is unavailable because the connector does not import promoted
## Search performance
Keywords and queries includes paid keywords from ad platforms and organic queries from Google Search Console.
-Search Console requires a synced `search_analytics_by_query` or `search_analytics_by_query_page` table; the integration and paid/organic filters determine which sources appear.
+Search Console keyword rankings require a synced `search_analytics_by_query` table, and landing page rankings require `search_analytics_by_page`.
+Drill-downs use `search_analytics_by_query_page`.
+A missing or stale dedicated table shows a source notice and excludes that source from the ranking; it does not fall back to query-and-page data because aggregation by page can change clicks, impressions, CTR, and position.
+The integration and paid/organic filters determine which sources appear.
Each search table has a reload control and query duration.
Pagination stays within the table without scrolling the scene, and changing between keywords and landing pages starts on page 1.
Long landing URLs truncate within the first column; hover over the URL to read it in full.
diff --git a/frontend/snapshots.yml b/frontend/snapshots.yml
index 125266b69037..b89fd286ebba 100644
--- a/frontend/snapshots.yml
+++ b/frontend/snapshots.yml
@@ -13413,69 +13413,69 @@ snapshots:
scenes-app-marketing-analytics-persisted-conversion-recommendations--updating--light:
hash: v1.k794b7964.852abfd71814efc870cb2178a7acf97833babbd13866c0196d6976f8351999fb._dZPb-BB_XLmD7aRG3nBiePMXUZOzSzgVTK6xgccsF4
scenes-app-marketing-analytics-search-performance--awaiting-sync--dark:
- hash: v1.k794b7964.a68e5069915d1416731bb56e1bd061b81020839cf35d98cdc01552a0c7fe0602.s7rS2bvBpMV8lvMnKn2C5VihtDFuU_Bq0x7vnTZ7jK4
+ hash: v1.k794b7964.d69b90c1e1a2b1b836be603421a2ae39c62e84272b9579cce6e718a02ff8403a.PLuTb4SYPUf_cP9vbV8nbsc83U3K8Cbzh1KDVDXoy6I
scenes-app-marketing-analytics-search-performance--awaiting-sync--light:
- hash: v1.k794b7964.1e682849cf3ff944c156abae9e4a762cbfb4a6067a3a28b92f0a900f62d781cd.2NWULrKTIdOxwZwMcOOWiXaakv5AQ5GNtbiACz2FzyU
+ hash: v1.k794b7964.f6c9e00e26b7cda9817080605af0dba6af50c4db7d8b3150ad4b364863a4f854.AswfVTF8W0wX2vZwV3wd5l6Mm1iM-KeUgXLOcTgWZuA
scenes-app-marketing-analytics-search-performance--comparison--dark:
- hash: v1.k794b7964.210933b06f2bcb00f078c3b6872b1fc0f7f827a0764bbd495b636c156fdb633b.9N7I1irVjsUj1EDQ9FIYWuy_qE2534HiyMVxoqWbVlM
+ hash: v1.k794b7964.95bd2000c35ea1689e482196cf423e67a26aa274afb3007b2bd43a595f0baec2.HT-gsKTAdJRH2DvwzxQNKX6H66l_YesIPnxp-ayM0D4
scenes-app-marketing-analytics-search-performance--comparison--light:
- hash: v1.k794b7964.90ba9d9691f4ad58f6b76494bf466534de57e101cabfed4a417967c596261f13.fQIwF9QvUzEhEDCzKIB46HGz876l2yFh_ZXzQh6Wy9M
+ hash: v1.k794b7964.9a55e5c29016c60fc359238d47f15def8b79e5f69b9102eca41a934ab4e014d2.PkxoyIAZjKW35Fl0bM_CE7w9ez7YdpRpPnGC-BB_UPI
scenes-app-marketing-analytics-search-performance--connected--dark:
- hash: v1.k794b7964.8b890259ce38300f636b6ff1fc05bbf72a7a4f59d59eb1400309c61b81a47326.J1xcAaOCEDVsXZ_8o33fSUooydTAMnJXQe1JeuLwz_I
+ hash: v1.k794b7964.ead0cf46b1e32d9a8a70e1c04a2c88ed7e178c220959005d2d45292ca562d443.7Bo6GLZeqztyWorpSqUZfq1gpo0JHWcWWlnS4RSoC7o
scenes-app-marketing-analytics-search-performance--connected--light:
- hash: v1.k794b7964.447f75b7576cac3d0db3b088ea7d78b86d355ebccda57892876948ef82513b91.I3sr2SEJtSn1R1AGf_5ui3eBrJ0ccn62CVQ2g76ZBDA
+ hash: v1.k794b7964.0ea2378608d19fe8882c2e13569b198cc5d7b91c12b6b9b90554e9b3e2753da3.iLdhQ74WrJFM1LzQfRUNyFYFxV5e8NDsJ9dgnf8e25A
scenes-app-marketing-analytics-search-performance--empty--dark:
- hash: v1.k794b7964.9f1249316a2c9985f5a6c224f180a045c509eeb54ddb5b6f7b910287223a4b3a.-njLiBuPCAgp_EaXigo7HzgIZMDs8Rv1d21GwEMG06w
+ hash: v1.k794b7964.2b0cdec5ce63792a7b4832bf7d3c5b23217961db286da2301dd725a6ac942c13.PRBtfW_JmszAo1giQmJ2DyprfxdaWYofAhAm1tOtqOw
scenes-app-marketing-analytics-search-performance--empty--light:
- hash: v1.k794b7964.fbcf88f4d22d9f943fe14e1aace4f1173229ee8044de4a8ca72abb2245a3a2cc.WescPg0a589XbTy7FBCxshi8fiKfPfOxeRHSvRixSYA
+ hash: v1.k794b7964.d39a80f11f98274d1569714eb62de933e271e905bcbbed9e35593e5a75dc02c6.BjO-fba2MEiNDFLoycBuShvBhewOBkReaM2K7dDd2kM
scenes-app-marketing-analytics-search-performance--empty-google-ads--dark:
- hash: v1.k794b7964.5fc8926c03b44da8f2137a5961d73ed90b2b4a3271b3b10f938a89cc6bfd144b.ZPNdbvsrChlkGwSXRwB8XJrKbiGkuKmGeHf7PnTaPZA
+ hash: v1.k794b7964.57d46db9218be8c0907c69fa5541f30bdad85774280d4d69987c7417f147cf1a.6HAWkRGklEPwCW2RtEr-uvpkp6zJJL6Vy85NXAZwzSU
scenes-app-marketing-analytics-search-performance--empty-google-ads--light:
- hash: v1.k794b7964.b0fe6cc872e8d4c2085c38a67958c52077b2c91a0489cfa20dc60ce7f013e79e.HnfAQQ5u7vELWMVgzU1y3RbY9nm3dykRifKBq47sFh0
+ hash: v1.k794b7964.80c3a79cfbf54e5c29f947e38b7d28441aacc6334af9c2b1b07d6a1f7e75b857.s07Uld-RcX3SenBloD0ICzobWIo3kcJrXoHEfpkLfU8
scenes-app-marketing-analytics-search-performance--empty-organic--dark:
- hash: v1.k794b7964.d8e094f9e90cdeee016fb58a9d2cdb2593c2377b08fefda0a3787851d25737ce.EeN-zmWTh6Qy9Lwwv2UB3j4MmbZqAQksvORY7KMEAdM
+ hash: v1.k794b7964.cd8bc86ab2e62102fbd747a6baf41030db7327fb656bd750af0b83ee8cda0ae0.rpGAXh_65SXveXlzYQRqKsDgU6ho8Pcy0lP3DCMgTss
scenes-app-marketing-analytics-search-performance--empty-organic--light:
- hash: v1.k794b7964.451bd03a65cc673dcc37455619769ca14d8c5aa3783a004c6968448dab545d30.2j0Ul4S5qTpdwmMZg_fbSferpiEkBILpsO4uBjTc_-g
+ hash: v1.k794b7964.2ea8b47cf5de2c83e5ed075428597e57ecebaa0764cbb5e41c820f3342450e40.j18V9g7KbTU3c8bgfPOQ9mwJZ96zAXZTlo5Ay9Fkx0c
scenes-app-marketing-analytics-search-performance--filtered-empty--dark:
- hash: v1.k794b7964.fe1489c77e70e9233ae8af1338dea14beae558532588eec61e2c4de70a22619d.sh0W1ajzLjefmG1_rYNDSASqP1Cd-AE1E_UnFfpwwys
+ hash: v1.k794b7964.ccf433e26ce4e1d5d939901c4b4f7b7550ba1e8429ebe38a648630b547dd991a.4YgW4lgqWUIQRnGhcJxP8wfOoOv96GD6ZYc52qPXZDM
scenes-app-marketing-analytics-search-performance--filtered-empty--light:
- hash: v1.k794b7964.3b4262a400459f33520153a16613da815d3da34b55156983e70d986f1e5d34b2.MhIRhmKAJVvskTu8VqLPdX7pSSWSTRZ4nBE5MJuKVQg
+ hash: v1.k794b7964.a70e2ef928f09b74db325e9ec8120752d23ba5f939029c67b9aacf25e93e3acf.vtRdJiUaE3QLAIK4LKj-Z6Tkq4EAzwC_ieK-jH2rod4
scenes-app-marketing-analytics-search-performance--flag-off--dark:
hash: v1.k794b7964.0abe2d58ee70ac24582205caacee0e0b09831b9f04687d5ee1d9ec28f7f99be8.23pCSt9pA4N6R0id0jXh6Z0GpGSmmifTz1Ur090dRnY
scenes-app-marketing-analytics-search-performance--flag-off--light:
hash: v1.k794b7964.9336af8fdbf0c10e0dadbdc398517b3856ad19eae7ff0f580ddd507e4202b57b.92lmvS4XqmLPpRq2h7e7R_7p8x2ZpdvIaIAKZRL4lQU
scenes-app-marketing-analytics-search-performance--keyword-post-hog-conversions--dark:
- hash: v1.k794b7964.21f3d8b1eb73a3a526e2f7dd0be0b36911c04f03f36e99a9f6716424da4e3624.5Ex750DL1FcVG_i1Zc1bbEh9LaKU8Rb2H-ARw2Max7c
+ hash: v1.k794b7964.aea1c3861661b51b1b9ac211378927a0e4ccbfd3cc76c67800afbe4d9eea7ad4.WFZ1g29a7UBklWs_6oRgYfzca1yvvobb9RrU4OhKW0k
scenes-app-marketing-analytics-search-performance--keyword-post-hog-conversions--light:
- hash: v1.k794b7964.8849a82f1e979edc79ae2a5c01881c844bc4731aa0213768949e3af135eb074c.mO_WMAvfNK_tpB6AU9VIyYvQCZb3MXHiNdQqur8XJ7E
+ hash: v1.k794b7964.ef995d1a48d85971a0c2bdd22cd3ceb32a564efa24654bc3a9f9bc72eadf3313.7cx5RKJCArEWkrG03zxntcRpuiXV2WwJsUnEnVm9FTw
scenes-app-marketing-analytics-search-performance--keyword-post-hog-conversions-narrow--dark:
- hash: v1.k794b7964.3f85d04647af60eead6ab678aa477db67020131b53333105249565032289823c.O55MnPubefIkBC-lcVafgqLcraGVhCks97nf53opGRs
+ hash: v1.k794b7964.777f93e2c327bf97c822452e99a0c90ec0047f42468883b138def9180f5204d5._xrtlIp0NcB1B-rqdNwKTnYcx0QS8_fik8vs4MEgPIY
scenes-app-marketing-analytics-search-performance--keyword-post-hog-conversions-narrow--light:
- hash: v1.k794b7964.729885a1ce5323dddafe0f07c15fae674f75885be37fbb66218f5de6f0e1b476.h4LBCgyz1Y4lXOhQuQbQLBL0FSCGI-YaIRC2ygQ58mI
+ hash: v1.k794b7964.23926be16fa6ab50b5f0129aea108eb340de52a085f2160f7b317fb2f34b86ee.zLmlOqEa4SMc807cfWQ2KHKzbe5a1kU-4GU7omNCsWU
scenes-app-marketing-analytics-search-performance--landing-pages--dark:
- hash: v1.k794b7964.670dc58db7b39f1b17caaf7e56f67419bbe638079df37183b74f90766c7aa986.dDpzPiMHoqNB4bam5pfEl3S1BTp6P62F2Le-F97MF2k
+ hash: v1.k794b7964.66c18fceb68f15bb1ce8bd737843e3660191c59f0c0cbe7cf02e2cf70c37ef34.rx6JBI7wznEezLozOa4tHJJH1q1lXso3WeVovSBWwwU
scenes-app-marketing-analytics-search-performance--landing-pages--light:
- hash: v1.k794b7964.168de9991a12f9fae2674e4dd8656d7592124e7ccd94d961a02146a8bdb15fb4.t3SCmE8mTnC3UdVi35t_SQgQDxKsNr7uN38XUsOHyYk
+ hash: v1.k794b7964.d325dae0a5a8d3fcff9b5108745d7a93b4f0955acc4dd4d424d02aa72c69b317.i8TmO2TtW8KtaNS0YHHubwEiI07nfIfsMTnr05BA6WM
scenes-app-marketing-analytics-search-performance--legacy-scene--dark:
hash: v1.k794b7964.7b0c55bef8dfaac42b50b130b297bef3891085c4d66ee1c7ffcb50224a27f8f0._VNoZlIWIOKCQUyki6rytQP5OlHtGQv89uSGGzMxNng
scenes-app-marketing-analytics-search-performance--legacy-scene--light:
hash: v1.k794b7964.2b671c96efa294edb6940a97640240820fee25aaec0abfd10b8ce0536491f735.0u14hvowv9SXKzxDPXPYL2nB7-OAcqOAZeY0JnzEdLU
scenes-app-marketing-analytics-search-performance--loading--dark:
- hash: v1.k794b7964.c2efa78ddd96c45aa10bd5e6c4682aa0cafac243622b3ba0c37166506647549e.KixqIty9DjPGkbstbuoo84SKVhjZA3joqVmIayL9Ahc
+ hash: v1.k794b7964.f6e09f38a1502a3cfa1d88d61774c64e588170f84ba62f2a1a0e2f6e80dea6e0.LW-k0i4DAtag1QiiFEgIMvCRkLuHaOT4PlL5juGEggI
scenes-app-marketing-analytics-search-performance--loading--light:
- hash: v1.k794b7964.fc378cb574d1bc5300b807cb84a4da896575e595660774cd5ef7fe891a9bbe63.pdoNTfPjmBjyZjMPg4_qtOXvVt1-RakQDp2qQmKIdPY
+ hash: v1.k794b7964.b037f4bfe2201ac260832ac0404db1c33fcb1b47bb0c7eeeff5b7aa336aa1178.a5mSBje41rQnZsXA8hO22k3sOg-RrVwgt--h8JMtGqc
scenes-app-marketing-analytics-search-performance--mixed-with-position--dark:
- hash: v1.k794b7964.210933b06f2bcb00f078c3b6872b1fc0f7f827a0764bbd495b636c156fdb633b.CIN3WTYdp_975xC42BmfnAkdB-fJo4z5GJD8_48IalA
+ hash: v1.k794b7964.95bd2000c35ea1689e482196cf423e67a26aa274afb3007b2bd43a595f0baec2.hW5VCvWbVYxlRVmRDbozfYN7Bd12LbBdqALq5VqZfEs
scenes-app-marketing-analytics-search-performance--mixed-with-position--light:
- hash: v1.k794b7964.90ba9d9691f4ad58f6b76494bf466534de57e101cabfed4a417967c596261f13.PNl-786EZ-vh6rteoo4uCL1Nc7CK0YZCewdv2wG8XXI
+ hash: v1.k794b7964.9a55e5c29016c60fc359238d47f15def8b79e5f69b9102eca41a934ab4e014d2.Y08GaPIxwFwHuWFCVJJwz8JkBskeEVS5coK82A-V3XY
scenes-app-marketing-analytics-search-performance--narrow--dark:
- hash: v1.k794b7964.64ba9a070fffcfb17ed7a087f85a77befdf744b23ebe0b9b8d2f2426b63d0016.4fPcx2kPspgAdLZy-E2q1qgFUr54k2aj9zrK1LM7enM
+ hash: v1.k794b7964.fa11d1f6b10d46d99a81ae82b91a3f66c895c5546d1363a562714d443f73a50e.iQIfT-CtOKA8QeyJiQsLgiNC_MidLgo003bpLwLoGhg
scenes-app-marketing-analytics-search-performance--narrow--light:
- hash: v1.k794b7964.3adae3a77e77ec936a93733cfb2a057a94c25a87549df23f42b4a30a078e396c.LvV-K1xn14yLftnY3TlvNZxX8xLMktaIcdfUiS4H30c
+ hash: v1.k794b7964.2857314b28e9be69171ded50a9108351531e9026b8a37e5457eb3c908ee276b4.3CNZdQ3nfg5ie5iCUt7tvZQT-Ks73WNtzdPgFleKuLQ
scenes-app-marketing-analytics-search-performance--narrow-position-metrics--dark:
- hash: v1.k794b7964.c54009982c4ecfbeae686394093117e77df92cf586478d648810ff955b002913.j0Uf-K8SaGQek6ypjU7d2Un6qiM-ilkRInvIO_eAurw
+ hash: v1.k794b7964.a10e363be836b1bacfbea847357f80b987323caf54d45e7a85d3a4758ac44671.DbFPlLNt06dWI5V2w2-0luic5oaqJCAgfUS4EBlnvJ8
scenes-app-marketing-analytics-search-performance--narrow-position-metrics--light:
- hash: v1.k794b7964.1a5b05437a85b339fe72012a2e8b7ecf9343ad3d58be8f1df756b4874c49f77b.4K1otf3N65qp57kfTlUdWIGPtzS-__ZIjG_GBuqKaBs
+ hash: v1.k794b7964.0b7811f39d52b8d297f1b7f75c837bfd43df60b464024804de78ab21e18c1010.kuyz3alS3WRQreQO2U0ylB1c5BZEsaaGbkra06QdSSs
scenes-app-marketing-analytics-search-performance--new-dashboard-flag-off--dark:
hash: v1.k794b7964.b5396b32369d9e930e3db3dcd3f7e87bfbe9e813c815be0819b4a6b3f90ae63e.-n0OMQJZ2BHjrGTarQVkOln7dl6v1tLs81vsnimxTlc
scenes-app-marketing-analytics-search-performance--new-dashboard-flag-off--light:
@@ -13489,77 +13489,77 @@ snapshots:
scenes-app-marketing-analytics-search-performance--not-connected--light:
hash: v1.k794b7964.d26e073f6322a6a5408b4b612361749f47d3b4cba38a82caf6210215db7b339a.c0EL08UuZQQZ3H5Euck3vSNLJSImyrOkGtYHoZOLzH4
scenes-app-marketing-analytics-search-performance--only-google-ads--dark:
- hash: v1.k794b7964.61fcd3ecdc8d3419601ccf16c151ead53dfdfb27b5cb2cf9b746d8d912893689.PDN81XUHAt7tra0lZ1pq-SR_sGP0R4dsGmZXRgyGqXk
+ hash: v1.k794b7964.0eb88d52b8bbd3b414335b889ac09f852ed577689ea9e8bad202699bc0b224ae.bEm_2vQcGBk0coInx3APXfY4sYH3U9nVgf5-p7-rry0
scenes-app-marketing-analytics-search-performance--only-google-ads--light:
- hash: v1.k794b7964.8c53914bcc945c129137e99bc40b4da0a831268a21ff7c87751af026fdcad3ee.VOgV1u6JEQcs3YrwLMw1nsLqwejEN8AdvPUzmjnlVTM
+ hash: v1.k794b7964.4153cac0080f27b9bac12df8fab7b5a9261d3b0be0da986c6aa6b13ee573f61f.L_MBnT5_IZsKgfyy7wwcAdODQFEX5gyL3sDdLZ8E3-0
scenes-app-marketing-analytics-search-performance--organic-detail--dark:
- hash: v1.k794b7964.6d8905258eac66c4167a27d231dfd00a92d3000cc4e76a05701b84437806c52a.Rf0LOLzh5CXszxoBsNqbPjcbhfm1Vq6wZArni887lE0
+ hash: v1.k794b7964.3b54e9c3a8093291b045431bf558b1e104212c944c663535c49eb7f130090d36.XbbpYKtKqZD9kDwvlOE5csklSuc0wOGqYus9fn1KXoc
scenes-app-marketing-analytics-search-performance--organic-detail--light:
- hash: v1.k794b7964.74f0fbb65696f2213190e03b1ab4646db5ab4384daad6074ba24b97153e2c75e.-rSPfjW0AzCGfOzimNPHgqt5Ul6foTtrXvFkp9JEjjk
+ hash: v1.k794b7964.51b4f72f7f468f4f0373545a5723c9bb4e5121018cecff8c29264573babffb7b.M9Ss-qp_x_G1dG_lN4hfM2SZDwE7PuMwu_g7thLiUR0
scenes-app-marketing-analytics-search-performance--organic-traffic--dark:
- hash: v1.k794b7964.05e333c81b38939ab1ed41e2711998bb4e839535fa14a5ae0d309879e7a749e9.hvrjXmLXOlKlvCg-bOliTDtmO-B6cLVqQb5P0NKcCpg
+ hash: v1.k794b7964.bba24280bd46e267fd4d989490f5e71b72a3a9adcb54a34dba028d39921d0f1b.c_bsx0uNZ98D6NKQUEjB5C-FoccRbCgEZ7o4MebtfDU
scenes-app-marketing-analytics-search-performance--organic-traffic--light:
- hash: v1.k794b7964.a1af73515eed85314e4e69a65fa2b9260f9665eb5196293a9104e7566a771d77.4dZq7-sxWBJPxHLfwGkJAVBzKPHGMELNak-DxBjEfkU
+ hash: v1.k794b7964.9b7047f95703a25041cedc1cf524bd909d70c633ab8a6e9b8f23bd094defafba.fETHmoVYloh782x323WI8snRq0vriWBbqKT5Y5_nNe8
scenes-app-marketing-analytics-search-performance--pagination--dark:
- hash: v1.k794b7964.174749b392dab081bda379e800047e301273d42b8cb8be135f0622ca4ae58bc4.rFkERMoDVPe9S6fceGdO_0nW5BjV14NyLdwI0ZOMD58
+ hash: v1.k794b7964.28662deb8ab8582b6aedac9c2fcffba71b3ad8d78ce4f6ef34642c3b200e77b8.jOtEN_O2se2e1wt_YazWOgvrTdDsEG-EtLXbQ52_l2Y
scenes-app-marketing-analytics-search-performance--pagination--light:
- hash: v1.k794b7964.f7aea382425a4e86081df23fdd213b0dda1549de7b788ea674be9a9b910a0595.E5jPQI9oHY3ZqgcfgvONiRRjC8zpNCyZyeU96hrcW20
+ hash: v1.k794b7964.83a3730f2893e66e0bc33b6dd5759dc3f3d7707f11285799e5062fca41fecac5.SJjTNKGH5lN_w6HE-2ZOvQGsc5KlzG8Tb7XFmtG2ynY
scenes-app-marketing-analytics-search-performance--placement-unavailable--dark:
- hash: v1.k794b7964.1c0b75c3deaa157ac7a134b4f1da03bd6704e0d5d05bcc69b79de98084a65fae.y25Tf5JSGR2r5jfPDhFZKg5d2panJI4wabqugWCvEyc
+ hash: v1.k794b7964.f9e9def80c46d979849136e278e8fd2c7ee411d44768ce6c1252c44494bce39a.TcbRlHmDWyy3Ys8OvocRZZrVxRGMWM7kAsqXW1wExU8
scenes-app-marketing-analytics-search-performance--placement-unavailable--light:
- hash: v1.k794b7964.0e6aeacd2bbf55412e40811b0979b4842725f023b76de695880da3912c00bf9a.o9OvjJ1uyWh7gWuuf0XVwdMKgeoTqqjDa50FcyYqz9A
+ hash: v1.k794b7964.9132ab7a37c8519e4fb52a37d6623c8eea2969d69532342ce877bd4c31fcc184.glpephRinlnPE2nB831WYYOKL8P3gKw_4_yDgVAA24E
scenes-app-marketing-analytics-search-performance--position-metrics--dark:
- hash: v1.k794b7964.41895ba6bd450b89a4abe579595ce15838d9e0412a2d847c6a3669c173fa5b25.GcXi116J4PDN2w8ra3_ZaW8GiHmI1NFY6CSQPuaY3eQ
+ hash: v1.k794b7964.adf8c4f8927a8a0e131e3548b4d1e75798e478b8cdc7232b388f9381780902cc.2uhi2pewKTyDwAHs2W5Iuv7eZLYCQGCThyAJ9CBLE7U
scenes-app-marketing-analytics-search-performance--position-metrics--light:
- hash: v1.k794b7964.e472faf0ee0f88a451de5bd839c591ad274bc8a7501c4784537c138e8c1a2a5d.oXuLMCqiicIOfxKEpPA9Dp1Si9qZSYnlmZPd9pF4D6A
+ hash: v1.k794b7964.d5099dea2f3faf5bbb5bd4dc76bbb0224762efbfed459dc9a99c3bf19023bd67.Iz50mTZ2ak6wLLJAw0_h2QWLczqy8xwEhqjf0SrR0ng
scenes-app-marketing-analytics-search-performance--post-hog-conversions--dark:
- hash: v1.k794b7964.68290a0f312cc90774da41ee4bc42c5b78a1149313568872450a558362c85af3.NjSv8yYV2vuFbKXs_fUClYdUR5ySW_YVGKQfZdGF_ow
+ hash: v1.k794b7964.9d3e260b6c10d6ef412dd784d10973a8649a9c67995ff07c1dc4ce42b29bd886.8SXJebwFKiup-BKVjtiRUkx5D8kJiWjYjhtaaIoy5_g
scenes-app-marketing-analytics-search-performance--post-hog-conversions--light:
- hash: v1.k794b7964.e0ee7f57ed5d2903b46916480bd6245cc18d10da07b605f640229ff6e810f65c.OhWGKh7hOHlzZKcy8ItQOErISX7MIOjvdI1Hk5DSR2o
+ hash: v1.k794b7964.b467d9e76cc98cd6deede1153e31f0a7df4eb38803ce25cb1bba5234110363e0._ZM3fhXND0GV_0-dEwGKOSTnM9sf6nhOtOFlCjgNMGM
scenes-app-marketing-analytics-search-performance--post-hog-conversions-error--dark:
- hash: v1.k794b7964.c2fe4bdc0cf71a65bfdcb82f5f7e908e7b65a70da7d477dac65e607e14ffa0ef.2G83gtUeQkSKFG81rWUOP-GLOoWcqBnYIfXJJv217cA
+ hash: v1.k794b7964.dd1099a418146c6ce9ab3f6c0de67d9da53afbeed4b2c02bb31f61618d1953fe.6lqe9N_dIjJKfBVYm-FE5sei2H8Zm6tDgWCXW6a3V9I
scenes-app-marketing-analytics-search-performance--post-hog-conversions-error--light:
- hash: v1.k794b7964.add2a3256bd460ecc59d7fe2349cc1e61140d1fad2ac39ae1ef1a66998847518.0LhydWu1S6nrSYf1MD3nfCFRDtnHWisY9rkGLmWrCnI
+ hash: v1.k794b7964.504e45a97aecaf46d18afd46ec6510b4f0ff7b2f0767a02a5736f52e3372e73b.0wApiqPfT_wdhqBjtb805KsG09p7LOJDaV7upOxFyyc
scenes-app-marketing-analytics-search-performance--post-hog-conversions-flag-off--dark:
- hash: v1.k794b7964.5111bfafc2aacf55873f60e2b57a48ed71443c6d875a0d87ec0ebdb16a43b09e.s2Iex5PmItl38uDkqctuhVBu8kPtd9tjJeXPPQch2f4
+ hash: v1.k794b7964.57ddf8e3936322cdd0d1ee03d080724b9741432061e1d163dc68bf536efd6c3b.d7lJK2X79QGnSwEZpOOWNedL1zokDnE2nFAzpkyUDb4
scenes-app-marketing-analytics-search-performance--post-hog-conversions-flag-off--light:
- hash: v1.k794b7964.d522e4ff9b045b4282344b385e8ed147413abd4852928fa3a7582e954c762f02.Bm-Yq8nRZ3LMPajfZfDUTgqv11Krp-NMajWJKRYOwZM
+ hash: v1.k794b7964.a930d02587de1fce5c703c5252989403c041f78b1146ca79c7e84985ea2c4d95.MfBWPcInI-o3iC-YnGzRt09hyLB9lf0BJxaO6PYY47k
scenes-app-marketing-analytics-search-performance--post-hog-conversions-loading--dark:
- hash: v1.k794b7964.3c02c635831d791f9ea40dd5ade149da615df7fa5752149c109cdaa402f99311.aaR7qmz-ZGK9WM3PtEFPYaSDti-CT1cpL2oHc2Ez93M
+ hash: v1.k794b7964.83cd8eb8d7e06e4c8963cd26402d62e8c07c0873eeedcecf7ca2581cffe18fdc.oePz9uMCRld1fRhJ_KhJqj-HLhcclVlC1vN0vk5cEhM
scenes-app-marketing-analytics-search-performance--post-hog-conversions-loading--light:
- hash: v1.k794b7964.37b31b0dd34ff86f7492fcc3d2c33f9576abf1ef18132a2e0755698c48274b71.i19KmSqxARi4BEprX9tiXRThM95PmwmTKGgGl2GvPas
+ hash: v1.k794b7964.ba33175b26e6047e80e7a6db64fe450a4b60d469cace0ff94aeb8b262a0e5fbc.cqez2zPQ6cAAsYOCvO3U10AMbz_1xQbN2hslKNlIboY
scenes-app-marketing-analytics-search-performance--post-hog-conversions-narrow--dark:
- hash: v1.k794b7964.9be2c33359366e05067fcdaca52d857bd2e39876ed6d789df314ea278afa4ef6.37qYHco1J4zEdKmNECI3dOSY0nh7XScd0R1T_IlqsjM
+ hash: v1.k794b7964.0bec6e0ae0cfead4f1dded7000de3f5b62c5a31cbdba5bf24e8e0a80b60e3c55.AQobPc4hNJFQpCT9HAy0BUio9rmvOudC1vDbjZOdHl8
scenes-app-marketing-analytics-search-performance--post-hog-conversions-narrow--light:
- hash: v1.k794b7964.fe15428bd8cce3b4b96eeac9dceb8355e26d87cbd1a010e3e35dda02cfb61f22.o0ywulRF1-5QmL0-BCwa4RmWw4opqGFCL9oWBom_dP4
+ hash: v1.k794b7964.293e7845f845ef62b8cbff7fe7728aa8ec9126952ba971b726cea4719e73b261.RZURVa6MJ25bpvopeA5nXtijvbkd7vbmQgTmHA6am4g
scenes-app-marketing-analytics-search-performance--query-error--dark:
- hash: v1.k794b7964.3a11f95ed8775f2d45568ac1e4a5938f1f2e924bfc1d86c02165b659dc93e4ce.opQL0vSr8S9E7lYNq-f59RcmiOU-CQ_gZmyERtxEYa4
+ hash: v1.k794b7964.d0fc944d97baaaec513e4835c75da65ca0e5b18f514d0a79fbba82ad83e04314.6Zg4JqAeBdtxqnzy-a_Guq6XQls3fnOB2scbPgO82tI
scenes-app-marketing-analytics-search-performance--query-error--light:
- hash: v1.k794b7964.7bccf040abf349630edc89e3bcb03b421d284655f8a3e24a0f3aa4b6e63d7fcb.l_KzlyEF4Su2JWkOGLQbh0niwLXErXAWJpqZDg60Fs4
+ hash: v1.k794b7964.02a2cafd8aab2f793ffa8cdf581715462091b93e79af0581965918d15b590091.Vyw3RcZhBxpWja2isgoWUtyA4CRabRdd3islby-yP44
scenes-app-marketing-analytics-search-performance--sources-error--dark:
hash: v1.k794b7964.874d4819628e188381b6b9c0c7799b572d512e05a3ef968fd5bce45fe72df26b.34-FVEAK6yWUfN6uBxYIlsg7eEov6vFa4oCCKG82J7s
scenes-app-marketing-analytics-search-performance--sources-error--light:
hash: v1.k794b7964.159cf8b9647d98ad2c63ce40109229e9ffd0352de1d98167b9446794a947ff21.gupk_qTVysxLVkierQb3CrLvQ4-AtOFEXoQ4yuxHtlU
scenes-app-marketing-analytics-search-performance--stale-aggregate--dark:
- hash: v1.k794b7964.90fa045981c73c2e3c4d238b7b01390b3952929949e97875cf57290bfb1f06c2.s1uk22kEgUAr_2Oc2ug_wlSe8k3_n7RrY0UCPc1v8qM
+ hash: v1.k794b7964.a77472d30636ecc215619bf6d3f0b7d1fada8aecfb714d434bf75136b529bc01.jlFgA4ebmhvigcElkUxhfEO59IEi58_5qZgjd80vYw4
scenes-app-marketing-analytics-search-performance--stale-aggregate--light:
- hash: v1.k794b7964.1545abebcc88817c0313ecad3f23b85381a475714f0acc6f53fa5314880ac2a0.x7wyBzn5C74hVodMjZ3G-MVaGoPr7rNDfZKy0CBhIxI
+ hash: v1.k794b7964.57c12ea63159ae99b39cd2716b19349c65c0481646b295240714ad99dbbaf63d.nKN5AuqiS4IuIQQhPM9g7wtpCE1hPww3KpRhy32SNJ0
scenes-app-marketing-analytics-search-performance--unavailable-sources--dark:
- hash: v1.k794b7964.f6115da5bb35e65e9e48dda2f2caa8c3ea2c5d29b2e820f0a151f544f9d9c6c6.JiUwR7QskSO2lnI3Iq0P_NclgAPQye-fndfCTAjqDsQ
+ hash: v1.k794b7964.fa4fe0412be3d31f33832c2eb5e727d972a4f5eb3f41c0d73622611c80399558.z7ArOIvhBcC_d1EcZVzElgucZzXtnY5Tk3_1gLgqTZw
scenes-app-marketing-analytics-search-performance--unavailable-sources--light:
- hash: v1.k794b7964.c71766ec41c46d47dd676129e4f3b837ecab3cc59a65af160c45c0c0a809f922.qbs-hSZcGidbcdyt3ggbsM6icZ28TM29U78ALMAktfE
+ hash: v1.k794b7964.bec87bcf24edaf411fbd91e2c9c04015953fff364b26903ecad5a0306765815d.W_DYme6EP-v-EC9YoRzjmRzma587O23qf86q154kVys
scenes-app-marketing-analytics-search-performance--unavailable-sources-narrow--dark:
- hash: v1.k794b7964.b8c97421239d5053d4ae1f01901a73254eee804c8dd722f71062593004d23422.HCopq5hkJ4Ru-bHW4fdMVo0bK3WC_R-Kn5XZ-NYFPKo
+ hash: v1.k794b7964.30b8411b0eef4b9e3b040c8753971a2f0629b46e8289bf98f1647973248056ac.vdoyKnRJ1TWDWVKLEEudKI2gBqWa2oLW0azLtDjSShg
scenes-app-marketing-analytics-search-performance--unavailable-sources-narrow--light:
- hash: v1.k794b7964.7f7d654e0ec8b3c7bd0709a979fce22876760760ccc966528354484f84a5f139.A1RAOnCcgSPTsbI7KQYj06cYSVRXK8cRvdT2bk8SvO4
+ hash: v1.k794b7964.1fc7fe55e455e2dfec1650a30127c8412a47d5af6ae4cc82dd7aafb1133231d1.fgzZ8_kBgMiQoQBS9SW4PIsfkzdwn4pHcLCSPSHMDrU
scenes-app-marketing-analytics-search-performance--wrapped-landing-pages--dark:
- hash: v1.k794b7964.7d438daa3a2fe9a4697b6ebdf8d0d24fac23ff1418d5c965795c37e611f31164.rVRt10r2cislmBy5VB6PEI4Xw2oepBBXxjIXaJDEC6o
+ hash: v1.k794b7964.b0bd0c62ebc021c08fbf3c387e6a6ceb2cfd4b10f961d246209ad0bf1504fcb4.LNoUKwNj32Ba1CIO-wtpVh0PorSj2ISoNzAyAcPR7Dg
scenes-app-marketing-analytics-search-performance--wrapped-landing-pages--light:
- hash: v1.k794b7964.29d1c408a06c54e486449f064646ac62f3de65cb9ee1ea1ad0580af6939f495f.fA1icnZhhOOZAYPFWj39Ol-_B6jaslgDFRUJz61u-g4
+ hash: v1.k794b7964.2c5ee901195812f03af61b134eabdc227486c425d5a96c2e5ed992e62a9a1421.fPjI608E8VdRpON6A8UyhI5aoM9HcuvankcZmPVAmik
scenes-app-marketing-analytics-search-performance--wrapped-landing-pages-narrow--dark:
- hash: v1.k794b7964.7bf3e39caad9ca522ace9ea9d72e0f4e2abee62f48a72674900e80e752677637.v7TQ-LZtvMqtBW6ZQUGmatobaIsQd1FpzVgnzjIsqmI
+ hash: v1.k794b7964.9a5f2ce539aa08cd050a59644c69711a23d4b8ca1065490cf165087c4b32c3b5.wnGh2z5HA1UtIgTLHmdK_zgvMCxZB-dozFZu0ffg228
scenes-app-marketing-analytics-search-performance--wrapped-landing-pages-narrow--light:
- hash: v1.k794b7964.bc7e930ff65d3898a309bf63b7dedafb78c498d14e2ddbce421ce701b4114b19.4vEUxz-8PhpNNO7we_L1k3W-USCIj0sfcsCjdEL3Um4
+ hash: v1.k794b7964.9e5842b790ad00801abdebc4a1dc944d705a632e05c25d5f3b8bb8d56cebc3dd.YWAIAUUyeYBjzMo9G1a8tQWIs2502pvSpGDucE-lh94
scenes-app-marketing-analytics-source-onboarding--ad-performance-data-available--dark:
hash: v1.k794b7964.52d793e434ed135a17252c76b796cc7f059342600f7ea6c95241ab76669a2441.FveMgmXg9otKomgnoJbhm7TP1HJyln_odWNWqALJEiw
scenes-app-marketing-analytics-source-onboarding--ad-performance-data-available--light:
@@ -13589,9 +13589,9 @@ snapshots:
scenes-app-marketing-analytics-source-onboarding--dashboard-scanning-with-search--light:
hash: v1.k794b7964.82af8d7fc971f03bf36739952b9f436cdae9e03b052fba2f3c83af1428120b76.m-VTiI3gRppO6oQNhsW4BkfvmkEJaZcqKiBVq_vSWzA
scenes-app-marketing-analytics-source-onboarding--dashboard-scanning-with-search-console--dark:
- hash: v1.k794b7964.f6c3227540c1daf5266cc94e80d1626e8a192906fb1f688a18c7457de0b9575e.htWZS2VejTaqYTr-fZioOWMdpole1T-s1QlBB09ls9U
+ hash: v1.k794b7964.f70d5ae3e5c95415f5e48a683674cf74d72bba6173c59757825fa1017c13a997.mwCu316WCiw_EAtoFcy2jopXz7hxxtGqspJq-875xh0
scenes-app-marketing-analytics-source-onboarding--dashboard-scanning-with-search-console--light:
- hash: v1.k794b7964.96925f009594f797806c47cbc799946341b4e4800844baacef5f8951ad434cf9.P_bQfBSfYVpIeEPw6WGMqzloDECX40vH57tb3fvuPxM
+ hash: v1.k794b7964.583c0ea77d053b8dcf1385c40c1bed2427c1a95a85e5a124b14abd5daef38210.yoGV2VudMiCWP_RX_qPG2VByF29IAgz-Y0Z1AVade7M
scenes-app-marketing-analytics-source-onboarding--dashboard-with-ads-and-search-console--dark:
hash: v1.k794b7964.a8368267f7ff5b455100231b3a5770bf6f66cdf8ca5bbe4ec9e1664aebab9210.18-g90ixUzMnIiIvHSKBjwgXT2uq9XHnqbKMS67BvZ8
scenes-app-marketing-analytics-source-onboarding--dashboard-with-ads-and-search-console--light:
@@ -13601,13 +13601,13 @@ snapshots:
scenes-app-marketing-analytics-source-onboarding--dashboard-with-ads-only--light:
hash: v1.k794b7964.b000e0bdbf58908e885760cbd2193ebf7bc0af5d3c227dbfff89d47e0e37e5d4.6rIxgkPccXr32_WjurrJPlMhoCk0Daq29iTUp4VAL3U
scenes-app-marketing-analytics-source-onboarding--dashboard-with-ads-syncing-without-search-console--dark:
- hash: v1.k794b7964.bfa13529bdb940ef1cd344b2bf11c58522804280d0e0dd141008411660a53505.ApfEsWw3lxynpDaRYL_pRTblq_-Yucp5d6hwOFDmY9k
+ hash: v1.k794b7964.19c7794b02de1c46f660c0cc830fca420287335948cedd685da7d090d2aaa26f.kdeCMLqbb79A1_l9tEcXGXcCGjyQK-FUHPoHHuMJDZY
scenes-app-marketing-analytics-source-onboarding--dashboard-with-ads-syncing-without-search-console--light:
- hash: v1.k794b7964.3f5301fe8cf282bd4f53876e3e737f93c0efbb84fb31bd89588aba81002f512d.nGEExJIV8BcMR8Csi5eBnZ4ulUzUjmy94D6mye-Gc4A
+ hash: v1.k794b7964.148af8b72e6c4a528bd199ded6862c69dd7391b7445fb0226ef7b67203803808.Ss5eJaj6hVKjF8z4FMTwh5lyfftAkJN9AZAKQuh973k
scenes-app-marketing-analytics-source-onboarding--dashboard-with-search-console-only--dark:
- hash: v1.k794b7964.cf41d933958f7e522462c9a74b07f227c533241d6645a49446d4cada554316a1.UlI5XySqlFud8grNCLsDY9z6Af2hSWyf0wlOfR4xvI0
+ hash: v1.k794b7964.732cf7d32b7f5810494d5d4ced98f45277d062e0d3cb0940399b60aa15410eda.Dokh-HIrEnIFWZ5Os3ZVCiX_evKYF0tzPvBSCshZxSg
scenes-app-marketing-analytics-source-onboarding--dashboard-with-search-console-only--light:
- hash: v1.k794b7964.b7e888e590938f80cebd4f7528d9357b940c25163efaf90b7817ad525a1b2978.e0kgVOmH11vweGCfRc8X1y9sJ77S0-ZP12vveKXN6DA
+ hash: v1.k794b7964.63017ee792898686c3c65125faf061c8898333ad3645a9a9b375d20d661739ac.HpO0hDbthkCitHdEx-vudVazsd2D38qOLqhGV8x669A
scenes-app-marketing-analytics-source-onboarding--legacy-source-connection-step--dark:
hash: v1.k794b7964.cbb45878988736b927d4ac4ee322346195265bda2c31b87ab82828e6a079004a.molamC87IHXFTcKHUOOS3JWbIfTDyuC7gXMl8m_rDAU
scenes-app-marketing-analytics-source-onboarding--legacy-source-connection-step--light:
diff --git a/products/marketing_analytics/frontend/search/SearchPerformanceTab.stories.tsx b/products/marketing_analytics/frontend/search/SearchPerformanceTab.stories.tsx
index 7e1723f2c2b0..d2c72960d08b 100644
--- a/products/marketing_analytics/frontend/search/SearchPerformanceTab.stories.tsx
+++ b/products/marketing_analytics/frontend/search/SearchPerformanceTab.stories.tsx
@@ -516,8 +516,9 @@ export const StaleAggregate: Story = {
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement)
- await expect(await canvas.findByText(/Showing query-and-page data instead/)).toBeVisible()
- await expect(await canvas.findByText('1,240')).toBeVisible()
+ await expect(await canvas.findByText(/search_analytics_by_query is out of date/)).toBeVisible()
+ await expect(await canvas.findByText('840')).toBeVisible()
+ await expect(canvas.queryByText('1,240')).toBeNull()
},
}
export const UnavailableSources: Story = {
diff --git a/products/marketing_analytics/frontend/search/SearchPerformanceTab.tsx b/products/marketing_analytics/frontend/search/SearchPerformanceTab.tsx
index a7d6e1eb61c3..89833d001da7 100644
--- a/products/marketing_analytics/frontend/search/SearchPerformanceTab.tsx
+++ b/products/marketing_analytics/frontend/search/SearchPerformanceTab.tsx
@@ -172,8 +172,8 @@ export function SearchPerformanceTab({
{breakdown === 'keyword' &&
'Paid rows show targeted keywords; organic rows show actual Google queries. '}
Reported conversions use the ad platform's attribution. Google Search Console does not
- report spend or conversions, and can omit low-volume queries. Organic positions are
- weighted by impressions. Hover over a change to see its comparison value.
+ report spend or conversions, and can omit queries. Organic positions are weighted by
+ impressions. Hover over a change to see its comparison value.
</p>
</>
)}
diff --git a/products/marketing_analytics/frontend/search/searchPerformance.test.ts b/products/marketing_analytics/frontend/search/searchPerformance.test.ts
index 13aaece68244..779ef1aff596 100644
--- a/products/marketing_analytics/frontend/search/searchPerformance.test.ts
+++ b/products/marketing_analytics/frontend/search/searchPerformance.test.ts
@@ -58,11 +58,7 @@ describe('search performance sources', () => {
[
'GoogleSearchConsole',
[schema('search_analytics_by_query', false), schema('search_analytics_by_query_page')],
- {
- sourceType: 'GoogleSearchConsole',
- statsTable: 'example.search_analytics_by_query_page',
- queryPageTable: true,
- },
+ null,
],
['GoogleSearchConsole', [schema('search_analytics_by_query_page', true, false)], null],
])('requires synced keyword tables for %s', (source_type, schemas, expected) => {
@@ -94,6 +90,8 @@ describe('search performance sources', () => {
'example.search_analytics_by_query_page',
],
['GoogleSearchConsole', ['search_analytics_by_query'], 'keyword', true, undefined],
+ ['GoogleSearchConsole', ['search_analytics_by_query_page'], 'keyword', false, undefined],
+ ['GoogleSearchConsole', ['search_analytics_by_query_page'], 'page', false, undefined],
] as const)('uses the right table for %s %s %s details=%s', (source_type, schemas, breakdown, detail, expected) => {
expect(
searchPerformanceSource(
@@ -149,27 +147,30 @@ describe('search performance sources', () => {
expect(searchPerformanceSourceNotice(source)).toBeNull()
})
- it.each(['keyword', 'page'] as const)('uses fresh query-page data instead of a stale %s aggregate', (breakdown) => {
- const source = {
- source_type: 'GoogleSearchConsole',
- schemas: [
- { ...schema('search_analytics_by_query'), last_synced_at: dayjs('2025-02-10T12:00:00Z') },
- { ...schema('search_analytics_by_page'), last_synced_at: dayjs('2025-02-10T12:00:00Z') },
- schema('search_analytics_by_query_page'),
- ],
- } as ExternalDataSource
- expect(searchPerformanceSource(source, breakdown)).toEqual({
- sourceType: 'GoogleSearchConsole',
- statsTable: 'example.search_analytics_by_query_page',
- queryPageTable: true,
- })
- expect(searchPerformanceSourceNotice(source, breakdown)).toContain('Showing query-and-page data instead')
- expect(searchPerformanceSourceNotice(source, breakdown)).toContain('Totals may differ')
- source.schemas[2].last_synced_at = dayjs('2025-02-10T12:00:00Z')
- expect(searchPerformanceSource(source, breakdown)).toBeNull()
- expect(searchPerformanceSource(source, breakdown, true)).toBeNull()
- expect(searchPerformanceSourceNotice(source, breakdown, true)).toContain('out of date')
- })
+ it.each(['keyword', 'page'] as const)(
+ 'keeps %s metrics unavailable when its dedicated table is stale',
+ (breakdown) => {
+ const source = {
+ source_type: 'GoogleSearchConsole',
+ schemas: [
+ { ...schema('search_analytics_by_query'), last_synced_at: dayjs('2025-02-10T12:00:00Z') },
+ { ...schema('search_analytics_by_page'), last_synced_at: dayjs('2025-02-10T12:00:00Z') },
+ schema('search_analytics_by_query_page'),
+ ],
+ } as ExternalDataSource
+ expect(searchPerformanceSource(source, breakdown)).toBeNull()
+ expect(searchPerformanceSourceNotice(source, breakdown)).toContain('out of date')
+ expect(searchPerformanceSource(source, breakdown, true)).toEqual({
+ sourceType: 'GoogleSearchConsole',
+ statsTable: 'example.search_analytics_by_query_page',
+ queryPageTable: true,
+ })
+ source.schemas[2].last_synced_at = dayjs('2025-02-10T12:00:00Z')
+ expect(searchPerformanceSource(source, breakdown)).toBeNull()
+ expect(searchPerformanceSource(source, breakdown, true)).toBeNull()
+ expect(searchPerformanceSourceNotice(source, breakdown, true)).toContain('out of date')
+ }
+ )
it.each([
['24hour', '2025-02-13T12:00:00Z', true],
diff --git a/products/marketing_analytics/frontend/search/searchPerformance.ts b/products/marketing_analytics/frontend/search/searchPerformance.ts
index 189850e14e89..fc70aa00710c 100644
--- a/products/marketing_analytics/frontend/search/searchPerformance.ts
+++ b/products/marketing_analytics/frontend/search/searchPerformance.ts
@@ -56,10 +56,7 @@ function searchTableNames(source: ExternalDataSource, breakdown: SearchBreakdown
if (source.source_type === 'GoogleSearchConsole') {
return detail
? ['search_analytics_by_query_page']
- : [
- breakdown === 'page' ? 'search_analytics_by_page' : 'search_analytics_by_query',
- 'search_analytics_by_query_page',
- ]
+ : [breakdown === 'page' ? 'search_analytics_by_page' : 'search_analytics_by_query']
}
if (source.source_type === 'GoogleAds') {
return breakdown === 'page' ? ['landing_page_stats'] : ['keyword', 'keyword_stats']
@@ -80,10 +77,7 @@ export function searchPerformanceSource(
}
const tables = searchTableNames(source, breakdown, detail).map(table)
if (source.source_type === 'GoogleSearchConsole') {
- const index = tables.findIndex(Boolean)
- return index < 0
- ? null
- : { sourceType: 'GoogleSearchConsole', statsTable: tables[index]!, queryPageTable: detail || index === 1 }
+ return tables[0] ? { sourceType: 'GoogleSearchConsole', statsTable: tables[0], queryPageTable: detail } : null
}
if (tables.length === 0 || tables.some((table) => !table)) {
return null
@@ -110,8 +104,7 @@ export function searchPerformanceSourceNotice(
detail = false
): string | null {
const querySource = searchPerformanceSource(source, breakdown, detail)
- const fallback = querySource?.queryPageTable && !detail
- if (querySource && !fallback) {
+ if (querySource) {
if (source.source_type === 'GoogleAds' && breakdown === 'keyword' && !querySource.placementTable) {
const status = searchTableStatus(source.schemas.find((schema) => schema.name === 'keyword_placement_stats'))
const message = {
@@ -149,7 +142,7 @@ export function searchPerformanceSourceNotice(
}[status]
})
const label = source.description || SEARCH_PLATFORM_LABELS[source.source_type as SearchPlatform]
- return `${label}: ${issues.join(' ')}${fallback ? ' Showing query-and-page data instead. Totals may differ from the dedicated query or page table.' : ' Data from this source will appear when the tables are ready.'}`
+ return `${label}: ${issues.join(' ')}`
}
export const SEARCH_SOURCE_TYPES = ['GoogleAds', 'BingAds', 'GoogleSearchConsole']