influxdata / influxdata/influxql

bug / lack of QuoteIdent

Open
#45 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
170
Forks
50
PR merge metrics
No merged PRs in 30d

Description

Hi,

There is a minor bug in the `String` method here:

https://github.com/influxdata/influxql/blob/b9e521f450818862cab2bc31a30293b192439728/ast.go#L2602

Should be:
```
if s.Database != "" {
_, _ = buf.WriteString(" ON ")
_, _ = buf.WriteString(QuoteIdent(s.Database))
}
```
See:
https://github.com/influxdata/influxql/blob/master/ast.go#L2533

Contributor guide

No contributing guide indexed for this repository

Research direction

Open ast.go at the String method around the referenced line and compare it with the master version around line 2533. Confirm that the database name is written through QuoteIdent, then verify that the generated ON clause uses the quoted identifier.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
databases
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.