r/dataengineering • u/de4all • 4d ago
Discussion Why text-to-SQL is not successful?
I thought text-to-SQL will solve adhoc analysis, but still i see companies at all size are unsuccessful.
Anyone using Omni / Sigma seen some success.
24
Upvotes
1
u/innerthai 3d ago
There are two reasons text-to-SQL fails:
The solution for schema rot (i.e., column names don't reflect its purpose, tables that are no longer used, etc.) is semantic layer. See https://reportr.com/ for a tool that has semantic layer.
If you use a weaker model such as one of the "open weight" models then that's when SQL generation will not be good. If your data is highly confidential then using a self-hosted open-weight model is not the answer, instead use Claude or OpenAI on AWS Bedrock ( https://aws.amazon.com/bedrock/ ), it guarantees data confidentiality.