Home » Author Archives: Lukas Eder (page 2)

Author Archives: Lukas Eder

Lukas is a Java and SQL enthusiast developer. He created the Data Geekery GmbH. He is the creator of jOOQ, a comprehensive SQL library for Java, and he is blogging mostly about these three topics: Java, SQL and jOOQ.

10 Easy Steps to a Complete Understanding of SQL

software-development-2-logo

Too many programmers think SQL is a bit of a beast. It is one of the few declarative languages out there, and as such, behaves in an entirely different way from imperative, object-oriented, or even functional languages (although, some say that SQL is also somewhat functional). As a SQL trainer (do visit our training, it’s great!) I’m writing SQL every ...

Read More »

SQL JOIN or EXISTS? Chances Are, You’re Doing it Wrong

software-development-2-logo

I’ve noticed this very consistently with a lot of customers, and also with participants of our Data Geekery SQL Workshop (which I highly recommend to everyone, if you excuse the advertising): A lot of developers get the distinction between JOIN and SEMI-JOIN wrong. Let me explain… What are JOIN and SEMI-JOIN A little bit of relational algebra first. What is ...

Read More »

Java A’s new Local-Variable Type Inference

java-logo

News could hardly get more exciting than this, for a programming language aficionado! There is now a JEP 286 for Local-Variable Type Inference with status “Candidate”. And a request for feedback by Brian Goetz, which I would love to invite you to participate in: http://mail.openjdk.java.net/pipermail/platform-jep-discuss/2016-March/000037.html Please do so, the survey remains open only from March 9 to March 16! This ...

Read More »

UI Developers! Choose Sensible Default Ordering!

software-development-2-logo

Good decisions come from experience. Experience comes from making bad decisions. ― Mark Twain Today, let’s look at one piece of experience and how we can turn that into good decisions when implementing UI logic. Please, all UI developers read this. The bad decision When UI developers display tabular data, it is very common for the table to offer sorting ...

Read More »

How to Support Java 6, 8, 9 in a Single API

java-logo

With jOOQ 3.7, we have finally added formal support for Java 8 features. This opened the door to a lot of nice improvements, such as: Creating result streams try (Stream<Record2<String, String>> stream = DSL.using(configuration) .select(FIRST_NAME, LAST_NAME) .from(PERSON) .stream()) { List<String> people = stream.map(p -> p.value1() + " " + p.value2()) .collect(Collectors.toList()); } Calling statements asynchronously (jOOQ 3.8+) CompletionStage<Record> result = ...

Read More »

A Very Peculiar, but Possibly Cunning Kotlin Language Feature

jetbrains-kotlin-logo

This has caught me by surprise. After studying the Kotlin language to learn about how to best leverage this interesting new language for jOOQ, I stumbled upon this puzzler. What do you think the following program will print? fun main(args: Array) { (1..5).forEach { if (it == 3) return print(it) } print("done") } Well… You might have guessed wrong. The ...

Read More »

(Ab)using Java 8 FunctionalInterfaces as Local Methods

java-logo

If you’re programming in more advanced languages like Scala or Ceylon, or even JavaScript, “nested functions” or “local functions” are a very common idiom to you. For instance, you’ll write things like fibonacci functions as such: def f() = { def g() = "a string!" g() + "– says g" } (Question from Stack Overflow by Aaron Yodaiken) The f() ...

Read More »

The Mute Design Pattern

java-logo

Have you been writing a lot of code following the Mute-Design-Pattern™ lately? E.g. try { complex(); logic(); here(); } catch (Exception ignore) { // Will never happen hehe System.exit(-1); } There’s an easier way with Java 8! Just add this very useful tool to your Utilities or Helper class: public class Helper { // 18395 lines of other code here ...

Read More »

jOOQ Tuesdays: Glenn Paulley Gives Insight into SQL’s History

software-development-2-logo

Welcome to the jOOQ Tuesdays series. In this series, we’ll publish an article on the third Tuesday every other month where we interview someone we find exciting in our industry from a jOOQ perspective. This includes people who work with SQL, Java, Open Source, and a variety of other related topics.               I’m very ...

Read More »

Want to take your Java skills to the next level?

Grab our programming books for FREE!

Here are some of the eBooks you will get:

  • Spring Interview QnA
  • Multithreading & Concurrency QnA
  • JPA Minibook
  • JVM Troubleshooting Guide
  • Advanced Java
  • Java Interview QnA
  • Java Design Patterns