I have a file as a byte[] fileContent. My mySql-scheme is generated by Hibernate and by default hibernate sets the sql-type of fileContent to BLOB.
But a BLOB is not big enough for my files. I will need at least a MEDIUMBLOM or even a LONGBLOB.
But how can i annotate my field so that Hibernate will generate the scheme with my field as a LONGBLOB? I have search google for 2 hours now without getting anything...
Shouldn't this be a so simple and common task that it should be documented somewhere??
Please help a frustrated programmer!!
@WhatAnnotationCanIUseToForceHibernateToMakeThisALONGBLOB????
private byte[] fileContent;
Have you tried
@Column(columnDefinition = "LONGBLOB")
private byte[] fileContent;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With