소스 검색

* fixed bug: exception when dataset is updated, but no was value changed

master
bergmann 7 년 전
부모
커밋
3f7ad004b2
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. +2
    -2
      src/cpphibernate/driver/mariadb/schema/table.cpp

+ 2
- 2
src/cpphibernate/driver/mariadb/schema/table.cpp 파일 보기

@@ -1357,8 +1357,8 @@ std::string table_t::execute_create_update(
else else
{ {
auto count = connection.execute_rows(*statement); auto count = connection.execute_rows(*statement);
if (count != 1)
throw misc::hibernate_exception("Expected exaclty one row to be inserted/updated!");
if (count > 1)
throw misc::hibernate_exception("Expected one/ row to be inserted/updated!");
cpphibernate_debug_log(count << " rows inserted/updated"); cpphibernate_debug_log(count << " rows inserted/updated");
} }
primary_key_field->set(context, primary_key); primary_key_field->set(context, primary_key);


불러오는 중...
취소
저장