Suggestion for improving the examples

#1

Hello your documentation and tutorials would make a lot more sense if SQL TABLES, QUERIES and INDEXES were included.

Frankly it is a huge wast those examples have not been provided. For example:

Take the ridiculously complicated concept of @Embeddable class e.g Address  etc...

Placed in an employee Object but wait What does the table look like. Nope not in the example.

Wait but what about some named queries to go with that @Entity? Nope

And what about explaining how / what you mean by indirect getters and setters

 

so If I wish to access my @EmbeddableId  Address    as in your example, I would what? Have to 

create getters and setters specific to a hierarchy of objects???

e.g     Address getAddress() { return this.address }

or     String  getState() { return this.address.getState();}

or  String getZipCode() { return this.address.getZipCode()}

So then can I use it in a named query  e.g   from Employee where ZipCode=:zipCode"

Just my two cents here but a full fledged example complete with SQL , JPL named queries and  how EmbeddedId  classes are meant to be used in named queries.... etc...

 

 

#2

Thank you for your suggestions.

We tried to keep the examples as simple as possible and when embeddable classes are introduced we prefer to focus on that topic only with minimal code that is needed for understanding the topic.

Indexes, named queries, etc. are discussed on other pages of the documentation.

Note also that ObjectDB, as an object database, silently ignores @Table and other ORM annotation.

ObjectDB Support
#3

Note also that ObjectDB doesn't require defining properties for persistent fields, so you can access fields in queries even if you do not define properties.

ObjectDB Support

Reply