-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Creating an entity inside a PreFlush is throwing an error INSERT VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
#8598
Comments
No, not every event can do everything, you probably need to do this in the general |
I just discovered that if the address of the subscription is new, it always works. I would have prefer to avoid creating a Listener and playing more with the |
I just tried an |
It does work in a PreFlush event if I call
|
I have an entity
Subscription
in OtO withAddress
andLead
which is also in OtO withAddress
.In the Subscription, I have the following preFlush
Everything works fine when
$lead->getAddres()
is not null ; the address is updated.But when it's null (ie the code
new Address();
is executed), I was expecting that a new address could be created and set.Instead, I'm getting the following error:
Is this a bug ?
The text was updated successfully, but these errors were encountered: