• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef NATIVE_RDB_RDB_ERRNO_H
17 #define NATIVE_RDB_RDB_ERRNO_H
18 
19 namespace OHOS {
20 namespace NativeRdb {
21 
22 constexpr int E_OK = 0;
23 constexpr int E_BASE = 1000;
24 constexpr int E_ERROR = (E_BASE + 1);
25 constexpr int E_CANNOT_UPDATE_READONLY = (E_BASE + 2);
26 constexpr int E_REMOVE_FILE = (E_BASE + 3);
27 constexpr int E_EMPTY_FILE_NAME = (E_BASE + 4);
28 constexpr int E_EMPTY_TABLE_NAME = (E_BASE + 5);
29 constexpr int E_EMPTY_VALUES_BUCKET = (E_BASE + 6);
30 constexpr int E_INVALID_STATEMENT = (E_BASE + 7);
31 constexpr int E_INVALID_COLUMN_INDEX = (E_BASE + 8);
32 constexpr int E_INVALID_COLUMN_TYPE = (E_BASE + 9);
33 constexpr int E_INVALID_COLUMN_NAME = (E_BASE + 10);
34 constexpr int E_QUERY_IN_EXECUTE = (E_BASE + 11);
35 constexpr int E_TRANSACTION_IN_EXECUTE = (E_BASE + 12);
36 constexpr int E_EXECUTE_IN_STEP_QUERY = (E_BASE + 13);
37 constexpr int E_EXECUTE_WRITE_IN_READ_CONNECTION = (E_BASE + 14);
38 constexpr int E_BEGIN_TRANSACTION_IN_READ_CONNECTION = (E_BASE + 15);
39 constexpr int E_NO_TRANSACTION_IN_SESSION = (E_BASE + 16);
40 constexpr int E_MORE_STEP_QUERY_IN_ONE_SESSION = (E_BASE + 17);
41 constexpr int E_NO_ROW_IN_QUERY = (E_BASE + 18);
42 constexpr int E_INVALID_BIND_ARGS_COUNT = (E_BASE + 19);
43 constexpr int E_INVALID_OBJECT_TYPE = (E_BASE + 20);
44 constexpr int E_INVALID_CONFLICT_FLAG = (E_BASE + 21);
45 constexpr int E_HAVING_CLAUSE_NOT_IN_GROUP_BY = (E_BASE + 22);
46 constexpr int E_NOT_SUPPORTED_BY_STEP_RESULT_SET = (E_BASE + 23);
47 constexpr int E_STEP_RESULT_SET_CROSS_THREADS = (E_BASE + 24);
48 constexpr int E_STEP_RESULT_QUERY_NOT_EXECUTED = (E_BASE + 25);
49 constexpr int E_STEP_RESULT_IS_AFTER_LAST = (E_BASE + 26);
50 constexpr int E_STEP_RESULT_QUERY_EXCEEDED = (E_BASE + 27);
51 constexpr int E_STATEMENT_NOT_PREPARED = (E_BASE + 28);
52 constexpr int E_EXECUTE_RESULT_INCORRECT = (E_BASE + 29);
53 constexpr int E_STEP_RESULT_CLOSED = (E_BASE + 30);
54 constexpr int E_RELATIVE_PATH = (E_BASE + 31);
55 constexpr int E_EMPTY_NEW_ENCRYPT_KEY = (E_BASE + 32);
56 constexpr int E_CHANGE_UNENCRYPTED_TO_ENCRYPTED = (E_BASE + 33);
57 constexpr int E_CHANGE_ENCRYPT_KEY_IN_BUSY = (E_BASE + 34);
58 constexpr int E_STEP_STATEMENT_NOT_INIT = (E_BASE + 35);
59 constexpr int E_NOT_SUPPORTED_ATTACH_IN_WAL_MODE = (E_BASE + 36);
60 constexpr int E_CREATE_FOLDER_FAIL = (E_BASE + 37);
61 constexpr int E_SQLITE_SQL_BUILDER_NORMALIZE_FAIL = (E_BASE + 38);
62 constexpr int E_STORE_SESSION_NOT_GIVE_CONNECTION_TEMPORARILY = (E_BASE + 39);
63 constexpr int E_STORE_SESSION_NO_CURRENT_TRANSACTION = (E_BASE + 40);
64 constexpr int E_NOT_SUPPORT = (E_BASE + 41);
65 constexpr int E_INVALID_PARCEL = (E_BASE + 42);
66 } // namespace NativeRdb
67 } // namespace OHOS
68 
69 #endif
70