On 5.9, doing the same thing, I get this error:
Database operation "dml" failed (exception ERROR, "ERROR: insert or update on table "cr_revisions" violates foreign key constraint "cr_revisions_lob_fk"
DETAIL: Key (lob)=(1) is not present in table "lobs".
")ERROR: insert or update on table "cr_revisions" violates foreign key constraint "cr_revisions_lob_fk"
DETAIL: Key (lob)=(1) is not present in table "lobs".
SQL:
update cr_revisions
set mime_type = 'application/pdf',
lob = 1
where revision_id = '32133'