将 Dbever 上的结果集导出到 CSV

通常,我会在窗口中使用 Dbever,并且总是像这样导出我的结果集:

  • 运行我的查询—— > 选择结果—— > 导出结果集—— > 选择导出到剪贴板—— > 完成

这一步一步把我的结果集放在我的剪贴板,我可以粘贴到任何地方,我想与它的工作。

问题是,现在我正在使用 dbever 的 Mac 和这个指南是不工作。 我可以继续下去,直到我选择结果集的那一刻,如下图所示:

exporting data set

但是一旦我在这个过程中更进一步,在最后一步我得到: 没问题

请注意,在“ source”中,本来应该显示起源于结果集的查询,但是它只说了“ select”。

因此,它不选择我的结果或任何东西(除了是“成功的”)。

通常情况下,我的查询会自动显示在那里,我找不到任何选项来纠正这个问题的菜单。

174313 次浏览

Is there a reason you couldn't select your results and right click and choose Advanced Copy -> Advanced Copy? I'm on a Mac and this is how I always copy results to the clipboard for pasting.

The problem was the box "open new connection" that was checked. So I couldn't use my temporary table.

You don't need to use the clipboard, you can export directly the whole resultset (not just what you see) to a file :

  1. Execute your query
  2. Right click any anywhere in the results
  3. click "Export resultset..." to open the export wizard
  4. Choose the format you want (CSV according to your question)
  5. Review the settings in the next panes when clicking "Next".
  6. Set the folder where the file will be created, and "Finish"

The export runs in the background, a popup will appear when it's done.


In newer versions of DBeaver you can just :

  1. right click the SQL of the query you want to export
  2. Execute > Export from query
  3. Choose the format you want (CSV according to your question)
  4. Review the settings in the next panes when clicking "Next".
  5. Set the folder where the file will be created, and "Finish"

The export runs in the background, a popup will appear when it's done.

Compared to the previous way of doing exports, this saves you step 1 (executing the query) which can be handy with time/resource intensive queries.

In version 21.0 / Release date march 1, 2021

  1. right click the SQL of the query you want to export
  2. Export data
  3. From query Choose the format you want (CSV according to your question)
  4. Review the settings in the next panes when clicking "Next".
  5. Set the folder where the file will be created, and "Finish"