From e0a7b3829017ef8e969f3deba03ad1886900e31e Mon Sep 17 00:00:00 2001 From: Trask Stalnaker Date: Fri, 12 Jul 2024 08:11:30 -0700 Subject: [PATCH] db.query.text IN-clauses MAY be collapsed --- docs/database/database-spans.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/database/database-spans.md b/docs/database/database-spans.md index 3a38d4def6..c9f164ab49 100644 --- a/docs/database/database-spans.md +++ b/docs/database/database-spans.md @@ -250,6 +250,10 @@ in which case the instrumentation MAY choose a different placeholder. Placeholders in a parameterized query SHOULD not be sanitized. E.g. `where id = $1` can be captured as is. +[IN-clauses](https://en.wikipedia.org/wiki/Where_(SQL)#IN) MAY be collapsed during sanitization, +e.g. from `IN (?, ?, ?, ?)` to `IN (?)`, as this can help with extremely long IN-clauses, +and can help control cardinality for users who choose to (optionally) add `db.query.text` to their metric attributes. + ## Semantic Conventions for specific database technologies More specific Semantic Conventions are defined for the following database technologies: