Jump to content

Confused regarding the Lookup function


mikedr

This topic is 3380 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I read a post here recently that referenced the Lookup function, which I wasn't familiar with. Did some digging, found this --

http://www.filemaker.com/help/html/relational.11.21.html#1028978

However, can those who are smarter than I (i.e., most people) provide information as to the usage scenarios for this function? I'm missing, basically, why you would use this, as opposed to properly defining a relationship between tables in the first place.

  • Like 1
Link to comment
Share on other sites

Data obtained using a lookup will remain unchanged unless you do a Re-lookup for it.

Example:

How about for something like your hourly rate, or for a tax rate, etc. that needs to remain unchanged in your existing records, but has to to be apply to new records.

The help you pointed at has two additional helps, check them out too.

Lee

  • Like 1
Link to comment
Share on other sites

I haven't used lookups in years.  As Lee mentioned after you do a lookup the data is static AND is now stored in two places.  If the data is to be kept in sync, you have to remember to trigger a relookup.

 

Lookups happen at the schema (field) level and can be sort of hidden from the overall scripted workflows and in that sense be easily overlooked.  Unlike calculated fields you can set a field that receives a lookup by a scripted action so it can get really confusing that way.

 

Traditional uses for lookups are for instance (using an invoice example- setting data in the invoice table)

- setting the tax % on an invoice to the tax % at the time the invoice is created

- same with the client info at the time of the invoice

 

In my mind it makes more sense to do this through a scripted action so that anyone can read what is going on just by following the script, without having to take a trip to the Manage Database screen to see how any lookup fields are defined.

Link to comment
Share on other sites

I use the Lookup FUNCTION on occasion. I'm speaking of the function, not the auto-enter option using a Lookup. It's all the same really. As previously mentioned, looking up a value via either method allows accurate history. For example, a table that records cheques will, if using the address of the recipient from a Contacts table, make all cheques written to a given person have the same address regardless of when the cheque was issued. Using an auto-entered value as a lookup, or using the Lookup function will enter the current address of the cheque recipient and preserve history.

Link to comment
Share on other sites

This topic is 3380 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.