dbTalk Databases Forums  

force calc field/relation to update

comp.databases.filemaker comp.databases.filemaker


Discuss force calc field/relation to update in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Christoph Kaufmann
 
Posts: n/a

Default force calc field/relation to update - 12-14-2010 , 12:26 PM






FMP 8 Adv: A calc field pulls a value out of a relation.

On the left side of the relation, there's another calc field that
depends on a global field which is in a different table.

When I change the global field, the calc field on the left side of the
relation updates immediately. The field that pulls the value out of the
relation, however, won't update until I refresh the window.

What's the problem here?
The solution runs on FMP 8, meaning I can't use triggers.

--
http://clk.ch

Reply With Quote
  #2  
Old   
Remi-Noel Menegaux
 
Posts: n/a

Default Re: force calc field/relation to update - 12-14-2010 , 01:11 PM






Try 'unstore' the calc ?
Remi-Noel

"Christoph Kaufmann" <clk (AT) tele2 (DOT) ch> a écrit dans le message de
news:1jti8fd.7k4j3j1fvo0qmN%clk (AT) tele2 (DOT) ch...
Quote:
FMP 8 Adv: A calc field pulls a value out of a relation.

On the left side of the relation, there's another calc field that
depends on a global field which is in a different table.

When I change the global field, the calc field on the left side of the
relation updates immediately. The field that pulls the value out of the
relation, however, won't update until I refresh the window.

What's the problem here?
The solution runs on FMP 8, meaning I can't use triggers.

--
http://clk.ch

Reply With Quote
  #3  
Old   
Christoph Kaufmann
 
Posts: n/a

Default Re: force calc field/relation to update - 12-14-2010 , 01:16 PM



Remi-Noel Menegaux <rnmenegaux (AT) free (DOT) fr> wrote:

Quote:
Try 'unstore' the calc ?
The calc is

relatedTable::field

so it's by definition unstored.

I tried with evaluate, but no luck.


--
http://clk.ch

Reply With Quote
  #4  
Old   
Your Name
 
Posts: n/a

Default Re: force calc field/relation to update - 12-14-2010 , 06:08 PM



In article <1jti8fd.7k4j3j1fvo0qmN%clk (AT) tele2 (DOT) ch>, clk (AT) tele2 (DOT) ch (Christoph
Kaufmann) wrote:

Quote:
FMP 8 Adv: A calc field pulls a value out of a relation.

On the left side of the relation, there's another calc field that
depends on a global field which is in a different table.

When I change the global field, the calc field on the left side of the
relation updates immediately. The field that pulls the value out of the
relation, however, won't update until I refresh the window.

What's the problem here?
The solution runs on FMP 8, meaning I can't use triggers.
It could be another problem caused byt the silly new "feature" where
FileMaker doesn't actually save changes like it used to. That means you
may have to Script the change making sure to Comit the new data. (

Helpful Harry )

Reply With Quote
  #5  
Old   
Howard Schlossberg
 
Posts: n/a

Default Re: force calc field/relation to update - 12-14-2010 , 10:45 PM



On 12/14/2010 10:26 AM, Christoph Kaufmann wrote:
Quote:
FMP 8 Adv: A calc field pulls a value out of a relation.

On the left side of the relation, there's another calc field that
depends on a global field which is in a different table.

When I change the global field, the calc field on the left side of the
relation updates immediately. The field that pulls the value out of the
relation, however, won't update until I refresh the window.

What's the problem here?
The solution runs on FMP 8, meaning I can't use triggers.

That's just how it behaves...more or less, depending on version, your
mileage will vary. The related records are cached and won't refresh
until you do something to specifically refresh the calc. As you
mentioned, performing a Refresh Window will do the trick. But so will
updating the relationship that the calc is based on IF the relationship
match field is based in the local table.

In your case, the calc field is based in the local table, but the field
that triggers it to update is the global in the other table. If you
were to move the global to the local table, then I believe you would see
everything update as you are expecting.

Since globals can pretty much live anywhere, perhaps you can move it for
this one piece of functionality.

For what its worth, I have found that in FM 11, a screen refresh does
not cause the entire screen to flash as it did in 10 and prior. But I
found that a trick to just updating a portal in those earlier versions
was to trigger the relationship itself to refresh by setting the key
field (or a local component thereof) to itself.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Howard Schlossberg
FM Professional Solutions, Inc. Los Angeles

FileMaker Certified Developer
Associate Member, FileMaker Business Alliance

Reply With Quote
  #6  
Old   
Christoph Kaufmann
 
Posts: n/a

Default Re: force calc field/relation to update - 12-15-2010 , 12:50 AM



Howard Schlossberg <howard (AT) nospam (DOT) fmprosolutions.com> wrote:

Quote:
I
found that a trick to just updating a portal in those earlier versions
was to trigger the relationship itself to refresh by setting the key
field (or a local component thereof) to itself.
I tried Evalauate as well as If ( 1 OR SameFeld ), but no joy. Used a
secons global now and a script to set it.
--
http://clk.ch

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.