Home
last modified time | relevance | path

Searched refs:trxId (Results 1 - 10 of 10) sorted by relevance

/foundation/distributeddatamgr/relational_store/test/ndk/unittest/
H A Drdb_store_configv2_test.cpp106 int64_t trxId = 0; in VdbTest002() local
107 EXPECT_EQ(OH_Rdb_ErrCode::RDB_OK, OH_Rdb_BeginTransWithTrxId(store, &trxId)); in VdbTest002()
109 EXPECT_EQ(OH_Rdb_ErrCode::RDB_OK, OH_Rdb_ExecuteByTrxId(store, trxId, insertSql)); in VdbTest002()
110 EXPECT_EQ(OH_Rdb_ErrCode::RDB_OK, OH_Rdb_CommitByTrxId(store, trxId)); in VdbTest002()
/foundation/distributeddatamgr/relational_store/interfaces/ndk/include/
H A Drelational_store.h506 * @param trxId The transaction ID of the specified transaction, must be greater than 0
514 int OH_Rdb_ExecuteByTrxId(OH_Rdb_Store *store, int64_t trxId, const char *sql);
568 * @param trxId The output parameter, which is used to receive the transaction ID corresponding to the transaction
576 int OH_Rdb_BeginTransWithTrxId(OH_Rdb_Store *store, int64_t *trxId);
582 * @param trxId The transaction ID of the specified transaction, must be greater than 0
590 int OH_Rdb_RollBackByTrxId(OH_Rdb_Store *store, int64_t trxId);
596 * @param trxId The transaction ID of the specified transaction, must be greater than 0
604 int OH_Rdb_CommitByTrxId(OH_Rdb_Store *store, int64_t trxId);
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/mock/include/
H A Drdb_store_impl.h47 std::pair<int32_t, ValueObject> Execute(const std::string &sql, const Values &args, int64_t trxId) override;
57 int RollBack(int64_t trxId) override;
59 int Commit(int64_t trxId) override;
90 int ExecuteByTrxId(const std::string &sql, int64_t trxId, bool closeConnAfterExecute = false,
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/include/
H A Drdb_store_impl.h96 std::pair<int32_t, ValueObject> Execute(const std::string &sql, const Values &args, int64_t trxId) override;
106 int RollBack(int64_t trxId) override;
108 int Commit(int64_t trxId) override;
165 int ExecuteByTrxId(const std::string &sql, int64_t trxId, bool closeConnAfterExecute = false,
H A Dtrans_db.h34 std::pair<int32_t, ValueObject> Execute(const std::string &sql, const Values &args, int64_t trxId) override;
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/src/
H A Drdb_store.cpp295 std::pair<int32_t, ValueObject> RdbStore::Execute(const std::string &sql, const Values &args, int64_t trxId) in Execute() argument
379 int RdbStore::RollBack(int64_t trxId) in RollBack() argument
381 (void)trxId; in RollBack()
390 int RdbStore::Commit(int64_t trxId) in Commit() argument
392 (void)trxId; in Commit()
H A Drdb_store_impl.cpp1189 std::pair<int32_t, ValueObject> RdbStoreImpl::Execute(const std::string &sql, const Values &args, int64_t trxId) in Execute() argument
1203 if (config_.IsVector() && trxId > 0) { in Execute()
1204 return { ExecuteByTrxId(sql, trxId, false, args), ValueObject() }; in Execute()
1912 int RdbStoreImpl::ExecuteByTrxId(const std::string &sql, int64_t trxId, bool closeConnAfterExecute, in ExecuteByTrxId() argument
1918 if (trxId == 0) { in ExecuteByTrxId()
1922 if (!trxConnMap_.Contains(trxId)) { in ExecuteByTrxId()
1923 LOG_ERROR("trxId hasn't appeared before %{public}" PRIu64, trxId); in ExecuteByTrxId()
1927 auto result = trxConnMap_.Find(trxId); in ExecuteByTrxId()
1940 LOG_ERROR("transaction id: %{public}" PRIu64 ", storeName: %{public}s, errCode: %{public}d" PRIu64, trxId, in ExecuteByTrxId()
1951 RollBack(int64_t trxId) RollBack() argument
2008 Commit(int64_t trxId) Commit() argument
[all...]
H A Dtrans_db.cpp193 std::pair<int32_t, ValueObject> TransDB::Execute(const std::string &sql, const Values &args, int64_t trxId) in Execute() argument
195 (void)trxId; in Execute()
/foundation/distributeddatamgr/relational_store/interfaces/ndk/src/
H A Drelational_store.cpp531 int OH_Rdb_ExecuteByTrxId(OH_Rdb_Store *store, int64_t trxId, const char *sql) in OH_Rdb_ExecuteByTrxId() argument
538 (rdbStore->GetStore()->Execute(sql, std::vector<OHOS::NativeRdb::ValueObject>{}, trxId)).first); in OH_Rdb_ExecuteByTrxId()
568 int OH_Rdb_BeginTransWithTrxId(OH_Rdb_Store *store, int64_t *trxId) in OH_Rdb_BeginTransWithTrxId() argument
571 if (rdbStore == nullptr || trxId == nullptr) { in OH_Rdb_BeginTransWithTrxId()
575 *trxId = res.second; in OH_Rdb_BeginTransWithTrxId()
579 int OH_Rdb_RollBackByTrxId(OH_Rdb_Store *store, int64_t trxId) in OH_Rdb_RollBackByTrxId() argument
585 return ConvertorErrorCode::NativeToNdk(rdbStore->GetStore()->RollBack(trxId)); in OH_Rdb_RollBackByTrxId()
588 int OH_Rdb_CommitByTrxId(OH_Rdb_Store *store, int64_t trxId) in OH_Rdb_CommitByTrxId() argument
594 return ConvertorErrorCode::NativeToNdk(rdbStore->GetStore()->Commit(trxId)); in OH_Rdb_CommitByTrxId()
/foundation/distributeddatamgr/relational_store/interfaces/inner_api/rdb/include/
H A Drdb_store.h405 virtual std::pair<int32_t, ValueObject> Execute(const std::string &sql, const Values &args = {}, int64_t trxId = 0);
493 virtual int RollBack(int64_t trxId);
500 virtual int Commit(int64_t trxId);

Completed in 13 milliseconds