stealth162 Posted September 7, 2005 Posted September 7, 2005 I'm trying to setup my database so that I can basically have a global status for all the records in that database. So I'd have a main layout page that sayed ie; "Final Version". This would be changeable by me on the main layout page. Problem now is that the data I put into that field now becomes linked to a specific record, so as scrolling through records the global status disappears. I'm thinking I need a relationship and something linking a table that holds all the records to the table that is escentially my 'global' status. Is this correct? Not sure how to set something like this up. Any help is greating appreciated.
T-Square Posted September 8, 2005 Posted September 8, 2005 Set up a single text field as a global field. Go to the field definition screen, add your field (gVersion - text field). Then select the field's options, and locate the option to store the content globally.
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 The only hitch is that I want to post this online via FM server, but globals do not work online. Any other thoughts?
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 Anyone able to offer any advice? This has to be capable of running on a server version of FM.
-Queue- Posted September 8, 2005 Posted September 8, 2005 Create a one-record preferences table/file that is related to all other desired tables via the X operator and make your status field a normal text field.
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 What do you mean the "X" operator? I'm sorry, but I may need a little hand holding and more literal explanation of what needs to be done. I understand how to make a new table and the field etc. Just haven't done the relationship thing.
-Queue- Posted September 8, 2005 Posted September 8, 2005 The X operator is an option when creating a relationship, along with =, <>, >, etc. Using the X operator creates a relationship which matches each record in one table with all records in the related table. It is the same as using a constant-to-constant relationship, without the extra field overhead. Using a relationship which matches a field in the main table to a field in the preferences table via the X operator allows you to display/access the status field in all records in the main table. Does that help?
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 I think I've set most of it up properly. I created a new table and defined fields that will be used to store the info that I want to use as 'global info'. ie; Project Status I setupt the relationships so that the respective fields match each other and set them to use the X operator. After setting that all up. I go back to my main "menu" page and type into this field and then proceed to scroll through records. The info stays linked to the record. So my status message goes away unless I'm on the record to witch I was when I entered the status. Any thoughts as to what I might be missing?
-Queue- Posted September 8, 2005 Posted September 8, 2005 Have you put the new related status field on the layout or are you still using the original field?
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 I'm using the original field from the original table on that main layout. Do I need to use the new one that I created? Do I have to create a layout with all the fields from the new table so the relationship will work or do those related fields not need to be on a layout to work?
-Queue- Posted September 8, 2005 Posted September 8, 2005 Put the status field from the preferences table on the main layout. Your original status one is now obsolete. You do not need an extra layout with the preferences fields for them to work correctly. Out of curiosity, what match fields did you use for the relationship, because you can basically use any two fields for a Cartesian (X) join to work, even two globals; there is no required criteria for matching one record to all others, so FM could care less which ones you use.
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 Here's what I've done so far. Created New Table Defined new fields in that table Set relationship (x) for fields from original table to new one Changed field that I'd like to use as "global status' to reference the new one in the new table. The fields are all text fields. Once I did the switch to reference the new field it will no longer let me enter any text into the field. Is it maybe because that table has no records and needs to have at least one?
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 I got it working! I made the stupid mistake of not even creating a record in the main table. Obviously you need a record to add info. Thanks so much for your help. One small thing that I need to figure out now and you may know is this: I have several different layouts and at the top of all these layouts I have displayed the text from that "status" field. I used to display it by typing this to reference the fields text <> That would reference the field 'ProjectStatus' and let me display it. How would I display info like that from a field in a different table?
-Queue- Posted September 8, 2005 Posted September 8, 2005 Use <>, if the name of your related Table Occurrence is called Preferences. In general, <>.
stealth162 Posted September 8, 2005 Author Posted September 8, 2005 Awesome! Thanks so much for all your help. You are the man!!
Recommended Posts
This topic is 7073 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