sql: allow PRIMARY REGION syntax for CREATE / ALTER DATABASE#56883
sql: allow PRIMARY REGION syntax for CREATE / ALTER DATABASE#56883craig[bot] merged 1 commit intocockroachdb:masterfrom
Conversation
fde5db9 to
c3b3b8d
Compare
ajstorm
left a comment
There was a problem hiding this comment.
Reviewed 11 of 11 files at r1.
Reviewable status:complete! 0 of 0 LGTMs obtained (waiting on @otan)
pkg/sql/parser/parse_test.go, line 77 at r1 (raw file):
{`CREATE DATABASE a SURVIVE REGION FAILURE`}, {`CREATE DATABASE a SURVIVE ZONE FAILURE`}, {`CREATE DATABASE a PRIMARY REGION = "us-west-1"`},
Nit - Stupid question, but why is the "=" semantics the one that we parse to by default?
pkg/sql/sem/tree/create.go, line 80 at r1 (raw file):
} if node.PrimaryRegion != "" { ctx.WriteString(" PRIMARY REGION = ")
Nit: Same question about "=" here. I'd think we'd default to no "="
otan
left a comment
There was a problem hiding this comment.
Reviewable status:
complete! 0 of 0 LGTMs obtained (waiting on @ajstorm)
pkg/sql/parser/parse_test.go, line 77 at r1 (raw file):
Previously, ajstorm wrote…
Nit - Stupid question, but why is the "=" semantics the one that we parse to by default?
fixed!
ajstorm
left a comment
There was a problem hiding this comment.
Reviewable status:
complete! 1 of 0 LGTMs obtained (waiting on @ajstorm)
Release note (sql change): Introduced stubs for ALTER DATABASE ... PRIMARY REGION and CREATE TABLE ... PRIMARY REGION
c3b3b8d to
be7dc05
Compare
|
thanks! bors r=ajstorm |
|
Build succeeded: |
Release note (sql change): Introduced stubs for ALTER DATABASE ...
PRIMARY REGION and CREATE TABLE ... PRIMARY REGION