diff --git a/lib/queries.js b/lib/queries.js index 3a62a37f..2411095a 100644 --- a/lib/queries.js +++ b/lib/queries.js @@ -65,9 +65,11 @@ export function getFilterQuery(table, filters = {}, params = []) { switch (key) { case 'url': if (table === 'session' || table === 'pageview' || table === 'event') { - arr.push(`and (${table}.${key}=$${params.length + 1} or ${table}.${key} like $${params.length + 2})`); + arr.push(`and (${table}.${key}=$${params.length + 1} or ${table}.${key} like $${params.length + 2} or (${table}.${key} like $${params.length + 3} and ${table}.${key} not like $${params.length + 4}))`); params.push(decodeURIComponent(value)); params.push(`${decodeURIComponent(value)}?%`); + params.push(`%${decodeURIComponent(value)}#%`); + params.push(`%${decodeURIComponent(value)}#/%`); } break;