Re: FMP question
Re: FMP question
- Subject: Re: FMP question
- From: Paul Berkowitz <email@hidden>
- Date: Thu, 02 Nov 2000 18:17:21 -0800
On 11/2/00 1:40 PM, "Shane Stanley" <email@hidden> wrote:
>
On 2/11/00 8:23 PM +1000, Paul Berkowitz, email@hidden, wrote:
>
>
> On 11/1/00 1:59 PM, "Shane Stanley" <email@hidden> wrote:
>
>
>
>> tell database 1
>
>> tell layout y
>
>> try
>
>> set x to record 1 whose cellValue of cells = {b, f, c, d, e}
>
>> on error
>
>> set n to ""
>
>> end try
>
>> end tell
>
>> if n {b, f, c, d, e} then
>
>> tell layout x
>
>> create new record at end with data {a, b, c, d, e, f, g}
>
>> end tell
>
>> end if
>
>> end tell
>
>>
>
>> That should speed things up quite a bit.
>
>
>
>
>
> This method is excellent.
>
>
But buggy :-( It doesn't allow for the fact that there might be more than
>
one record "whose cellValue of cells = {b, f, c, d, e}". Fairly easily
>
fixed, though.
? Not really. I don't care if there's more than one (i.e. previous
duplicates), it will simply prevent a new one being made. The cellValues
being checked are all the significant non-calculated ones. If applied
consistently from now on, there never will be duplicates.
Or am I missing something?
There IS a tiny bug however, which I referred to in my first post, but maybe
you didn't spot. "x" in line 4 suddenly becomes "n" for the rest of the
script, then there's a new "x" later on. I did fix that when adapting the
script.
--
Paul Berkowitz