View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0032962||FPC||Database||public||2018-01-06 22:39||2018-02-26 18:22|
|Reporter||Kevin Morris||Assigned To||Michael Van Canneyt|
|Platform||Microsoft Intel||OS||Windows Server Essentials||OS Version||2016|
|Product Version||3.1.1||Product Build||56872|
|Target Version||3.1.1||Fixed in Version||3.2.0|
|Summary||0032962: When trying to enter a TBufDataset.IndexName in Design Time, it disappears.|
|Description||You cannot set the .IndexName property of a TBufDataset at design time. I define indexes in IndexDefs, then I try to enter the name of the index I want the TBufDataset set to in the IndexName property, and it just disappears.|
|Steps To Reproduce||In Lazarus 1.9 design time, place a TBufDataset on a TDataModule. Define some indexes using IndexDefs. Include field name(s).|
Then go back to the TBufDataset and try to set the IndexName property. It disappears, sometimes saying DEFAULT_ORDER.
The only way around this is to set the IndexName in code, so it gets done AFTER a TBufDataset.CreateDataset or TBufDataset.LoadFromFile.
|Additional Information||Is it necessary to define indexes in IndexDefs (which contain field names) and then ALSO set the TBufDataset.IndexFieldNames property to the SAME FIELD NAME I just set the the IndexDef that I just defined?|
( I could not upload the example project because it is too large )
|Tags||No tags attached.|
|Fixed in Revision||38353|
Please try to attach the sample project in various files.
If necessary remove any really large files.
I find it hard to believe that a simple source file can be so big ?
BufDataset_IndexName.zip (130,514 bytes)
||I found that there were some .exes in the .zip. I deleted them and tried the upload again. It worked this time.|
This was a tricky one.
Contrary to what one would intuitively think, the indexdefs collection was not the place to add indexes.
New indexes could only be created in code using AddIndex().
I have changed this behaviour so that indexes can now be added to the collection,
and they will be created and maintained when the dataset is opened.
Now you define indexes using the IndexDefs collection, and the active index can be set using IndexName
|2018-01-06 22:39||Kevin Morris||New Issue|
|2018-01-12 08:32||Michael Van Canneyt||Assigned To||=> Michael Van Canneyt|
|2018-01-12 08:32||Michael Van Canneyt||Status||new => assigned|
|2018-01-12 08:34||Michael Van Canneyt||Note Added: 0105684|
|2018-01-12 08:34||Michael Van Canneyt||Status||assigned => feedback|
|2018-01-27 00:08||Kevin Morris||File Added: BufDataset_IndexName.zip|
|2018-01-27 00:09||Kevin Morris||Note Added: 0106059|
|2018-01-27 00:09||Kevin Morris||Status||feedback => assigned|
|2018-02-26 18:22||Michael Van Canneyt||Fixed in Revision||=> 38353|
|2018-02-26 18:22||Michael Van Canneyt||Note Added: 0106651|
|2018-02-26 18:22||Michael Van Canneyt||Status||assigned => resolved|
|2018-02-26 18:22||Michael Van Canneyt||Fixed in Version||=> 3.2.0|
|2018-02-26 18:22||Michael Van Canneyt||Resolution||open => fixed|
|2018-02-26 18:22||Michael Van Canneyt||Target Version||=> 3.1.1|