Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

relating 2 databases, 1 main, 1 info


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

Recommended Posts

Posted

i have been trying to relate a database with my main shell. all i want to do is do a find from my main shell to a information database. the fields that i am finding are the related fields on the info file. now what i am looking for "workable time" and "day of work". i made 1 field in each program and is a constant key. i used 999. the relationship works but when i do a find for a time, all the records show up in the portal window i made. example. i have 4 records that are the same day but have 4 different hours... 9,12,3,6. if i do a find for 12... all the records show up. i know that i am to make each record unique, so i made a field that is a calculation... date and time of the creation. this is a number that is always different. the problem is the main shell is just for viewing. there are no records being created.

i have no clue what i am doing wrong.

Peter

Posted

First of all, a constant relationship is going to show you all records from the related file. It is not affected by the current found set in either file.

Not sure if this is what you want: in your main file, create a date field (I think you'd want a global field). Make a relationship based on the date field, and you can see all the times for that date in a portal.

Another possibility is to make a portal/relationship based on a global text field in the main file and your unique id in the related file. Now, do a find in the related file. Then go to a layout with ONLY the id field on it and Copy All Records. Return to the main file and paste into the global text field. Ta da! All your found records in the portal.

Posted

Hi Peter,

Here's an option:

In your main shell, define two global fields: Filter_Time (Global Time) and Filter_Date (Global Date).

Then define a calculation field (unstored, text):

Filter_Date_Time_Key = If (not IsEmpty(Filter_Date), DateToText(Filter_Date) & TimeToText(Filter_Time), "all")

Now define a calculation field (stored, text) in your related file:

Date_Time_Key = "all" & "

This topic is 8258 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.