logoalt Hacker News

SQG (SQL to Code Generator) v0.10: Java Streams and List Type Support

18 pointsby uwemaurerlast Thursday at 7:08 PM5 commentsview on HN

Comments

vbilopavtoday at 6:51 AM

This was my first approach in realizing my PostgreSQL-centric, Db-first, or rather SQL-first vision of software development.

The project was call pgroutiner and it generated bunch of C# code for me out of PostgreSQL.

After doing couple of projects with it, I realized it wasn't enough. The new approach is a dynamic HTTTP REST API generation but, with plugin for code generation of frontend files (Typescript,. Javascript, HTTP files). This iw way better approach. Look it up, it's called npgsqlrest.github.io

DarkNova6yesterday at 10:24 PM

Neat! Even-though they should probably use a custom type rather than the generic "Stream" to communicate that this needs to be closed. Or remove the try-with-resource block if closing is not necessary.

This way it leaves some room for misinterpretation.

show 1 reply
barelysapienttoday at 1:41 AM

Love SQLC, this looks good too. Syntax is almost identical.

daveungereryesterday at 10:50 PM

How does SQG compare to SQLDelight, for someone only interested in Kotlin and PostgreSQL?