Field-Map Scripting

4.2.3.50 Update

Update procedure


Prototype:

procedure Update( const Set, Where : string);

Description:

Modifies existing records in a table

Syntax:

Layer.Update(Set,Where);


Part

Description


Layer

A reference to the Field-Map layer as defined in Field-Map Project Manager


Set

Specifies which columns and values should be updated


Where

The conditions that must be met for the update to execute.



Return value:


none


Example:

var 
  i:integer;    
begin
 
  Trees.Update('SpeciesCategory=100','Species<50');
  
  i:= Trees.DeleteFrom('DBH_mm>900');
  ShowInformation(format('Number of deleted records: %d',[i])); 
  
end. 


See also:

Value; ValueAsString; ValueAsinteger; ValueAsFloat; ValueAsboolean; OldValue; PreviousValue; BOF; EOF; RecordCount; State; SetValues; SetValuesFromXML; CrownProjection; CrownProfile; CrownProfilePoints; StemProfile; OldLayer; SavePosition; RestorePosition; SaveState; RestoreState; SavePositionAndState; RestorePositionAndState; Open; Close; First; Last; Next; Prior; Edit; Post; Append; Delete; Cancel; Refresh; Locate; ClearTable; Filter; Filtered; CheckFilter; SetFilterExt; ClearFilterForChildLayers; DeepFilter; EnableCachedUpdates; ApplyUpdates; GetAttributeValue; GetQueryResult; DeleteFrom; Update; CreateMemTable; SaveToDBF; SaveToExcel; GetMinOfAttributeValues; GetMaxOfAttributeValues; GetMeanOfAttributeValues; GetSumOfAttributeValues; GetRecordCount; GetLookupTable; GetLookupListValue; GetLookupListAttributeValue; GetID; GetIdAttributeName; GetIdSQL; SaveTimeStamp; File2Blob; Blob2Folder; String2Blob; Blob2String; FillAttributeValues; MarkValuesAsConditional;GetListOfChildLayers; GetPercentageOfFilledAttributes4Record; GetPercentageOfFilledAttributes4Layer; RoundAttributeValues