diff --git a/jOOQ-website/css/jooq.css b/jOOQ-website/css/jooq.css
index 92cab93cb8..8aad0c307f 100644
--- a/jOOQ-website/css/jooq.css
+++ b/jOOQ-website/css/jooq.css
@@ -183,6 +183,25 @@ div.navigation-item-left {
height: 40px;
}
+#footer {
+ font-size: 0.7em;
+ color: #ddd;
+
+ padding-top: 1em;
+ padding-left: 3em;
+ padding-right: 3em;
+ padding-bottom: 1em;
+
+ background: #888787;
+ background: -webkit-gradient(linear, left bottom, right top, from(#888787), to(#666));
+ background: -moz-linear-gradient(left bottom, #888787, #666);
+ background: gradient(linear, left bottom, right top, from(#888787), to(#666));
+ -webkit-box-shadow: inset rgba(0,0,0,.1) 0 5px 5px;
+ -moz-box-shadow: inset rgba(0,0,0,.1) 0 5px 5px;
+ box-shadow: inset rgba(0,0,0,.1) 0 5px 5px;
+ border-top: 1px solid rgba(0,0,0,.2);
+ text-shadow: #555 -1px -1px 0px;}
+
div.tweet-item-left {
float: left;
padding-right: 2em;
diff --git a/jOOQ-website/frame.php b/jOOQ-website/frame.php
index e09c9193cf..bc247ed8bd 100644
--- a/jOOQ-website/frame.php
+++ b/jOOQ-website/frame.php
@@ -79,10 +79,14 @@
}
printContent();
?>
-
-
+
+
jOOQ ships with its own DSL (or Domain Specific Language) that + simulates SQL as good as possible in Java. This means, that you can + write SQL statements almost as if Java natively supported that syntax + just like .NET's C# does with LINQ to SQL. +
+ +Here is an example to show you what that means. When you want to write a query like this in SQL:
+| Here is an example to show you what that means. When you want to write a query like this in SQL: | +Then, using jOOQ's DSL API, you can write the same query as such: | + +
++-- Select all books by authors born after 1920, +-- named "Paulo" from a catalogue: +SELECT * + FROM t_author a + JOIN t_book b ON a.id = b.author_id + WHERE a.year_of_birth > 1920 + AND a.first_name = 'Paulo' + ORDER BY b.title+ |
+
+
+Result<Record> result =
+create.select()
+ .from(T_AUTHOR)
+ .join(T_BOOK).on(TAuthor.ID.equal(TBook.AUTHOR_ID))
+ .where(TAuthor.YEAR_OF_BIRTH.greaterThan(1920)
+ .and(TAuthor.FIRST_NAME.equal("Paulo")))
+ .orderBy(TBook.TITLE)
+ .fetch();
+ |
+
+
You couldn't come much closer to SQL itself in Java, without re-writing the compiler.
+Sequences implement the + org.jooq.Sequence interface, providing essentially this functionality:
+ ++// Get a field for the CURRVAL sequence property +Field<BigInteger> currval(); + +// Get a field for the NEXTVAL sequence property +Field<BigInteger> nextval();+
So if you have a sequence like this in Oracle:
+CREATE SEQUENCE s_author_id+
This is what jOOQ will generate:
+
+public final class Sequences {
+
+ // A static sequence instance
+ public static final Sequence S_AUTHOR_ID = // [...]
+}
+
+ Which you can use in a select statement as such:
++Field<BigInteger> s = Sequences.S_AUTHOR_ID.nextval(); +BigInteger nextID = create.select(s).fetchOne(s);+ +
Or directly fetch currval() and nextval() from the sequence using the Factory:
++BigInteger currval = create.currval(Sequences.S_AUTHOR_ID); +BigInteger nextval = create.nextval(Sequences.S_AUTHOR_ID);+
| The jOOQ User Manual : Meta model code generation : Sequences | previous : next |
| Here is an example to show you what that means. When you want to write a query like this in SQL: | +Then, using jOOQ's DSL API, you can write the same query as such: | +
+-- Select all books by authors born after 1920, +-- named "Paulo" from a catalogue: +SELECT * + FROM t_author a + JOIN t_book b ON a.id = b.author_id + WHERE a.year_of_birth > 1920 + AND a.first_name = 'Paulo' + ORDER BY b.title |
+
+Result<Record> result =
+create.select()
+ .from(T_AUTHOR)
+ .join(T_BOOK).on(TAuthor.ID.equal(TBook.AUTHOR_ID))
+ .where(TAuthor.YEAR_OF_BIRTH.greaterThan(1920)
+ .and(TAuthor.FIRST_NAME.equal("Paulo")))
+ .orderBy(TBook.TITLE)
+ .fetch(); |
+
You couldn't come much closer to SQL itself in Java, without re-writing the compiler.
+