Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pgcode: use XC instead of CDB #70347

Merged
merged 1 commit into from
Sep 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/ccl/logictestccl/testdata/logic_test/as_of
Original file line number Diff line number Diff line change
Expand Up @@ -268,10 +268,10 @@ SELECT * FROM t AS OF SYSTEM TIME with_max_staleness('1ms', false) WHERE i = 2
statement ok
SELECT * FROM t AS OF SYSTEM TIME with_min_timestamp(statement_timestamp() - '1ms', false) WHERE i = 2

statement error pgcode CDB00 bounded staleness read with minimum timestamp bound.*could not be satisfied by a local resolved timestamp
statement error pgcode XCUBS bounded staleness read with minimum timestamp bound.*could not be satisfied by a local resolved timestamp
SELECT * FROM t AS OF SYSTEM TIME with_max_staleness('1ms', true) WHERE i = 2

statement error pgcode CDB00 bounded staleness read with minimum timestamp bound.*could not be satisfied by a local resolved timestamp
statement error pgcode XCUBS bounded staleness read with minimum timestamp bound.*could not be satisfied by a local resolved timestamp
SELECT * FROM t AS OF SYSTEM TIME with_min_timestamp(statement_timestamp() - '1ms', true) WHERE i = 2

#
Expand Down
4 changes: 2 additions & 2 deletions pkg/sql/pgwire/pgcode/codes.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,10 @@ var (
// internally on a connection between different Cockroach nodes.
InternalConnectionFailure = MakeCode("58C01")

// Class CDB - cockroach extension.
// Class XC - cockroach extension.
// CockroachDB distributed system related errors.

// UnsatisfiableBoundedStaleness signals that the bounded staleness query
// cannot be satisfied.
UnsatisfiableBoundedStaleness = MakeCode("CDB00")
UnsatisfiableBoundedStaleness = MakeCode("XCUBS")
)