Help with transaction() flushing ORM

We are having an issue when saving an ORM transaction, there is an error thrown but we don’t see an error with the transaction unless we ORMFlush().

In application.cfc the following are set:

ormsettings.flushatrequestend = false;
automanagesession = false;

In my template I am running the following transaction:

transaction {
  me = entityLoadByPK('user',1);
  me.setName('asdfhsalkfjsalfkjsaflasjkflsa'); //name is varchar(10);

No error is thrown, and the record is not saved. No further transactions in this page request are saved either.

Any help would be greatly appreciated!


We are moving from Lucee 4.5 which would have thrown an error if the value is too long for the property that is being saved.

FYI - Ran into this too.
It was a pretty big pain in the butt.

The DB validation would kick in and kill the request, but the in memory would not.

The weird thing is. it would generate the Primary Keys and everything, and look like it was working fine in memory.
It just died when it tried to persist to the DB level.

No errors, nothing… ever.
It didn’t error because the persisting seemed to happen after the page was processed.

Thats as far as I got.

Brad mentioned you got stung by this as well. Did you happen to open a ticket, if so I would gladly upvote!

@Seth_Johnson No, Gavin wasn’t able to find a ticket for it. If you haven’t put one in yet, please do so.