DB-GPT icon indicating copy to clipboard operation
DB-GPT copied to clipboard

[BUG]: sql生成与诊断 报AttributeError: 'ChatWithDbQA' object has no attribute 'tables'

Open withyou971 opened this issue 2 years ago • 1 comments

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context Add any other context about the problem here.

withyou971 avatar Jun 14 '23 14:06 withyou971

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context Add any other context about the problem here. do you have your local mysql environment, you should create database in your local mysql environment

Aries-ckt avatar Jun 15 '23 02:06 Aries-ckt

I also met this error at beginning, I do have a docker hosted mysql and created specific db for this test. until I restarted the webserver, I found out that it fetchs the DB info when you start the webserver. So seems it persists the info into vectordb for quick search. also means the db dialogue is not "realtime" querying the metadata info of your MySQL DB, once you do some changes on your db, you have to restart the webserver? how can I refresh the db info without restarting, wish can do it on GUI, thanks.

2023-06-27 17:15:29 | INFO | chromadb.db.duckdb | Persisting DB to disk, putting it in the save folder: /home/aigc/workplace/DB-GPT/pilot/data/tpch_region_ts.vectordb 2023-06-27 17:15:29 | INFO | langchain.embeddings | db summary embedding success

zfanswer avatar Jun 27 '23 09:06 zfanswer

Please try the latest version v0.4.2, this issue will be closed.

csunny avatar Nov 24 '23 13:11 csunny