Subject Re: [firebird-support] Tracking changes to records / triggers
Author Robert martin
Hi

It wasn't meant to be trigger code. It was an example of an idea I
thought might be possible. I was hoping an FB guru would say, yup you
can do that in FB without much of a performance cost.

And yes it is pretty much dephi code :)

Rob







Anderson Farias wrote:
> Hi,
>
>
>> Is it possible to write a trigger like....
>>
>> Changed := False;
>> Counter := 0;
>> while (counter < Record.FieldCount) and (Changed = False) do begin
>> if (old.Fields[Counter] <> new.Fields[Counter]) then begin
>> Changed := True;
>> end;
>> end;
>>
>> If (Changed = True) then begin
>> //Marke record as changed
>> end
>>
>
> It's me or the above code looks pretty much Delphi code? I don't get it...
> How a FB trigger fits here?
>
>
> Regards,
> Anderson
>
>
>
> ------------------------------------
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://www.firebirdsql.org and click the Resources item
> on the main (top) menu. Try Knowledgebase and FAQ links !
>
> Also search the knowledgebases at http://www.ibphoenix.com
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> Yahoo! Groups Links
>
>
>
>
>