Java SQL database class representation -
tables:
car
long :: car_id string :: typeowner
long :: owner_id string :: name int :: agecar_owner
long :: car_id long :: owner_id date :: bought_date question:so understand best way transfer info between java , sql db using java persistence api. each table represented java class @entity annotation.
but how mid-table "car_owner" represented java class?
the main thought relationship between both classes. check wiki-link more info onetoone relationship ( if business here auto has 1 owner ). if business owner has many cars , check manytoone link.
good luck assignment :)
java sql many-to-many persistence
No comments:
Post a Comment