-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#11] Demo code should link to relevant sections of the manual - Demo…
…15ComputedColumns
- Loading branch information
Showing
6 changed files
with
55 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 10 additions & 6 deletions
16
jOOQ-demo-oss/jOOQ-demo-kotlin/src/test/kotlin/org/jooq/demo/kotlin/Demo15ComputedColumns.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,28 @@ | ||
package org.jooq.demo.kotlin | ||
|
||
import org.jooq.demo.AbstractDemo | ||
import org.jooq.demo.kotlin.db.tables.references.* | ||
import org.jooq.demo.kotlin.db.tables.references.STAFF | ||
import org.junit.Test | ||
|
||
|
||
class Demo15ComputedColumns : AbstractDemo() { | ||
|
||
// Computed columns are a commercial only feature | ||
@Test | ||
fun fetchVirtualClientSideComputedColumns() { | ||
title("Client side computed columns emulate their server side equivalents by inlining the computation expression") | ||
|
||
// Computed columns are a commercial only feature | ||
|
||
// | ||
// @Test | ||
// fun fetchVirtualClientSideComputedColumns() { | ||
// ctx.select( | ||
// STAFF.FULL_NAME, | ||
// STAFF.FULL_ADDRESS | ||
// ) | ||
// .from(STAFF) | ||
// .fetch() | ||
// } | ||
// | ||
// | ||
|
||
// More information here: | ||
// - https://www.jooq.org/doc/latest/manual/code-generation/codegen-advanced/codegen-config-database/codegen-database-forced-types/codegen-database-forced-types-computed/ | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 10 additions & 6 deletions
16
jOOQ-demo-pro/jOOQ-demo-kotlin/src/test/kotlin/org/jooq/demo/kotlin/Demo15ComputedColumns.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,28 @@ | ||
package org.jooq.demo.kotlin | ||
|
||
import org.jooq.demo.AbstractDemo | ||
import org.jooq.demo.kotlin.db.tables.references.* | ||
import org.jooq.demo.kotlin.db.tables.references.STAFF | ||
import org.junit.Test | ||
|
||
|
||
class Demo15ComputedColumns : AbstractDemo() { | ||
|
||
// Computed columns are a commercial only feature | ||
/* [pro] */ | ||
|
||
@Test | ||
fun fetchVirtualClientSideComputedColumns() { | ||
title("Client side computed columns emulate their server side equivalents by inlining the computation expression") | ||
|
||
// Computed columns are a commercial only feature | ||
/* [pro] */ | ||
|
||
ctx.select( | ||
STAFF.FULL_NAME, | ||
STAFF.FULL_ADDRESS | ||
) | ||
.from(STAFF) | ||
.fetch() | ||
} | ||
/* [/pro] */ | ||
|
||
/* [/pro] */ | ||
// More information here: | ||
// - https://www.jooq.org/doc/latest/manual/code-generation/codegen-advanced/codegen-config-database/codegen-database-forced-types/codegen-database-forced-types-computed/ | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters