Skip to content
PeriplusDocs
Open app
Extract a field from product pages

Extract a field from product pages

Collect displayed prices, availability labels, or other repeated fields from a known page template.

SQL
SELECT capture_id, url, observed_at,
       node_text(capture_id, query_selector(capture_id, '.price')) AS price_text
FROM captures
WHERE startsWith(url, 'https://example.com/products/')
  AND capture_id IS NOT NULL
ORDER BY observed_at DESC, capture_id DESC
LIMIT 20;
Open in SQL workspaceLoads without running

What you get

The first matching price text for each sampled capture, alongside its source and observation time. Keep provenance with extracted values so you can investigate them later.

Illustrative output · selected columns, not live results

urlobserved_atprice_text
https://example.com/products/widget2026-09-24 09:00 UTC€45.00
https://example.com/products/widget2026-09-22 09:00 UTC€40.00

Adapt it

Replace the host, path, and .price selector with the actual template. You can apply the same pattern to job titles, event dates, or availability labels.

Notes

The example returns text, not normalized currency amounts. A selector may match a sale price or unrelated element; inspect samples before treating the extracted values as reliable results. Multiple captures of a URL remain separate rows.

Learn about source identities