Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Agile Database - Java JDBC concerns

 
Joseph Yin
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When using Java to access database tables, one of the biggest concern is the transaction control (commit or rollback). Does anyone have any guideline or solution to address my concern.
Thanks, Joseph Yin
jyin@qualcomm.com
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Interesting. Do you have any specific concerns regarding how an agile database design would affect your transaction management?
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Commit if you want the changes to be persistent, rollback otherwise, so it seems to me. But I guess I don't understand the question...?
 
Surasak Leenapongpanit
Ranch Hand
Posts: 341
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By default in JDBC transaction starts and commits after each statement's execution on a connection. But it gives poor performance when multiple statements on a connection are to be executed.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by surasak lee:
By default in JDBC transaction starts and commits after each statement's execution on a connection. But it gives poor performance when multiple statements on a connection are to be executed.
But this still doesn't have anything to do with agile database design...
 
Serge Adzinets
Ranch Hand
Posts: 166
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This topic seems appropriate for JDBC forum.
 
Craig Demyanovich
Ranch Hand
Posts: 173
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Given a java.sql.Connection instance conn, use

Now you can commit only when you want to.
Craig
[ January 14, 2004: Message edited by: Craig Demyanovich ]
[ January 14, 2004: Message edited by: Craig Demyanovich ]
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is agile database? This is a new term .
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm moving this to the JDBC forum.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is agile database? This is a new term .
There is no such a thing. There's agile database design or development, however.
[ January 14, 2004: Message edited by: Lasse Koskela ]
 
Scott Ambler
author
Ranch Hand
Posts: 608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For Agile Database material, check out www.agiledata.org.
When it comes to transaction control and agile databases, my only advice is to understand transaction control, concurrency control, recognize you have options, and the pick the right approaches. http://www.agiledata.org/essays/concurrencyControl.html might help a bit.
- Scott
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic