Solved

Fixed portal raws in Filemaker

Posted on 2011-09-12
4
392 Views
Last Modified: 2012-06-22
Hi,
I have a flat Filemaker database that I would like ti split to make it more flexible.
The database stores names and what sports they like. (just a silly example).
As it is now, in the flat design, I have hardcoded 10 sports. All of them has one field in the flat datebase. Yes or no field
So when I recreate the database with more than 1 table I get.

Customers tbl
- CustID
- Name

Sports tbl
- CustID
- Sports

In this case, I will not see the sports that they dont like. I will just se the lines that I have created in the sports table by relation to Customers tbl.

Has anyone an idea of how to get a fixed amount of lines in the portal on creation of a post in custumors tbl. And also of course how to add the necesary lines in Sports tbl for the existing ones.

I would like to solve this to be able to add any sport wihount loosing the visibility of sports to choose from. Thjs is the tricky part.

No problems on creation. I could add a button that imports the lines from someware else. But how do I fill up the missing sports for existing once?
 
I hope my explonation was good enoughf

Thanks
0
Comment
Question by:peroscar
4 Comments
 
LVL 12

Assisted Solution

by:North2Alaska
North2Alaska earned 250 total points
ID: 36522997
The first thing I see is a fundamental problem with your table design.  The way you have laid it out you can only have a given sport assigned to one customer.  You need to create a Many-To-Many relationship.  So you will need three tables

Customer tbl
- CustId
- Name

Sports tbl
-SportID
-Sport

Customer_Sport tbl
- CustID
- SportID

Now you create the appropriate relationships by connecting the ID fields together.  Get that working and we can go from there.
0
 
LVL 25

Accepted Solution

by:
Will Loving earned 250 total points
ID: 36523055
I would suggest that the best way to proceed is to NOT create more Sports records (you're calling them lines) for each Customer than you actually need. This would not be much different that what you already have. One of the points of having a relational data structure is to only have as many related records as you need, rather than having as you do now a field for each sport - whether or not it is checked - or as I think you are trying do, to create a related sports record for every sport.

To answer you question, a simple way to add multiple 'lines' (related records) to the portal all at once is to create a script that captures the Customer ID, goes to a layout based on the Sports table, creates however many records you want and then returns to the Customer layout. However, I would recommend the following instead:

Create a Value List for all the sports that you want to be able to select. Go to File -> Manage -> Value Lists and then enter the values you want in the Custom Values area.
Once you have created your value list, go to your Portal on the Customer screen, go to Layout mode, highlight the "Sports" field
In the Inspector pallette, under the "Data" tab, look for "Control Style" and change it from Edit Box to Popup menu
Go back to Browse and you should be able to select a list of sports from the popup menu. Each time you select a sport, a new related record will be created (as long as you have "Allow creation of records in this table via this relationship" checked for your relationship from Customers to Sports (on  the Sports) side.

If you don't like this idea, I can still advise you on how to setup a script to create a fixed number of records. The advantage of the method described above is that each customer has records only for the sports that they are interested in. You add a new sport at any time and you can also update your value list at anytime to include new sports for the popup menu.
0
 
LVL 8

Expert Comment

by:Tocacar
ID: 37194149
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Conversion Steps for merging and consolidating separate Filemaker files The following is a step-by-step guide for the process of consolidating two or more FileMaker files (version 7 and later) into a single file with multiple tables. Sometimes th…
Having just upgraded from Filemaker 11 to Filemaker 12 over the weekend, we thought we would add some tips for others making the same move.  In general, our installation went without incident. Please note that this is not a replacement for Chapter 5…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question