Multiple query results in the same tab

Answered

I am trying to run multiple queries, and want to see all results in the same result tab.

 

Basically I am trying to run:

Select * from mytable where x=1

Select * from mytable where x=2

And would like to see both results in the same result tab, 

 

I saw that question a couple of times, and the answer (Settings - Database - General - Open Results in new tab)  is not working for me. It still opens a different tab for each query.  Pinning does not work either.

Using datagrip 2020.2.3

Thanks

 

 

10 comments
Comment actions Permalink

Give the In-Editor Results a try and see if it's a better workflow for you.

0
Comment actions Permalink

Thanks for the response Jim,  but not working for me.

In-Editor results still displays in multiple tabs. I cannot get it to display like your screen shot.

I must have some user preferences or setting somewhere overwriting this, but cannot figure out what it is

0
Comment actions Permalink

Samersadek what is your DBMS? what if you close this result set and run query one by one having empty row between them?

0
Comment actions Permalink

Microsoft Sql Server

Apologies but I am not exactly sure what you mean. If you mean run the 2 queries without that empty row between them, I tried that and it did not make a difference

FWIW, this is on a windows machine.  I am going to try to setup DG on a mac and see if it behaves differently

0
Comment actions Permalink

Same results on a new install on a mac.

 

0
Comment actions Permalink

Did someone found the solution? I'm using PHPStorm and facing the same problem. It was working fine before version 2020.3.3


0
Comment actions Permalink

Still waiting too!

0
Comment actions Permalink

for mssql , adding the "go" keyword between the 2 queries seems to work with in-editor results enabled.

0
Avatar
Yuriy Vinogradov
Comment actions Permalink

 to open a new in-editor window, there should be a separator with empty row between queries.

to have results in tabs, just remove empty row between queries, select all and run.

please check if it works in latest version v.2021.1.x

0
Comment actions Permalink

v 2021.3.4 

It still opens a different tab for each query. Is it possible in 2022 to open results one by one, similar ssms?

1

Please sign in to leave a comment.