SQLAI.ai

AI Using Wrong Database Tables and Columns

If you have a multiple tables with similar sounding names like "pg_users" or "pro_users" and AI doesn't automatically pick up which tables or columns to use from the input, then you can use the autosuggest feature to easily add database schema meta data. This feature can also be used if you table or column naming is unconventional.

Once you have connected you data source or imported it via CSV or manually typed, you can access the schema by typing / (slash) in the input field on the AI Generator:

Open database schema autosuggestion
Open database schema autosuggestion

Once the autosuggestion is open you can simply either tables names or columns names. You can phrase it by appending "use X, Y, Z tables" or if it is a particular column by "via table_name.column_name".

The database schema autosuggest is also useful if you quickly want to look up what tables and columns your schema has. When the autosuggest is open you can search it to limit options.