apache / gravitino-playground

A playground to experience Gravitino
Apache License 2.0
31 stars 31 forks source link

Llamaindex seems not able to execute the generated SQL #77

Open shaofengshi opened 2 months ago

shaofengshi commented 2 months ago

When run the "gravitino_llamaIndex_demo.ipynb", in the "Define SQLJoinQueryEngine" step, it couldn't execute the generated SQL:

response = query_engine.query( "Tell me about the arts and culture of the city with the highest" " population" )

Querying SQL database: The first choice is more relevant as it mentions 'city_stats' and 'population' which could be used to determine the city with the highest population. The second choice does not provide any specific information that could be used to answer the question. SQL query: SELECT city_name, population, country FROM city_stats ORDER BY population DESC LIMIT 1; SQL response: I'm sorry, but there was an error in retrieving the information about the city with the highest population. Can you provide me with the name of the city you are interested in so I can give you more specific information about its arts and culture?

As the generated SQL is correct, the Trino engine is active, so this problem seems from Llamaindex.