News for hackers. Stuff that matters.

ycombinator2x

Re:A new way to solves complex SQL programming on Thursday December 10, 2020 @08:44AM (#25373594)
How it works,

Order.Table orderTable = Order.asTable(); Select select = new Select();

select.project(sum(orderTable.amount) / sum(orderTable.quantity) * 100) .from(orderTable) .where(orderTable.quantity > 30 && orderTable.salesAt.between("2020-10-10 00:00:00", "2020-10-30 23:59:59")) .groupBy(orderTable.productId);

codes above, how are expressions compiled in Java