# org.hibernate.PropertyValueException: not-null property references a null or transient value

**Code:** `not-null property references a null` · **Category:** Java · **Seen on:** Java

A field marked non-nullable was null at save time.

## Meaning

Hibernate validates `@Column(nullable=false)` / `optional=false` before running SQL, so you get this before any database error.

## Common causes

- Required field not set
- Relationship `optional=false` but parent missing
- Wrong entity mapping
- Builder default not applied

## Quick fix

1. Set the field before saving
2. Make the column nullable if appropriate
3. Validate input earlier with Bean Validation

## Detailed fix by platform

### JPA

1. `@NotNull @Column(nullable = false) private String email;` and validate in the controller

## How to diagnose

1. **Field** — Which property?
2. **Mapping** — nullable?
3. **Input** — Validated?

---
Source: [WhatIsMyError](https://whatismyerror.com/errors/java/hibernate-propertyvalueexception-not-null)
