Hi guys,
I am looking for some help with the problem below.
Basically, I have 2 tables where my goal is to look at the Table1_Count Records, and then based on the value on this field and its Timezone, I would like to look at Table_2 and assign an Account to Table1_Rep field.
Example:
Rep C has 4 records on Timezone CST, 2 on EST, 3 on PST. I would like to look at table 2 and assign to rep C, 4 accounts on timezone CST, 2 on timezone EST, and 3 on timezone PST...and so on and so forth for every record on my Table_1.
Table 1:
Rep | Timezone | Count Records |
A | PST | 2 |
B | PST | 2 |
C | CST | 4 |
C | EST | 2 |
C | PST | 3 |
D | PST | 1 |
E | CST | 1 |
E | EST | 2 |
E | PST | 8 |
Table 2
Account | Timezone |
A | PST |
B | PST |
C | CST |
D | CST |
E | CST |
F | EST |
G | EST |
H | EST |
I | EST |
K | PST |
L | EST |
M | CST |
I appreciate any insights. Thank you so much!!
@gcosta I am not sure I understand your requirement properly . Based on my understanding you can use the generate row tool to get it done
Hi @binuacs , sorry if is not clear but eventually what I want to do is to get something like the following table.
Using the Example of Rep C:
Account | Timezone | Table1(Rep) |
A | PST | C |
B | PST | C |
C | CST | C |
D | CST | C |
E | CST | C |
F | EST | C |
G | EST | C |
H | EST | |
I | EST | |
K | PST | C |
L | EST | |
M | CST | C |
Does it make sense?
Thank you so much for your help
Hi @binuacs , thank you so much ! I see what you ´ve done. That´s clever! Now, I am just wondering how can I remove duplicates and make sure an Account gets only one Rep assigned to it.
For example, looking at the outcome of your suggestion,
Account A, timezone PST can go to Rep A,B,C,D,E.
Account B, timezone PST can go to Rep A, B, C,D,E as well.
How could I make sure that the below is still respected? Rep A gets the 2 records, Reb B gets as well 2 records... so on and so forth
Table 1:
Rep | Timezone | Count Records |
A | PST | 2 |
B | PST | 2 |
C | CST | 4 |
C | EST | 2 |
C | PST | 3 |
D | PST | 1 |
E | CST | 1 |
E | EST | 2 |
E | PST | 8 |
I hope this makes sense and sorry for asking so many question. I am having a tough time on figuring out if I can do something like that using the tool.