# Handling Large Number of Variants

Hi, I work for a custom manufacturing company that handles many item variants. One example is that we buy standard sheets of aluminum (4ft x 10ft, 4ft x 12ft, …, different thicknesses, different colors). We cut these sheets into smaller pieces, then sell the smaller pieces and have a lot of leftover pieces of aluminum we put back in inventory to be used in the future. These leftover pieces can be weird dimensions like 2.43ft x 7.23ft. We also need to track the batch number as the paint colors are different between different purchases.

As you can see, we could have possibly 100s of variants of a certain item. We think of items as being the color of the raw material (item = Red Aluminum Sheet), and the variants are the dimensional properties (length, width, thickness). We have a developer team so are able to programmatically create/delete variants.

Here’s the workflow I am thinking:

1. We manually create item templates for the standard purchasing sheet dimensions (roughly 5-30 variants for each item template).
2. Our manufacturing software knows the dimensions of the leftover pieces of aluminum sheets when we cut them. We use the REST APIs to create these new variants (Red Aluminum 2.43ft x 7.23ft) when this happens. We enter these pieces into inventory.
3. Once one of these strange dimensional variants leaves inventory (we scrap or consume), we erase these variants from the item template to keep the list manageable.

Does this workflow make sense? Can anyone see any issues with it?
Thanks.

I can see where the issue might be.

If one of your dimensions are fixed (for example, you only have off-cuts of 1.75ft, ,2.43ft, 5.1ft…and so on, you could create variants for that width. The length could then become the quantity. This means you will have to invoice every piece of sheet that you dispatch.

Another option is to work out a square ft cost. So, say a square ft is \$ 25.00. then a 2.43ft x 7.23ft will be 17.5689 * \$ 25.00 = \$ 439.2225

we are steel fabrication company also facing this. we have material plate and pipe which vary in size.

I wonder if having items as purchased as Items , for example by sheet thickness or pipe diameter , and then variants for color and dimensions.

@crafter

Thanks for the response. We have two variable dimensions (length and width). My concern is that there are limits to the number of variants you can make for a product template (either a hard limit in the Stock module or its interaction with other modules). I tested one case where I had many thousands of variants and it technically worked, but took about 30 seconds to load the popup when I clicked “create” on the product template page to actually make some of these variants.

I think if the APIs are reliable, then we should be able to create logic that would work smoothly.

Hi , I think you can use batch for this situation, so you can make item = Red Aluminum and add the dimensions as batch on it

That’s a creative idea. I’ll look into that option as well.

I need these dimensional values to be programmatically accessible for our production process software-- our software will read both the count of available sheets and their dimensions to determine the best way to cut the required customer’s shapes. I’ll read through the API documentation and check if I can programmatically access the “Batch Description” property of the Item.

@smino
I think that you could handle it that way as well. We could create item templates:

Aluminum 3mm, Aluminum 4mm, Aluminum 5mm

Each of them has variants (color: red, blue green)
We sometimes want to programmatically ask inventory “What are the available sheets of all thicknesses of red aluminum?” We could solve this by placing these items in an Item Group “Aluminum Sheets” or something like that. I’ll think more about a setup like this where we enumerate one of the variations of an item into various item templates.

for more clarity, you can have 2 custom fields in batch to put this dimensional, so it can be easiest way for handling with API.

2 Likes

Thanks I’ll look into it. I like how responsive and active the forums for ERPNext are.

3 Likes