From db72f3959489ef54261071390e20703dea5caf51 Mon Sep 17 00:00:00 2001 From: alesapin Date: Thu, 28 May 2020 22:07:20 +0300 Subject: [PATCH] Remove error code --- src/Common/ErrorCodes.cpp | 1 - src/DataStreams/CheckSortedBlockInputStream.cpp | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/Common/ErrorCodes.cpp b/src/Common/ErrorCodes.cpp index 5898e956400..cb4c591041c 100644 --- a/src/Common/ErrorCodes.cpp +++ b/src/Common/ErrorCodes.cpp @@ -498,7 +498,6 @@ namespace ErrorCodes extern const int ALTER_OF_COLUMN_IS_FORBIDDEN = 524; extern const int INCORRECT_DISK_INDEX = 525; extern const int UNKNOWN_VOLUME_TYPE = 526; - extern const int SORT_ORDER_VIOLATED = 527; extern const int KEEPER_EXCEPTION = 999; extern const int POCO_EXCEPTION = 1000; diff --git a/src/DataStreams/CheckSortedBlockInputStream.cpp b/src/DataStreams/CheckSortedBlockInputStream.cpp index db4794b917f..a56738a9a9f 100644 --- a/src/DataStreams/CheckSortedBlockInputStream.cpp +++ b/src/DataStreams/CheckSortedBlockInputStream.cpp @@ -6,7 +6,7 @@ namespace DB namespace ErrorCodes { -extern const int SORT_ORDER_VIOLATED; +extern const int LOGICAL_ERROR; } CheckSortedBlockInputStream::CheckSortedBlockInputStream( @@ -72,12 +72,12 @@ Block CheckSortedBlockInputStream::readImpl() auto block_columns = block.getColumns(); if (!last_row.empty() && !less(last_row, 0, block_columns, 0)) - throw Exception("Sort order of blocks violated", ErrorCodes::SORT_ORDER_VIOLATED); + throw Exception("Sort order of blocks violated", ErrorCodes::LOGICAL_ERROR); size_t rows = block.rows(); for (size_t i = 1; i < rows; ++i) if (!less(block_columns, i - 1, block_columns, i)) - throw Exception("Sort order of blocks violated", ErrorCodes::SORT_ORDER_VIOLATED); + throw Exception("Sort order of blocks violated", ErrorCodes::LOGICAL_ERROR); last_row.clear(); for (size_t i = 0; i < block.columns(); ++i)