News for hackers. Stuff that matters.
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by calvinmorrison on Monday February 05, 2024 @01:49PM (#39265186)
more like, when it comes to complex data structures and logic, i will do that outside of sql. I'll do a join with sql no problem, by the time we're doing multiple inner joins I usually prefer to just do multiple sql queries. I don't care about performance that badly.
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by ako on Monday February 05, 2024 @03:23PM (#39266590)
That’ll often not scale to millions of records. Letting the database optimizer find the optimal execution path instead of doing it procedurally elsewhere might result in “finishes in 5 minutes”, versus “doesn’t fit in a night”.
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by threeseed on Monday February 05, 2024 @04:42PM (#39267643)
This isn’t the 90s. Most hardware is way over-specced for the data sizes most people are dealing with.

The number of use cases which are too heavy to finish in hours but small enough to fit in a single instance is pretty limited.

Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by fifilura on Monday February 05, 2024 @05:06PM (#39267907)
SQL is popular because it can be run on a map/reduce backend. So once you have written your code it can run on any number of machines.
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by threeseed on Monday February 05, 2024 @05:41PM (#39268231)
a) SQL is not that popular on map/reduce backends. Most people are doing it in code.

b) Only basic SQL works on any database and even then there are major differences in how they treat things like nulls, type coercion etc.

Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by fifilura on Tuesday February 06, 2024 @12:40AM (#39271169)
BigQuery? Athena/Redshift?
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by ako on Tuesday February 06, 2024 @01:58AM (#39271574)
Costs are another reason to optimize queries, long running, inefficient queries will be a lot more expensive on things like snowflake than more efficient queries.
Re:Show HN: Natural-SQL-7B, a strong text-to-SQL model by fifilura on Monday February 05, 2024 @02:31PM (#39265859)
I usually only do one join at a time. But I separate them with CTEs ("WITH"). I can agree that many joins at once can make you grow grey hair.