4 ms·
Query GPT: Transform Natural Language into SQL
- deleted 1y ago[deleted]
- sega_sai 1y agoI am not entirely sure if the distinct service is justified here, but in my own work, I've found that regular Chatgpt is great in writing queries. And usually I post the '\d ' output to it to describe my schema, and ask in regular language what i want. I don't think i encountered yet cases when it didn't work. The only thing I had to occassionally ask is to rewrite the query from nested query to CTE.
- voidhorse 1y agoWasn't part of the whole premise of SQL that it is already basically natural language?
- breadwinner 1y agoThat was the promise of COBOL as well. It was designed to be a "English-like computer programming language", see: https://en.wikipedia.org/wiki/COBOL https://en.wikipedia.org/wiki/COBOL But that doesn't mean you don't have to learn COBOL. It has a specific syntax that must be learned. Same for SQL.
- voidhorse 1y agoYeah, of course, and learning the mental model behind SQL is even more important than learning the syntax. I'll admit I was just posting a low-quality snark comment because I'm kind of appalled at the laziness and lack of expertise some of these AI "applications" show. I've yet to see an LLM used in a way that actually enables new ideas or that radically alters productivity. Instead every use case essentially boils down to either "save me five minutes by doing something I'm too lazy to do myself" or worse, "allow me to try my hand at something in complete ignorance, bother if I know whether or not it is even correct". The devaluation of practice and expertise is going to have major implications in the long run. In this particular case, if you actually bothered to spend one day learning SQL you'd find it takes probably even less time to just write the query rather than try to think about the best english-language rendition of it that actually gets the LLM to do what you want...LLMs are like short-term thinking codified into a tool. Why spend thirty minutes to learn something today when I can spend a decade of my time doing it in a half-baked fashion over a lifetime.
- breadwinner 1y agoThat's like saying you shouldn't use a spellchecker because you should be learning the correct spelling yourself. But the point of a spellchecker isn't to replace learning — it's a tool that supports and accelerates your work. In the same way, AI tools aren't a substitute for understanding; they're productivity enhancers. They help you move faster, reduce routine effort, and give you more time to focus on deeper learning and problem-solving. Used wisely, they complement the learning process rather than undermine it.
- sgarland 1y agoA spellchecker is a linter. LLMs are a false equivalency. I have yet to see AI “used wisely.” It is always precisely as parent complained about: people who neither know nor care to learn about the subject of their profession using it as a shortcut. If that is to be the state of the field, then salaries need to be _drastically_ cut. There’s absolutely no reason that you should be paid six figures to ask an omniscient entity a question, and copy/paste the answer. > They help you move faster, reduce routine effort You cannot understand something if you don’t understand its fundamentals. Reducing routine effort translates to “I don’t want to write boilerplate.” And that’s fine, if and only if you already know how to write it, what it does, and why it is the way it is. Wax on, wax off.
- deleted 1y ago[deleted]
- sgarland 1y agoJFC just learn SQL. It is one of the easiest languages that exists, and you probably don’t have to know 1/2 of it to be productive.
- deleted 1y ago[deleted]
- gremgoth 1y agoLike a third of LLMs still struggle with basic tasks like unrolling a cyclic foreign key: https://conexus.com/llm-wars/ https://conexus.com/llm-wars/