Mapping a list of embeddable with a JSON type

I dont find any obvious answers to my question so far, so I post an example of what I want to do.

Hibernate 6.4.4

class Test {
    @Column(name = "ARC_DOCS")
    private List<ArcDoc> arcDocs;

class ArcDoc  {
    private String archiveNumber;
    private String archiveStatus;
    private ZonedDateTime archivedAt;
    private String details;

And got the following error :
org.hibernate.AnnotationException: Property ‘Test.arcDocs’ is mapped as basic aggregate component array, but this is not yet supported.

Not supported or am I wrong with the code ?

You have to remove @Embeddable from ArcDoc.

Thanx, it works like a charm

Quick question, can we query through the list ?
Example : Test.ardocs.archivedAt > ?

You can, but not yet with plain HQL. For that, you will have to make use of native JSON functions that your database offers. Consult the manual of your database vendor for details.

The problem remains if in another entity i want to had the @Embedded field of this type. What to do in this case? Thanks in advance.

Please create a new topic and add more details to your question i.e. the entity model, query and exception stack trace.

Created -

Thank you, same problem, same solution.