Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Query result shows too short excerpt #3251

Open
yeysman opened this issue Mar 19, 2024 · 4 comments
Open

Query result shows too short excerpt #3251

yeysman opened this issue Mar 19, 2024 · 4 comments

Comments

@yeysman
Copy link

yeysman commented Mar 19, 2024

Please answer the questions below, it helps us to keep track of the issue. Please do not ignore it or your issue will be closed.

  1. Which driver are you using and version of it (Ex: PostgreSQL 10.0):
    SQL server any version, MySQL any version

  2. Which TablePlus build number are you using (the number on the welcome screen, Ex: build 81): 5.9.0 (538) (MacOS)

  3. The steps to reproduce this issue:
    SQL server qery:
    declare @test as table (invoicetty nvarchar(max)) insert into @test (invoicetty) values ('INVC'+CHAR(10)+CHAR(13)+'ID XD10000'+CHAR(10)+CHAR(13)+'DOAH\JOSHNMR'+CHAR(10)+CHAR(13)+'10FEB24') select * from @test

Actual result:
Table plus cuts the line on first line break.
image

Expecting: Display data inline including line breaks.
(Azure data studio example)
image

In my case i have 200+ records. To review the result i have to open right bar and go over all records one by one, that is very painful :(

Not sure this issue is a bug or feature request.

@huyphams
Copy link
Contributor

You can change the padding here to see more than one line @yeysman
Screenshot 2024-03-20 at 8 49 51 AM

@yeysman
Copy link
Author

yeysman commented Mar 20, 2024

Hello @huyphams,
Thank you. I tried that, but it is kind of workaround and not the solution.
Changing padding will affect UI. In this particular query i want to see let's say up to 3 lines, but in another query i want to see as many rows as allows me data table height.
The solution you advised affects all queries. By increasing padding i solving one problem and getting another problem with other queries result UI. Please see below the height of row after i increased padding to see at least next one line
image
Normally i see up to 20 rows in the result table, with such padding i see up to 5 rows, what is not convenient.

@huyphams
Copy link
Contributor

I see that Azure Data Studio rendered the new line as a symbol. Actually, we could do that, and I think it is a smarter way to render data. We will consider adding an option to render the new line as a symbol.

@yeysman
Copy link
Author

yeysman commented Mar 20, 2024

Thank you @huyphams.
If you will consider this option could you please also check if it possible to display a few extra hidden elements like: ETX, STX, SOH.
Here is a screenshot of how DataGrip renders these elements:
image

Technically, i think as a easiest solution can be simply display line break or some other character as it's unicode representation:
"\r", "\n","u\0001" etc.

If we will have some data like:
[STX]HEADER
[SOH]SOMEDATA
SOMEELSEDATA
[ETX]

In data table we will see following line
"\u0002HEADER\n\u0001SOMEDATA\n..."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants