User Tools

Site Tools


at-m42:lecture14

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
at-m42:lecture14 [2009/04/26 10:15] eechrisat-m42:lecture14 [2011/01/14 12:45] (current) – external edit 127.0.0.1
Line 462: Line 462:
   * If you have a pool of connections you'd want to release your connection (returning it to the pool) when you've finished.   * If you have a pool of connections you'd want to release your connection (returning it to the pool) when you've finished.
      
-=====Simplified Queries with Groovy =====+=====  Simplified Queries with Groovy ===== 
 + 
  
 <code groovy 1|Example 2; Database lookup in Groovy (at-m42/Lectures/lecture14/Lookup.groovy)> <code groovy 1|Example 2; Database lookup in Groovy (at-m42/Lectures/lecture14/Lookup.groovy)>
Line 562: Line 563:
 ===== Persistence Patterns: Transaction script ===== ===== Persistence Patterns: Transaction script =====
 In many applications it is natural to work directly with the relational model, issuing SQL queries and parsing result sets. In many applications it is natural to work directly with the relational model, issuing SQL queries and parsing result sets.
-  * This is known as the //[[http://martinfowler.com/eaaCatalog/transactionScript.html|Transaction Script]]// pattern((All patterns discussed in this lecture are from Fowler, //Patterns of Enterprise Application Architecture//.)): business logic is organized into procedures for each use case.+  * This is known as the //[[http://martinfowler.com/eaaCatalog/transactionScript.html|Transaction Script]]// pattern((All patterns discussed in this lecture are from //Patterns of Enterprise Application Architecture//. See [[Recommended Reading]] for bibliographic details.)): business logic is organized into procedures for each use case.
   * Direct use of SQL is also well suited for aggregating queries and set-based updates (accessing large amounts of data or updating many tables in the same transaction)   * Direct use of SQL is also well suited for aggregating queries and set-based updates (accessing large amounts of data or updating many tables in the same transaction)
 +
 ===== Persistence Patterns: ORM ===== ===== Persistence Patterns: ORM =====
  
at-m42/lecture14.1240740905.txt.gz · Last modified: 2011/01/14 12:24 (external edit)