Skip to content

Commit

Permalink
Move symbolsToEscape
Browse files Browse the repository at this point in the history
  • Loading branch information
nathan-artie committed May 1, 2024
1 parent 06ccd1d commit b2453ba
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 3 additions & 0 deletions lib/sql/dialect.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ type SnowflakeDialect struct {
UppercaseEscNames bool
}

// symbolsToEscape are additional keywords that we need to escape
var symbolsToEscape = []string{":"}

func (sd SnowflakeDialect) NeedsEscaping(name string) bool {
if sd.UppercaseEscNames {
// If uppercaseEscNames is true then we will escape all identifiers that do not start with the Artie priefix.
Expand Down
3 changes: 0 additions & 3 deletions lib/sql/escape.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ import (
"github.com/artie-labs/transfer/lib/config/constants"
)

// symbolsToEscape are additional keywords that we need to escape
var symbolsToEscape = []string{":"}

func EscapeNameIfNecessary(name string, uppercaseEscNames bool, destKind constants.DestinationKind) string {
var dialect = dialectFor(destKind, uppercaseEscNames)

Expand Down

0 comments on commit b2453ba

Please sign in to comment.