Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

stash

Steven Teyda3d0de88c27
diff --git a/packages/tinybird/endpoints/v2_top_urls.pipe b/packages/tinybird/endpoints/v2_top_urls.pipe
index 7407b5e13e..b2833c9a72 100644
--- a/packages/tinybird/endpoints/v2_top_urls.pipe
+++ b/packages/tinybird/endpoints/v2_top_urls.pipe
@@ -46,7 +46,9 @@ SQL >
{% end %}
WHERE
url != ''
- {% if defined(linkId) %} AND link_id = {{ String(linkId) }} {% end %}
+ {% if defined(linkIds) %} AND link_id IN {{ Array(linkIds, 'String') }}
+ {% elif defined(linkId) %} AND link_id = {{ linkId }}
+ {% end %}
{% if defined(qr) %} AND qr = {{ Boolean(qr) }} {% end %}
{% if defined(continent) %} AND continent = {{ continent }} {% end %}
{% if defined(country) %} AND country = {{ country }} {% end %}
diff --git a/packages/tinybird/pipes/v2_top_urls.pipe b/packages/tinybird/pipes/v2_top_urls.pipe
index 2ce0f69818..38b78cb5de 100644
--- a/packages/tinybird/pipes/v2_top_urls.pipe
+++ b/packages/tinybird/pipes/v2_top_urls.pipe
@@ -44,7 +44,9 @@ SQL >
{% end %}
WHERE
url != ''
- {% if defined(linkId) %} AND link_id = {{ String(linkId) }} {% end %}
+ {% if defined(linkIds) %} AND link_id IN {{ Array(linkIds, 'String') }}
+ {% elif defined(linkId) %} AND link_id = {{ linkId }}
+ {% end %}
{% if defined(qr) %} AND qr = {{ Boolean(qr) }} {% end %}
{% if defined(continent) %} AND continent = {{ continent }} {% end %}
{% if defined(country) %} AND country = {{ country }} {% end %}