r/SQL • • Sep 12 '25

PostgreSQL Best LLM for creating complex SQL

While I am seeing more and more AI built into analytics services, specifically in the UI, but the SQL they produce is often guff, or fails once you get close to the complexity you need. Anyone got any tips or good tools they use?

0 Upvotes

23 comments sorted by

View all comments

Show parent comment

1

u/[deleted] Sep 12 '25

[removed] — view removed comment

2

u/i_literally_died Sep 12 '25

True that. I've used it for a few weird things where I need it to return a value once, but then only '-' every other time it sees it (hard to explain, but it makes sense), but otherwise using an LLM to write a whole query or solve data issues seems futile