View Issue Details

IDProjectCategoryView StatusLast Update
0031375LazarusLCLpublic2017-05-15 22:42
ReporterSonerAssigned ToOndrej Pokorny 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Platformi386-32BitOSWindowsOS Version7
Product VersionProduct BuildLazarus 1.6.3 SVN-Rev. 53387 
Target VersionFixed in Version1.7 (SVN) 
Summary0031375: TDBGrid shows some rows repeated with TSQLQuery
DescriptionTDBGrid shows some records repeated if the dbgrids height resized.

It think it has to do with fechted row count.
This bug does not appears with ZEOS-TZQuery because TZQuery fetches all data rows.

I uploaded small project to reproduce.
It contains also 3 images to show the problem.
Steps To Reproduce1. make the dbgrid (form) smaller so it can not show all data rows
2. now click refresh button on dbnavigator
3. and resize the dbgrid
4. now you will see the dbgrid shows some rows repeated
TagsNo tags attached.
Fixed in Revisionr54444
LazTarget-
Widgetset
Attached Files

Relationships

related to 0031532 resolvedMichael Van Canneyt FPC Painting issue in DBGrid 

Activities

Soner

2017-02-10 18:51

reporter  

sqldbtedit.zip (296,905 bytes)

Thaddy de Koning

2017-02-10 21:33

reporter   ~0098087

This is a Lazarus issue, not an fpc one.
(Call invalidate helps)

Soner

2017-02-11 12:30

reporter   ~0098094

Sorry I didn't know how to change project field, but i put it in LCL-Category.
(Yet i know to select right project)

Invalidate hides the problem, it doesn't solves.

Thaddy de Koning

2017-02-11 12:58

reporter   ~0098095

It does not hide the problem: it seems repaints are not quick enough on your platform/configuration. What you experience is just a painting problem.
But maybe the invalidate can be called internally at a more proper place.

Bart Broersma

2017-02-11 13:42

developer   ~0098098

Can somebody move this to Lazarus please?

Soner

2017-02-21 22:26

reporter   ~0098361

Last edited: 2017-02-21 22:29

View 2 revisions

Today I inspected this bug again, it has nothing to do with fetched data-row count. It is weird bug.
Now I know when the bug appears.
1. make the dbgrid (form) smaller so it can not show all data rows
2. now click refresh button on dbnavigator.
Now you see the prior and first buttons of DBNavigator is enabled.

We distinguish two cases:

3. a) Go to the first row (top row in grid), but don't press up-key in the first row, so the prior and first buttons of DBNavigator is still enabled. (TSQLQuery.BOF is not called)
Now when you resize the Form the bug appers.

(Continue here from point 2.)
3. b)Go to the first row (top row in grid) and on the first row press up-key so the TSQLQuery.BOF is called and prior and first buttons is disabled.

Now when you resize the Form the bug does not appers.

I could not resolve it, because I don't know much about LCL-Grids and BufferedDataset, maybe someone who knows LCL-Grids and BufferedDataset can use this information.


Don't forget: This bug does not appers with ZEOS components only with TSQLQuery(=TCustomBufDataset)

LacaK

2017-03-24 14:36

developer   ~0099194

Probably related to 0031532
@Soner can you please retest with TRUNK version FPC and Lazarus ?

Michl

2017-03-29 22:57

developer   ~0099270

I can confirm that issue on 64bit Windows 7 with 32bit Lazarus Trunk and a SQLite test app (I don't have Firebird).

It is fixed here in Lazarus revision 54444 (Ondrej: lcl: dbgrids: workaround for FPC 3 issue 0031532). Works fine with FPC 3.0.0 and FPC Trunk.

@Soner: can you please retest with Lazarus Trunk?

Michl

2017-03-29 22:58

developer  

SQLite_Simple.zip (333,126 bytes)

Soner

2017-04-05 01:01

reporter   ~0099379

Last edited: 2017-04-05 01:08

View 2 revisions

I don`t have svn version from fpc but I trust you the other and close this als solved.
(I can't find the button for closing this issue).

Issue History

Date Modified Username Field Change
2017-02-10 18:51 Soner New Issue
2017-02-10 18:51 Soner File Added: sqldbtedit.zip
2017-02-10 21:33 Thaddy de Koning Note Added: 0098087
2017-02-11 12:30 Soner Note Added: 0098094
2017-02-11 12:58 Thaddy de Koning Note Added: 0098095
2017-02-11 13:42 Bart Broersma Note Added: 0098098
2017-02-11 15:47 Michael Van Canneyt Project FPC => Lazarus
2017-02-21 22:26 Soner Note Added: 0098361
2017-02-21 22:29 Soner Note Edited: 0098361 View Revisions
2017-03-24 14:36 LacaK Note Added: 0099194
2017-03-29 22:29 Michl Relationship added related to 0031532
2017-03-29 22:57 Michl LazTarget => -
2017-03-29 22:57 Michl Note Added: 0099270
2017-03-29 22:57 Michl Assigned To => Michl
2017-03-29 22:57 Michl Status new => feedback
2017-03-29 22:58 Michl File Added: SQLite_Simple.zip
2017-04-05 01:01 Soner Note Added: 0099379
2017-04-05 01:01 Soner Status feedback => assigned
2017-04-05 01:08 Soner Note Edited: 0099379 View Revisions
2017-04-05 11:20 Michl Fixed in Revision => r54444
2017-04-05 11:20 Michl Status assigned => resolved
2017-04-05 11:20 Michl Fixed in Version => 1.7 (SVN)
2017-04-05 11:20 Michl Resolution open => fixed
2017-04-05 11:20 Michl Assigned To Michl => Ondrej Pokorny
2017-05-15 22:42 Soner Status resolved => closed