News for hackers. Stuff that matters.
Re:Treating SQL like code by leoh on Thursday January 13, 2022 @11:40AM (#29922864)
Google and many other companies that use Looker do something else, too, which is that they store models in source control as opposed to SQL. Models describe the schema of the database, and things like calculations, measures, rollups — which are reusable and composable.

https://docs.looker.com/data-modeling/learning-lookml/what-i...

Re:Treating SQL like code by kristjansson on Thursday January 13, 2022 @11:56AM (#29923139)
Using models from your ORM of choice instead of the DDL they generate isn't that unreasonable. Suggesting that one should (or then could only?) use 'a simple API .. or UX' to actually query the database seems pretty objectionable though.
Re:Treating SQL like code by corrius on Friday January 14, 2022 @04:55AM (#29932545)
It locks you down to that ORM. If you are the owner of the ORM such as Google with Looker that is fine, otherwise it doesn't sounds like a good idea to me