filterDeleteRecords( )

Adds a filter to the AGDBSet object that removes any rows marked for deletion.

Interface

AGDBSet

IDL definition
void filterDeleteRecords(boolean filter);
ADO equivalent

None

JavaScript synopsis
dbset.filterDeleteRecords(filter)
C synopsis
void AVfilterDeletedRecords(
  dbset,
   PODSBooleanfilter
);
Parameters
  • dbset   The AGDBSet object.

  • filter   Boolean that indicates whether the deleted records should be filtered.

Returns

None

Remarks

This filter will work even with another filter that you may set using setFilter( ). Calling this method will cause the filter loop to run again.

Example

Assume you have a database on device where some records have been marked for deletion. The deletion will not actually be performed until the next synchronization, so you do not want these records to show up in any lists that the user displays. The following code suppresses the display of the records that have been flagged for deletion:

... 
var DBMgr = CreateObject('avantgo.db'); 
var DBName = "StressGets"; 
var DBSet = null; 
... 
function openDB() 
{ 
if(DBSet) 
DBSet.close(); 
DBSet = gDBMgr.open(DBName, "w"); 
DBset.filterDeletedRecords(true); 
}
See also

setFilter( )