jOOQ SQL Building

This is a note about jOOQ SQL building based on the official jOOQ document. jOOQ use BNF-based hierarchy DSL to emulate SQL in Java. It enables compile-time checking. jOOQ build a preser internally that consists of Query, ResultQuery, Table, Field, Row, Condition and Name.

ORM vs Typed-SQL

This article is a note recording different views on pros and cons of ORM, specifically the Java JPA and Hibernate. There are two common approaches to brige the business data model and the database: ORM mapps data model to database, or typed-SQL use strong types SQL-like syntax to access db data. ORM is data-model driven while the typedSQL is db-driven. ORM includes JPA and Hibernate. Typed-SQL includes jOOQ and QueryDSL.

Angular Change Detection

A basic requirement for every Web framework is to synchornize a data model and the Browser DOM. Detecting data model change is a central task. Angular separates updating the application and DOM changes into two distinct phases. The developer is responsible for model changes in one phase and Angular synchronizes the model changes in change detection in another phase.

Angular enforces an unidirectinal data flow from parent to child via @Input() property binding. A child should not change its parent’s state directly. A child can communicate with its parent using @Output() event or via shared service.