Sima2004 Posted July 27, 2004 Posted July 27, 2004 Hello everybody, I have a many to many relationship between papers and journalists. How can i define a many to many relationship in filemaker to solve this problem? I have now the repeatition problem of the information because the papers and the journalists are in one file. Then if in one peper i have 4 pepole working,then i have the information of that paper 4 times in the database,I want to solve it in a way that i have two apart files(tables) and a table to connect them. The third table include the keys of two another table(paper and journalist). Can anyone help me with this problem please? Thankx, Sima
Ender Posted July 27, 2004 Posted July 27, 2004 It sounds like you have already worked out the solution: a Paper file, a Journalist file, and a Journalist-Paper join file between them.
QuinTech Posted July 27, 2004 Posted July 27, 2004 Hi Sima, if you want to be able to show the name of the Paper in the Journalist file and vice-versa, you will need to create calc fields in the join table: PaperName = Paper::Name JournalistName = Journalist::Name Now, on a journalist's record, if you want to display all the papers she has worked for, create a portal showing related records from the join table and include the field PaperName in that portal. Jerry
Sima2004 Posted July 28, 2004 Author Posted July 28, 2004 Hi Jerry, I have made a portal..but i have problem working with it. if i include a field in the first row it wouldn't be apear in the browse mode! I want to do the following: I want to make a portal and put a field on it with the name of journalist in the paper file. Beside it i want to have a button(thus in the same row)which goes to the related record in journalist file. I have problem using portals..also visibility problem..because if a put the same field on the second row then i'm able to browse it!!! How should i define the relations properly? Can you help me please? Thankx, Sima
Sima2004 Posted July 29, 2004 Author Posted July 29, 2004 I think there is something wrong with my relations.I have do that as follows... I have three tables. A)paper(key, name) B)join(paperkey,journalistkey,papername,journalistname) C)journalist(key,name) Join relations --> publications(paperkey=::key) journalists (journalistkey=::key) paper relations --> key=::paperkey journalist--> key=::journalistkey Can anybody tells me what is wrong with it? Thankx, Sima the fields papername and journalistname are cal. fields and they are defined as follows publications::papername journalists::journalistname
Sima2004 Posted July 29, 2004 Author Posted July 29, 2004 I have solved it thanks. Now i have a question. If you want to make the field on the portal modifiable what should you do? Thankx, Sima
Sima2004 Posted July 29, 2004 Author Posted July 29, 2004 I have one more question. If i hit the button to go to the related record ..i go to the join table but i want to go to the other table if i'm in paper table for instance i want to go to journalisten table. What i have to do? Any suggestions? Thankx, Sima
Sima2004 Posted July 29, 2004 Author Posted July 29, 2004 i can solve it with makeing two buttons on join table to go to the journalist or paper table ...but i want to go directely from paper to journalist and vice versa.. Any idea? Sima
Ender Posted July 29, 2004 Posted July 29, 2004 I have one more question. If i hit the button to go to the related record ..i go to the join table but i want to go to the other table if i'm in paper table for instance i want to go to journalisten table. What i have to do? Any suggestions? Go to Related Records [ Show only related records; From table: Journalist ] and Go to Related Records [ Show only related records; From table: Paper ]
Sima2004 Posted August 2, 2004 Author Posted August 2, 2004 That didn't solve the problem?! I can choose only a relationship and i have only one and that is to the join table from each table(paper and journalist). Do you know what i mean? Thankx, Sima
Ender Posted August 2, 2004 Posted August 2, 2004 Somehow I was under the impression you were running FM7. To do this in FM5/6, your join file will need relationships to each file too. Then you Go to Related Records scripts will look like this: From Paper: Go to Related Records [ Show , Journalist-Paper ] Perform Script [ Sub-scripts, External: "Journalist-Paper" (Go to Journalist) ] In Journalist-Paper have a script "Go to Journalist": Go to Related Records [ Show , Journalist ] Do the same kind of thing to go from Journalist to Paper.
Recommended Posts
This topic is 7475 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 accountSign in
Already have an account? Sign in here.
Sign In Now