From 4617ea2c1c81f6b26531aa4212c061f005cb401f Mon Sep 17 00:00:00 2001 From: Rob Bygrave Date: Mon, 27 Mar 2023 21:44:23 +1300 Subject: [PATCH] Improve the error message "No join columns found" to include the relationship --- .../io/ebeaninternal/server/deploy/BeanDescriptorManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ebean-core/src/main/java/io/ebeaninternal/server/deploy/BeanDescriptorManager.java b/ebean-core/src/main/java/io/ebeaninternal/server/deploy/BeanDescriptorManager.java index 5f2792f6c..7778778ad 100644 --- a/ebean-core/src/main/java/io/ebeaninternal/server/deploy/BeanDescriptorManager.java +++ b/ebean-core/src/main/java/io/ebeaninternal/server/deploy/BeanDescriptorManager.java @@ -932,7 +932,7 @@ public final class BeanDescriptorManager implements BeanDescriptorMap, SpiBeanTy // define the TableJoin DeployTableJoin oneToManyJoin = oneToMany.getTableJoin(); if (!oneToManyJoin.hasJoinColumns()) { - throw new RuntimeException("No join columns"); + throw new RuntimeException("No join columns found to satisfy the relationship " + oneToMany); } createUnidirectional(targetDesc, owningType, beanTable, oneToManyJoin); }