Hi...
I'm new to Alpha and I've held off posting this question for two weeks reading through other posts and the help guide. For the life of me...I'm not getting it.
I have three tables:
broker_team
broker_teammate
remove_ff
I'm trying to get a grid working where I have two drop downs. One displays a list of Broker Teams from the broker_team table...that works...pretty simple. The second drop down is broker_teammate. I would like that drop down list to only show the teammates that are on the chosen broker team. ex. Team A has members 1,2,3...Team B has 4,5,6....if Team A is chosen the show only 1,2,3.
Within the broker_teammate table I have three fields. broker_teammate_id
broker_teammate
broker_team_id_fk
The broker_team table I have two
broker_team_id
broker_team
The remove_ff table
rff_id
broker_team
broker_teammate
item_type
item_id
created
I've tried the following with many variations:
Broker_Team_Fk=lookup("broker_team",".F.","Broker_team_id")
I also tried adding a fourth table (broker_membership)that shows a many to many relationship (two teammates work for 2 or more teams...that is why I tried that)...I think the confused me even more.
Broker_Teammate_Id=lookupc("f",remove_ff->broker_team_id_fk,"Broker_teammate_id_fk","broker_memebership","Broker_Team_Id_Fk")
Broker_Teammate_Id=lookup("broker_memebership","broker_teammate_id_fk","Broker_teammate_id_fk")
Any help would be appreciated...
Thx
Joe
I'm new to Alpha and I've held off posting this question for two weeks reading through other posts and the help guide. For the life of me...I'm not getting it.
I have three tables:
broker_team
broker_teammate
remove_ff
I'm trying to get a grid working where I have two drop downs. One displays a list of Broker Teams from the broker_team table...that works...pretty simple. The second drop down is broker_teammate. I would like that drop down list to only show the teammates that are on the chosen broker team. ex. Team A has members 1,2,3...Team B has 4,5,6....if Team A is chosen the show only 1,2,3.
Within the broker_teammate table I have three fields. broker_teammate_id
broker_teammate
broker_team_id_fk
The broker_team table I have two
broker_team_id
broker_team
The remove_ff table
rff_id
broker_team
broker_teammate
item_type
item_id
created
I've tried the following with many variations:
Broker_Team_Fk=lookup("broker_team",".F.","Broker_team_id")
I also tried adding a fourth table (broker_membership)that shows a many to many relationship (two teammates work for 2 or more teams...that is why I tried that)...I think the confused me even more.
Broker_Teammate_Id=lookupc("f",remove_ff->broker_team_id_fk,"Broker_teammate_id_fk","broker_memebership","Broker_Team_Id_Fk")
Broker_Teammate_Id=lookup("broker_memebership","broker_teammate_id_fk","Broker_teammate_id_fk")
Any help would be appreciated...
Thx
Joe
Comment