Archive for September, 2008
premature optimization
September 6th, 2008 by Jeanne BoyarskyDonald Knuth is often quoted as saying “premature optimization is the root of all evil.” Often in the JavaRanch forums, we see questions like: which is faster stringBuilder.append(‘a’) or “a” + “b” (The answer is these two expressions are supposed to generate to the same byte code if used on the same line.) My first [...]
Categories: Development Process.
Comments: 3
Database Key Generation in Java Applications
September 3rd, 2008 by Scott SelikoffAll JDBC programmers at one time or another have had to deal with key generation for new records, or more precisely, how to retrieve keys for newly created records. This article discusses some of the techniques and limitations offered to Java JDBC programmers. Unique Keys Most (good) database systems assign a unique key, usually a [...]
Categories: JDBC, Java/J2EE.
Tags: auto-generate, Database, generation, getGeneratedKeys, Java/J2EE, JDBC, key
Comments: 3
