Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL Editor traceID link queries wrong table #874

Closed
ryn9 opened this issue Jun 21, 2024 · 1 comment
Closed

SQL Editor traceID link queries wrong table #874

ryn9 opened this issue Jun 21, 2024 · 1 comment
Assignees
Labels
datasource/ClickHouse type/bug Something isn't working

Comments

@ryn9
Copy link

ryn9 commented Jun 21, 2024

What happened:

Explore > Editor Type: SQL Editor > Query Type: table

Query:

SELECT
    TraceId AS traceID,
    SpanId AS spanID,
    SpanName AS operationName,
    ParentSpanId AS parentSpanID,
    ServiceName AS serviceName,
    Duration / 1000000 AS duration,
    Timestamp AS startTime,
    arrayMap(key -> map('key', key, 'value', SpanAttributes[key]), mapKeys(SpanAttributes)) AS tags,
    arrayMap(key -> map('key', key, 'value', ResourceAttributes[key]), mapKeys(ResourceAttributes)) AS serviceTags
FROM otel_traces
WHERE ( Timestamp >= $__fromTime AND Timestamp <= $__toTime )
 AND ( Duration > 0 )
ORDER BY startTime ASC

( reference: https://grafana.com/grafana/plugins/grafana-clickhouse-datasource/ "Visualizing traces with the Traces Panel" )

Clicking on the traceID link opens a trace panel, but errors:
error querying the database: code: 60, message: Table MY_DB_NAME.MY_DB_NAME does not exist

Note:
Datasource's Traces configuration is configured with
Default trace database: MY_DB_NAME
Default trace table: otel_traces
use otel is enabled

What you expected to happen:

I would expect this to correctly load the trace panel

How to reproduce it (as minimally and precisely as possible):

Please see above

Screenshots

Anything else we need to know?:

Environment:

  • Grafana version: v11.0.0 (83b9528bce)
  • Plugin version: v4.1.0
  • OS Grafana is installed on: linux/docker
  • User OS & Browser:
  • Others:
@ryn9 ryn9 added datasource/ClickHouse type/bug Something isn't working labels Jun 21, 2024
@SpencerTorres SpencerTorres self-assigned this Jun 25, 2024
@alyssabull alyssabull moved this from Incoming to Backlog in Partner Datasources Jun 25, 2024
@ryn9
Copy link
Author

ryn9 commented Jun 26, 2024

working now with latest grafana and latest plugin..

@ryn9 ryn9 closed this as completed Jun 26, 2024
@github-project-automation github-project-automation bot moved this from Backlog to Done in Partner Datasources Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
datasource/ClickHouse type/bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

2 participants