| 422 | } |
| 423 | |
| 424 | void NodeTable::validatePkNotExists(const Transaction* transaction, ValueVector* pkVector) const { |
| 425 | offset_t dummyOffset = INVALID_OFFSET; |
| 426 | auto& selVector = pkVector->state->getSelVector(); |
| 427 | DASSERT(selVector.getSelSize() == 1); |
| 428 | if (pkVector->isNull(selVector[0])) { |
| 429 | throw RuntimeException(ExceptionMessage::nullPKException()); |
| 430 | } |
| 431 | if (lookupPK(transaction, pkVector, selVector[0], dummyOffset)) { |
| 432 | throw RuntimeException( |
| 433 | ExceptionMessage::duplicatePKException(pkVector->getAsValue(selVector[0])->toString())); |
| 434 | } |
| 435 | } |
| 436 | |
| 437 | void NodeTable::initInsertState(main::ClientContext* context, TableInsertState& insertState) { |
| 438 | auto& nodeInsertState = insertState.cast<NodeTableInsertState>(); |
nothing calls this directly
no test coverage detected