Title: Prisma Spans don't include SQL · Issue #5780 · getsentry/sentry-javascript · GitHub
Open Graph Title: Prisma Spans don't include SQL · Issue #5780 · getsentry/sentry-javascript
X Title: Prisma Spans don't include SQL · Issue #5780 · getsentry/sentry-javascript
Description: Problem Statement Prisma spans show the query type in the description instead of the SQL that was generated (findMany, findUnique, update, etc...) Other SDKs (Python, Ruby, PHP) for specific frameworks (Django, Rails, Laravel) show the a...
Open Graph Description: Problem Statement Prisma spans show the query type in the description instead of the SQL that was generated (findMany, findUnique, update, etc...) Other SDKs (Python, Ruby, PHP) for specific framew...
X Description: Problem Statement Prisma spans show the query type in the description instead of the SQL that was generated (findMany, findUnique, update, etc...) Other SDKs (Python, Ruby, PHP) for specific framew...
Opengraph URL: https://github.com/getsentry/sentry-javascript/issues/5780
X: @github
Domain: github.com
IPv4 address: 140.82.113.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Prisma Spans don't include SQL","articleBody":"### Problem Statement\n\nPrisma spans show the query type in the description instead of the SQL that was generated (`findMany`, `findUnique`, `update`, etc...)\r\n\r\nOther SDKs (Python, Ruby, PHP) for specific frameworks (Django, Rails, Laravel) show the actual SQL that's being generated. Having the SQL makes it easy to see what's happening under the hood and solve things like n+1 queries.\n\n### Solution Brainstorm\n\nHaving the ORM details is useful, especially for finding them in the codebase.\r\n\r\n**1. Update the span description**\r\nWe could update the span description to include the raw SQL `ORM call - raw SQL`\r\n\r\ne.g. `Expense findOne - SELECT `expenses_expense`.* FROM `expenses_expense` WHERE `expenses_expense`.id = %s\r\n\r\n**2. Update the span op**\r\nIf we wanted to keep it similar to the other SDKs we could have the description as just the raw SQL call and update the Span op to include the ORM call.\r\n\r\nspan.op: `db.prisma.findOne`\r\nspan.description: `SELECT `expenses_expense`.* FROM `expenses_expense` WHERE `expenses_expense`.id = %s`\r\n","author":{"url":"https://github.com/silent1mezzo","@type":"Person","name":"silent1mezzo"},"datePublished":"2022-09-20T11:28:28Z","url":"https://github.com/getsentry/sentry-javascript/issues/5780"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:069e35f8-24f2-4b2f-3ee5-983f9e33f0d5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A768:1BE13B:6B4AC6:90F0BC:6B04A413 |
| html-safe-nonce | 77910217ea35a163759f03e84c1b82334221fce8f8415dda8ffc5a4b9f2c2924 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNzY4OjFCRTEzQjo2QjRBQzY6OTBGMEJDOjZCMDRBNDEzIiwidmlzaXRvcl9pZCI6IjIwNTg3MDA5NTQ4OTA3MDc5ODciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | f77d4557f360dd224cb6045e647424adfcf90edb0e02879f8634bfd1f480099d |
| hovercard-subject-tag | issue:1379260385 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getsentry/sentry-javascript/5780/issue_layout |
| twitter:image | https://opengraph.githubassets.com/895a8a97b6a2c1511667c45aece71c412249467a88cfe0cfc62d403a572ac8c5/getsentry/sentry-javascript/issues/5780 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/895a8a97b6a2c1511667c45aece71c412249467a88cfe0cfc62d403a572ac8c5/getsentry/sentry-javascript/issues/5780 |
| og:image:alt | Problem Statement Prisma spans show the query type in the description instead of the SQL that was generated (findMany, findUnique, update, etc...) Other SDKs (Python, Ruby, PHP) for specific framew... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | silent1mezzo |
| hostname | github.com |
| expected-hostname | github.com |
| None | 188497a0f45a7aa8f7c866faa1950d1a7f8d82b59416adf549b222ad1d1dd19b |
| turbo-cache-control | no-preview |
| go-import | github.com/getsentry/sentry-javascript git https://github.com/getsentry/sentry-javascript.git |
| octolytics-dimension-user_id | 1396951 |
| octolytics-dimension-user_login | getsentry |
| octolytics-dimension-repository_id | 3328572 |
| octolytics-dimension-repository_nwo | getsentry/sentry-javascript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 3328572 |
| octolytics-dimension-repository_network_root_nwo | getsentry/sentry-javascript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 557cfbac6cdb532730c95c90f2cefdc0c4128029 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width