Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Product Manuals » DBISAM Version 4 Manual for RAD Studio XE (Delphi) » Using DBISAM » Setting Filters on Tables and Query Result Sets |
Difference | Description |
Correlation Names | You cannot use table or column correlation names in filter expressions. |
Aggregate functions | You cannot use any aggregate functions like SUM(), COUNT(), AVG(), etc. in filter expressions. |
begin with MyTable do begin { Set the filter expression } Filter:='(LastSaleDate >= '+QuotedStr('1998-01-01')+') '+ 'and (LastSaleDate <= '+QuotedStr('1998-12-31')+') '+ 'and (TotalSales > 10000)'; FilterOptions:=[]; Filtered:=True; end; end;
begin with MyTable do begin { Set the filter expression, in this case for a partial-match, case-insensitive filter } Filter:='CustomerName = '+QuotedStr('A*'); FilterOptions:=[foCaseInsensitive]; Filtered:=True; case FilterOptimizeLevel of foNone: ShowMessage('The filter is completely unoptimized'); foPartial: ShowMessage('The filter is partially optimized'); foFull: ShowMessage('The filter is completely optimized'); end; end; end;
procedure TMyForm.TableFilterRecord(DataSet: TDataSet; var Accept: Boolean); begin Accept:=False; if Pos('Hardware', DataSet.FieldByName('CustomerName').AsString) > 0) then Accept:=True; end;
This web page was last updated on Thursday, November 16, 2023 at 10:39 AM | Privacy PolicySite Map © 2025 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |