diff options
author | Olivier Bertrand <bertrandop@gmail.com> | 2015-08-06 17:46:47 +0200 |
---|---|---|
committer | Olivier Bertrand <bertrandop@gmail.com> | 2015-08-06 17:46:47 +0200 |
commit | 5f533035d3ad8dc56ef339196633a931d7bff60c (patch) | |
tree | 5995948550927610863d8810a60e4c0f2c8eea18 /storage/connect/tabdos.cpp | |
parent | 7962add6c4d4ddf2928059fb4e009014f704b206 (diff) | |
download | mariadb-git-5f533035d3ad8dc56ef339196633a931d7bff60c.tar.gz |
Fix the TDBDOS::EstimatedLength function that was wrongly counting
its calculation virtual and special columns.
modified: storage/connect/reldef.h
modified: storage/connect/tabdos.cpp
Diffstat (limited to 'storage/connect/tabdos.cpp')
-rw-r--r-- | storage/connect/tabdos.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/storage/connect/tabdos.cpp b/storage/connect/tabdos.cpp index a1e58ab3344..527fe55dd89 100644 --- a/storage/connect/tabdos.cpp +++ b/storage/connect/tabdos.cpp @@ -2018,7 +2018,8 @@ int TDBDOS::EstimatedLength(void) // result if we set dep to 1 dep = 1 + cdp->GetLong() / 20; // Why 20 ????? } else for (; cdp; cdp = cdp->GetNext()) - dep = MY_MAX(dep, cdp->GetOffset()); + if (!(cdp->Flags & (U_VIRTUAL|U_SPECIAL))) + dep = MY_MAX(dep, cdp->GetOffset()); return (int)dep; } // end of Estimated Length |