Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

database integrity

 
omar bili
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, i was only wondering about the database integrity
while using "JDO" who is doing that is it the database it self
or..
Regards
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you elaborate on your question. Not sure what you are asking.

JDO injects SQL into your Java classes. I don't think there are any changes to the database itself. If you are asking about data being stored. Transactions are handled by JDO, and all the CRUD and database constraints are followed.

Mark
 
Erik Bengtson
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Omar,

The database takes care of data integrity when using relational jdo implementations. Some implementations will create the tables and contraints for you if you wish. To enrich the data integrity you create additional constraints using DDL scripts or define new ones in the jdo metadata definition.
 
Erik Bengtson
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JDO injects SQL into your Java classes.


JDO does not inject SQL into java classes. Your java classes are datastore agnostic and can be simultaneously used for xml store, relational store, file stores and others.

On the other hand, EJB CMP injects SQL code into classes at deployment time.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic