Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I want to find
If each product uses 1 lower arm, 20 screws, 2 upper arms and 2 housings, how many complete products can i assemble?
MachineNumber | Start | Stop | Program | CoolantPumped | RPM | OpID |
1 | 07:30 | 08:00 | Lower Arm | 22 | 2000 | 4 |
1 | 08:10 | 08:50 | Lower Arm | 47 | 8000 | 4 |
1 | 08:30 | 08:40 | DETECT STOP | 0 | 0 | 4 |
1 | 09:15 | 09:40 | Lower Arm | 24 | 2200 | 4 |
1 | 09:47 | 10:23 | Lower Arm | 22 | 2000 | 4 |
1 | 10:35 | 11:05 | Lower Arm | 27 | 2300 | 4 |
2 | 07:05 | 07:10 | Housing | 5 | 9717 | 3 |
2 | 07:11 | 07:13 | Housing | 5 | 10398 | 3 |
2 | 07:16 | 07:21 | Housing | 5 | 9988 | 3 |
2 | 07:27 | 07:30 | Housing | 5 | 10900 | 3 |
2 | 07:38 | 07:42 | Housing | 5 | 10184 | 3 |
2 | 07:49 | 07:54 | Housing | 5 | 9925 | 3 |
2 | 08:00 | 08:03 | Housing | 5 | 10533 | 3 |
2 | 08:11 | 08:13 | Housing | 5 | 10731 | 3 |
2 | 08:22 | 08:24 | Housing | 5 | 10862 | 3 |
2 | 08:33 | 08:35 | Housing | 5 | 10859 | 3 |
2 | 08:44 | 08:49 | Housing | 5 | 9018 | 3 |
2 | 08:55 | 09:00 | DETECT STOP | 0 | 0 | 3 |
2 | 09:06 | 09:17 | Housing | 5 | 9171 | 3 |
3 | 07:02 | 07:03 | Screw | 0.2 | 300 | 1 |
3 | 07:04 | 07:05 | Screw | 0.2 | 300 | 1 |
3 | 07:06 | 07:07 | Screw | 0.2 | 300 | 1 |
3 | 07:08 | 07:09 | Screw | 0.2 | 300 | 1 |
3 | 07:10 | 07:11 | Screw | 0.2 | 300 | 1 |
3 | 07:12 | 07:13 | Screw | 0.2 | 300 | 1 |
3 | 07:14 | 07:15 | Screw | 0.2 | 300 | 1 |
3 | 07:16 | 07:17 | Screw | 0.2 | 300 | 1 |
3 | 07:18 | 07:19 | Screw | 0.2 | 300 | 1 |
3 | 07:25 | 07:26 | Screw | 0.2 | 300 | 1 |
3 | 07:27 | 07:28 | Screw | 0.2 | 300 | 1 |
3 | 07:29 | 07:30 | Screw | 0.2 | 300 | 1 |
3 | 07:31 | 07:32 | Screw | 0.2 | 300 | 1 |
4 | 08:00 | 09:05 | Upper Arm | 60 | 12000 | 10 |
4 | 09:30 | 10:25 | Upper Arm | 60 | 12000 | 10 |
4 | 10:50 | 11:49 | Upper Arm | 60 | 12000 | 10 |
4 | 12:09 | 13:02 | Upper Arm | 60 | 12000 | 10 |
4 | 13:30 | 14:21 | Upper Arm | 60 | 12000 | 10 |
4 | 14:45 | 15:31 | Upper Arm | 60 | 12000 | 10 |
4 | 15:59 | 16:49 | Upper Arm | 60 | 12000 | 10 |
4 | 17:24 | 18:21 | Upper Arm | 60 | 12000 | 10 |
4 | 18:56 | 19:51 | Upper Arm | 60 | 12000 | 10 |
5 | 08:05 | 09:04 | Upper Arm | 60 | 12000 | 10 |
5 | 09:28 | 10:15 | Upper Arm | 60 | 12000 | 10 |
In this example, there won't be even a single product made because there are only 13 screws available. But assuming you need only 13 screws, you can try this:
=RangeMin(Floor(Count({<Program = {'Housing'}>}Program)/2),
Floor(Count({<Program = {'Lower Arm'}>}Program)/1),
Floor(Count({<Program = {'Screw'}>}Program)/13),
Floor(Count({<Program = {'Upper Arm'}>}Program)/2))
For 20, you can do this:
=RangeMin(Floor(Count({<Program = {'Housing'}>}Program)/2),
Floor(Count({<Program = {'Lower Arm'}>}Program)/1),
Floor(Count({<Program = {'Screw'}>}Program)/20),
Floor(Count({<Program = {'Upper Arm'}>}Program)/2))
Not sure I understand, what would be the expected output from the sample data you have provided?
Hi Sunny,
I want to find how many Products i can produce.
A Product can be made if we have 1 lower arm, 20 screws, 2 upper arms and 2 housings.
Joshua - so if, for example, you have lots of screws, upper arms and housing, but only 2 lower arms, that limits you to making just 2 products?
If so, you can count the totals of each of these components and then do the maths.
You might like to use the FLOOR function.
Hi Ritchard,
can you make it in expression.
Dear Sunny T
Are u clear with What i am expecting.
In this example, there won't be even a single product made because there are only 13 screws available. But assuming you need only 13 screws, you can try this:
=RangeMin(Floor(Count({<Program = {'Housing'}>}Program)/2),
Floor(Count({<Program = {'Lower Arm'}>}Program)/1),
Floor(Count({<Program = {'Screw'}>}Program)/13),
Floor(Count({<Program = {'Upper Arm'}>}Program)/2))
For 20, you can do this:
=RangeMin(Floor(Count({<Program = {'Housing'}>}Program)/2),
Floor(Count({<Program = {'Lower Arm'}>}Program)/1),
Floor(Count({<Program = {'Screw'}>}Program)/20),
Floor(Count({<Program = {'Upper Arm'}>}Program)/2))
Dear Bro,
Thank You very much.
No problem at all