Corey-Troy Posted December 4, 2009 Posted December 4, 2009 I am working with 2separate fields[item]&[price] that has 2 repetitions each on a layout(page 1). On another layout(Page 2), i have a repeating field(10)[items available], that lists items that are used in the dropdownlist of [item] on Page 1. There is also a repeating field(10)[cost of items], that list prices for each of the items available. I want the user to select an item from the dropdown list of [item], and the [price] field will pull in the value from the other field in Page 2 that relates to the item selected. How do i do this? I created a relationship between:- [item] - [items available] , but i always get in the [price] field, the value in [cost of item]repetition 1 only. What fields do i need to create the relationship with each other?
Ocean West Posted December 4, 2009 Posted December 4, 2009 I sincerely recommend NOT to use repeating fields for such data - when you put a field on a layout and you ask yourself does the user need to enter ONLY one of type of data - be it price, cost, item. By normalizing your data and putting the data in its own field in a separate table and use a portal for the user interaction. In most cases you will quickly find that you would like to create reports based on data entered. You will find MANY developers typically will refrain from using repeating fields for any user data. You are describing a typical parent child relationship between invoice/quote and associated line items. I assume you have another table that is your catalog or price list that you wish to LOOKUP the data from or display from a drop down list.
comment Posted December 4, 2009 Posted December 4, 2009 See also: http://fmforums.com/forum/showpost.php?post/309136/
Corey-Troy Posted December 7, 2009 Author Posted December 7, 2009 Thanks for the reply. If i have 10 Item Fields and 10 Price fields, so i would make these as separate fields instead of repeating fields. Does that mean i then need to create a relationship to each of 10 fields then? Corey....
Corey-Troy Posted December 7, 2009 Author Posted December 7, 2009 Sorted it out by the looks of it. I was not creating a separate Table for the Items and Prices and creating separate records for each one.
Recommended Posts
This topic is 5525 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