set_bill_of_materials
Attach a bill of materials to a finished-goods stock item in Tally Prime, so manufacturing journals use the predefined component ratio instead of typed quantities.
Instructions
Attach a Bill of Materials (recipe) to an existing finished-goods stock item, so a Manufacturing/Stock Journal producing this item can have its component quantities computed from a fixed ratio instead of typed by hand every time. Uses Tally's native MULTICOMPONENTLIST.LIST structure. This is a pure convenience layer over create_stock_journal — it does not affect stock or post anything by itself; you still call create_stock_journal to actually record a production run, scaling each component's qty by the ratio to basicQty yourself (this tool does not auto-compute that scaling for you). EXTRAPOLATED from a genuine Tally-exported XML template's stock item master shape, not reverse-engineered from a real manually-created BOM — verify carefully after use, especially natureOfItem's accepted values.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| unit | No | Unit of measure for basicQty, e.g. 'Nos'. | |
| basicQty | No | The quantity of stockItem this recipe produces (the ratio base). Defaults to 1. | |
| stockItem | Yes | Exact name of the existing finished-goods stock item to attach this BOM to | |
| components | Yes | The raw materials (and any co-products/scrap) in this recipe. | |
| componentListName | No | Name for this BOM/recipe (Tally allows more than one per item). Defaults to 'Primary'. |