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

resultset displaying issue #29930

Open
skriszo opened this issue May 7, 2024 · 6 comments
Open

resultset displaying issue #29930

skriszo opened this issue May 7, 2024 · 6 comments

Comments

@skriszo
Copy link

skriszo commented May 7, 2024

Description

this is the actual, whole resultset of a query:
whole_resultset

with the below settings:
settings

if, by the time the query initially executed, the resultset window is smaller (the row count that fits into it) than as many row is set in the "ResultSet fetch size" config (and the full resultset is bigger than "ResultSet fetch size" (12<20<25):
resultset_1

and then you start scrolling down (fetch more records), then DBeaver keeps fetching records endlessly, and repeats the same records over and over again.
resultset_2

DBeaver Version

community, 24.0.3.202404211624

Operating System

windows 11

Database and driver

  1. Teradata 17.10.03.18
  2. Teradata JDBC Driver 20.00.00.20

Steps to reproduce

see description
if any of the listed conditions don't meet the issue does not arise.

Additional context

No response

@ShadelessFox
Copy link
Member

Hello @skriszo,

Try disabling this option:
image

@skriszo
Copy link
Author

skriszo commented May 7, 2024

hi @ShadelessFox,
then I lose the possibility to fetch the records incrementally.
maybe it is a misunderstanding, but when I say "then DBeaver keeps fetching records endlessly", I mean that whenever I scroll down DBeaver fetches a new batch of records, but it never ends.
eg.: the table (or whatever I query from) contains only 25 rows, DBeaver does not stop at 25 (which would be the correct behaviour), but it fetches zillions of records.

@ShadelessFox
Copy link
Member

I believe the RECURSIVE clause causes this. Try putting the LIMIT clause in the outer query.

@skriszo
Copy link
Author

skriszo commented May 7, 2024

@ShadelessFox, this query was just for demonstrative purposes, it behaves like this with simple select * from table as well.
and also, I am not the one who puts the LIMIT clause anywhere, but DBeaver. This is what this setting is for:
image

@ShadelessFox
Copy link
Member

Sorry, I can't reproduce this exact scenario.

By default, DBeaver fetches rows until the entire screen is filled with data. This can be turned off as demonstrated here: #29930 (comment)

To be able to fetch next pages of data, you might need to enable such an option here:
image

So that you can access it from the toolbar:
image

@skriszo
Copy link
Author

skriszo commented May 8, 2024

well, according to my experience DBeaver fetches data until it reaches the record count that is set here (does not depend on window size):
image

yes, this Fetch Next Page equals with scrolling down with Auto-fetch next segment turned on and the issue appears with this as well.
However, I tried the same thing with an Oracle connection and it worked fine, so it is a Teradata related bug. Also what I noticed as a difference:
image
even with this setting turned on
image
with an Oracle connection the queries do not get extended with FETCH FIRST x ROWS ONLY (this is the oracle syntax for LIMIT)
while with a Teradata connection they do get extended with TOP x (Teradata syntax for LIMIT)

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

No branches or pull requests

4 participants