![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. |
#3
| |||
| |||
|
|
Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. |
#4
| |||
| |||
|
|
In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#5
| |||
| |||
|
|
I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#6
| |||
| |||
|
|
Just retested here with the letter h, and the numbers 0 and -5, both worked. Must be something wonky at your end. Not sure if its my instructions that have the bug, or your execution of them yet though. Hmmmm....on second thought... Are you sure you implemented my 'case' and not Harry's very similiar one? We both came up with almost identical solutions -- the one difference is that I think Harry's will fail on "0". Further if the source field is set to be of type "number", not "text", then "just letters" will evaluate to 0 in the calc, and also fail on Harry's. The "or 1" clause in my version of the case statement was put there specifically to deal with blanks and zeros, and it seems to be working here. ![]() -Dave In article <1131023489.574568.324570 (AT) o13g2000cwo (DOT) googlegroups.com>, hruby (AT) dataapex (DOT) com says... I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#7
| |||
| |||
|
|
Just a minor correction regarding attribution: The other case statement that doesn't handle "0" was put forth by Howard, not Harry. (Forgive me both you: Harry for attaching your name to a bug you didn't make, and Howard for bringing this much attention to your minor bug just to clear my concsience.) -regards, Dave In article <MPG.1dd3ec06e4a80970989da1 (AT) shawnews (DOT) vf.shawcable.net>, nospam (AT) nospam (DOT) com says... Just retested here with the letter h, and the numbers 0 and -5, both worked. Must be something wonky at your end. Not sure if its my instructions that have the bug, or your execution of them yet though. Hmmmm....on second thought... Are you sure you implemented my 'case' and not Harry's very similiar one? We both came up with almost identical solutions -- the one difference is that I think Harry's will fail on "0". Further if the source field is set to be of type "number", not "text", then "just letters" will evaluate to 0 in the calc, and also fail on Harry's. The "or 1" clause in my version of the case statement was put there specifically to deal with blanks and zeros, and it seems to be working here. ![]() -Dave In article <1131023489.574568.324570 (AT) o13g2000cwo (DOT) googlegroups.com>, hruby (AT) dataapex (DOT) com says... I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#8
| |||
| |||
|
|
Ok, I admit to not testing my solution. I guess that makes it more of a theory. But a '0' would not be empty and so it should evaluate properly. But I'm just not able to test it right now. I'll defer to Dave on this. 42 wrote: Just a minor correction regarding attribution: The other case statement that doesn't handle "0" was put forth by Howard, not Harry. (Forgive me both you: Harry for attaching your name to a bug you didn't make, and Howard for bringing this much attention to your minor bug just to clear my concsience.) -regards, Dave In article <MPG.1dd3ec06e4a80970989da1 (AT) shawnews (DOT) vf.shawcable.net>, nospam (AT) nospam (DOT) com says... Just retested here with the letter h, and the numbers 0 and -5, both worked. Must be something wonky at your end. Not sure if its my instructions that have the bug, or your execution of them yet though. Hmmmm....on second thought... Are you sure you implemented my 'case' and not Harry's very similiar one? We both came up with almost identical solutions -- the one difference is that I think Harry's will fail on "0". Further if the source field is set to be of type "number", not "text", then "just letters" will evaluate to 0 in the calc, and also fail on Harry's. The "or 1" clause in my version of the case statement was put there specifically to deal with blanks and zeros, and it seems to be working here. ![]() -Dave In article <1131023489.574568.324570 (AT) o13g2000cwo (DOT) googlegroups.com>, hruby (AT) dataapex (DOT) com says... I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#9
| |||
| |||
|
|
Howard, I did just test your version; and it did fail on zeros (and if the field monitored was "number" it failed on text too). While you are right that a '0' would not be empty, you didn't test for emptyness you tested for boolean 'truth', and in FM 'truth' is anything non-blank and non-zero. So while '0' satisifies the non-blank part it clearly doesn't satisfy non-zero part; and it evaluates to false in the simple case testing the field: case(field,get(timestamp)) Its worth pointing out that it would have worked on zero if you'd explicitly tested for emptyness: case(not isempty(field), get(timestamp)) But I still prefer the "or 1" tautological solution to emptyness testing because it will even trap the field-had-data-and-I-made-it-blank scenario, while emptyness testing won't. -regards, Dave In article <11mkkh7nctmmq2b (AT) corp (DOT) supernews.com>, howard (AT) antispahm (DOT) fmprosolutions.com says... Ok, I admit to not testing my solution. I guess that makes it more of a theory. But a '0' would not be empty and so it should evaluate properly. But I'm just not able to test it right now. I'll defer to Dave on this. 42 wrote: Just a minor correction regarding attribution: The other case statement that doesn't handle "0" was put forth by Howard, not Harry. (Forgive me both you: Harry for attaching your name to a bug you didn't make, and Howard for bringing this much attention to your minor bug just to clear my concsience.) -regards, Dave In article <MPG.1dd3ec06e4a80970989da1 (AT) shawnews (DOT) vf.shawcable.net>, nospam (AT) nospam (DOT) com says... Just retested here with the letter h, and the numbers 0 and -5, both worked. Must be something wonky at your end. Not sure if its my instructions that have the bug, or your execution of them yet though. Hmmmm....on second thought... Are you sure you implemented my 'case' and not Harry's very similiar one? We both came up with almost identical solutions -- the one difference is that I think Harry's will fail on "0". Further if the source field is set to be of type "number", not "text", then "just letters" will evaluate to 0 in the calc, and also fail on Harry's. The "or 1" clause in my version of the case statement was put there specifically to deal with blanks and zeros, and it seems to be working here. ![]() -Dave In article <1131023489.574568.324570 (AT) o13g2000cwo (DOT) googlegroups.com>, hruby (AT) dataapex (DOT) com says... I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
#10
| ||||
| ||||
|
|
Yes 42's solution works. I implemented Howards solution only (I overlooked "or 1") and it does't work even the field is text type. |
|
It doesn't work for any letters and zero character. Of coarse it is only theoretically interesting not important. |
|
I apologize for my mystake and to bother you. |

|
42 wrote: Howard, I did just test your version; and it did fail on zeros (and if the field monitored was "number" it failed on text too). While you are right that a '0' would not be empty, you didn't test for emptyness you tested for boolean 'truth', and in FM 'truth' is anything non-blank and non-zero. So while '0' satisifies the non-blank part it clearly doesn't satisfy non-zero part; and it evaluates to false in the simple case testing the field: case(field,get(timestamp)) Its worth pointing out that it would have worked on zero if you'd explicitly tested for emptyness: case(not isempty(field), get(timestamp)) But I still prefer the "or 1" tautological solution to emptyness testing because it will even trap the field-had-data-and-I-made-it-blank scenario, while emptyness testing won't. -regards, Dave In article <11mkkh7nctmmq2b (AT) corp (DOT) supernews.com>, howard (AT) antispahm (DOT) fmprosolutions.com says... Ok, I admit to not testing my solution. I guess that makes it more of a theory. But a '0' would not be empty and so it should evaluate properly. But I'm just not able to test it right now. I'll defer to Dave on this. 42 wrote: Just a minor correction regarding attribution: The other case statement that doesn't handle "0" was put forth by Howard, not Harry. (Forgive me both you: Harry for attaching your name to a bug you didn't make, and Howard for bringing this much attention to your minor bug just to clear my concsience.) -regards, Dave In article <MPG.1dd3ec06e4a80970989da1 (AT) shawnews (DOT) vf.shawcable.net>, nospam (AT) nospam (DOT) com says... Just retested here with the letter h, and the numbers 0 and -5, both worked. Must be something wonky at your end. Not sure if its my instructions that have the bug, or your execution of them yet though. Hmmmm....on second thought... Are you sure you implemented my 'case' and not Harry's very similiar one? We both came up with almost identical solutions -- the one difference is that I think Harry's will fail on "0". Further if the source field is set to be of type "number", not "text", then "just letters" will evaluate to 0 in the calc, and also fail on Harry's. The "or 1" clause in my version of the case statement was put there specifically to deal with blanks and zeros, and it seems to be working here. ![]() -Dave In article <1131023489.574568.324570 (AT) o13g2000cwo (DOT) googlegroups.com>, hruby (AT) dataapex (DOT) com says... I tried to test your idea. However I realized that it works for number>0 content of field-i-want-to-monitor only! I.e if I enter "0" or any letter the content of field-i-want-to-modify is empty. A strange behaviour isn't it? 42 wrote: In article <violon-043E62.09281803112005 (AT) sunsite (DOT) dk>, violon (AT) online (DOT) no says... Is it possible to find out when a field was last modified - not the entire record, but a certain field within that record? I'm on Filemaker 8. Define a field, set it as 'date' field, with an auto enter calculation: case(field-i-want-to-monitor or 1, get(currentdate)) make sure to A) tick the "replace contents" box in the field definition, and to B) to un-tick the "do not calculate if all referenced fields are empty" box on the bottom of the window where you specify the above calculation. basically, what happens is that the case clause is a tautology (it ALWAYS evaluates to true), and including the 'field-i-want-to-modify' in it creates a dependancy on the 'field-i-want-to-monitor'. So when the field-i-want-to-monitor is changed the autoenter calc is triggered, evaluates to true, and returns the current date as its new value. The A) option ensures that it will 'reset' itself each time the field is changed. (if its not set it will only work if the date field is empty. The B) option ensures that "erasing" the field-i-want-monitor still triggers the autoenter. |
![]() |
| Thread Tools | |
| Display Modes | |
| |