MCPcopy Index your code
hub / github.com/bytebase/bytebase / completionCandidateText

Function completionCandidateText

backend/plugin/parser/redshift/completion.go:253–260  ·  view source on GitHub ↗
(candidate redshiftcompletion.Candidate)

Source from the content-addressed store, hash-verified

251}
252
253func completionCandidateText(candidate redshiftcompletion.Candidate) string {
254 switch candidate.Type {
255 case redshiftcompletion.CandidateKeyword, redshiftcompletion.CandidateFunction:
256 return candidate.Text
257 default:
258 return quotedIdentifierIfNeeded(candidate.Text)
259 }
260}
261
262func quotedIdentifierIfNeeded(s string) string {
263 if strings.ToLower(s) != s || !isValidUnquotedIdentifier(s) {

Callers 1

CompletionFunction · 0.85

Calls 1

quotedIdentifierIfNeededFunction · 0.85

Tested by

no test coverage detected