diff options
| author | LazyDBA247-Anyvision <yonin@anyvision.co> | 2021-02-14 13:14:36 +0200 |
|---|---|---|
| committer | LazyDBA247-Anyvision <yonin@anyvision.co> | 2021-02-14 13:14:36 +0200 |
| commit | 51b4963e2eaa6caff8ed4702453b9af371cf6914 (patch) | |
| tree | c557e1515886185c5dbb0bffb9b7bec43a565174 /weed/filer/postgres/postgres_store.go | |
| parent | 876dbe3d26138c26e0e9869874c0d0b18aec7d1e (diff) | |
| download | seaweedfs-51b4963e2eaa6caff8ed4702453b9af371cf6914.tar.xz seaweedfs-51b4963e2eaa6caff8ed4702453b9af371cf6914.zip | |
postgres2 & memsql2
add escape (quote identifiers) for the dynamic sql
so tables (collections) with special characters will work.
Diffstat (limited to 'weed/filer/postgres/postgres_store.go')
| -rw-r--r-- | weed/filer/postgres/postgres_store.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/weed/filer/postgres/postgres_store.go b/weed/filer/postgres/postgres_store.go index 27c6278c7..6e0d05315 100644 --- a/weed/filer/postgres/postgres_store.go +++ b/weed/filer/postgres/postgres_store.go @@ -45,7 +45,7 @@ func (store *PostgresStore) initialize(user, password, hostname string, port int store.SupportBucketTable = false store.SqlGenerator = &SqlGenPostgres{ CreateTableSqlTemplate: "", - DropTableSqlTemplate: "drop table %s", + DropTableSqlTemplate: `drop table "%s"`, } sqlUrl := fmt.Sprintf(CONNECTION_URL_PATTERN, hostname, port, sslmode) |
