Skip to main content

Compare BOMs stored in Excel files

Project description

bomcheck

What the program does

The bomcheck.py program compares Bills of Materials (BOMs). BOMs from a CAD (Computer Aided Design) program like SolidWorks are compared to BOMs from an ERP (Enterprise Resource Planning) program like SyteLine. The CAD and ERP programs must be able to export to Excel files because that is where bomcheck gathers data from.

How to install

Assuming that you already have Python on your machine, use the package manager software pip that comes with Python and run this from a command line:

pip install bomcheck

Compared BOMs come from Excel files

The name of a file containing a BOM that comes from a CAD program must have the syntax: PartNumberOfBOM_sw.xlsx. That is, names like 0399-2344-005_sw.xlsx, 093352_sw.xlsx, and 35K2445_sw.xlsx are all legitimate file names. The names of the files from the ERP program have the same syntax, but instead end with _sl.xlsx. Thus the names will look like 0399-2344-005_sl.xlsx, 093352_sl.xlsx, and 35K2445_sl.xlsx. The program will match the 0399-2344-005_sw.xlsx file to the 0399-2344-005_sl.xlsx file, and so forth.

Multilevel BOMs are allowed

A file can contain a mulilevel BOM. In which case individual BOMs are extracted from a top level BOM. For a BOM from the ERP program to be recognized as a multilevel BOM, a column named "Level" must exist that gives the relative level of a subassembly to the main assembly. (The name "Level" can be altered with the file bomcheck.cfg. See info below.) The Level column starts out with "0" for the top level assembly, "1" for part/subassemblies under the main assembly, "2" for a part/subassembly under a Level "1" subassembly, and so forth. From the CAD program, it is similar. However item nos. indicate the Level, for example item nos. like 1, 2, 3, 3.1, 3.2, 3.2.1, 3.2.2, 3.3, 4, etc., where item 3 is a subassembly with parts under it.

How to run

Enter this on the command line to run:

bomcheck

(An easier way to get started is to use bomcheckgui)

Sample output

An Excel file is output. Shown below is an example of the result of a BOM comparison:

assy Item IQDU Q_sw Q_sl Descripton_sw Description_sl U_sw U_sl
730322 130031 XXXX 1 HOUSING EA
130039 XXXX 1 HOUSING EA
220978 ‒‒‒‒ 1 1 SPUR GEAR SPUR GEAR EA EA
275000 ‒‒‒‒ 0.35 0.35 TUBE TUBE FT FT
380000 ‒‒‒‒ 2 2 BEARING BEARING EA EA
441530 ‒‒‒‒ 1 1 SHIFT ASSY SHIFT ASSY EA EA
799944 ‒‒X‒ 1 1 SHAFT AXLE EA EA
877325 ‒XX‒ 3 1 PLUG SQ. HEAD PLUG EA EA
900000 ‒‒‒‒ 0.75 0.75 OIL OIL GAL GAL
441530 433255 ‒‒‒‒ 1 1 ROD ROD EA EA
500000 ‒‒‒‒ 1 1 SHIFT FORK SHIFT FORK EA EA
K34452 ‒‒‒‒ 1 1 SPRING PIN SPRING PIN EA EA

The column IQDU shows Xs if Item, Quantity, Description, or Unit of measure don't match between the two BOMs. Q_sw is the quantity per the CAD BOM, Q_sl per the ERP BOM, and so forth. In the example above, 1309031 is in the ERP BOM, but not in SolidWorks. 130039 is in the CAD's BOM, but not in the ERP's BOM.

Units of measure

If a Unit of Measure (U/M) is not given for a value in the Length column of a SolidWorks' BOM, then the U/M is assumed to be inches unless explicity specified, e.g. 336.7 mm. The program recognizes the follwing U/Ms:

in, inch, ", ft, ', feet, foot, yrd, yd, yard, mm, millimeter, cm, centimeter, m, meter, mtr, sqin, sqi, sqft, sqf, sqyd, sqy, sqmm, sqcm, sqm, pint, pt, qt, quart, gal, g, gallon, ltr, l, liter

When the program is run, values will be converted to the U/M given in the ERP's BOM. For example, if the ERP program uses FT as a U/M, then comparison results will be shown in feet.

bomcheck.cfg

Bomcheck has a configuration file available named bomcheck.cfg. With it the default U/M measure can be switched from inches to mm, or to some other U/M. Also, column names can be changed, and so forth. Within the bomcheck.cfg file are explanations about settings that can be employed. To get started, download the bomcheck.cfg from here, then open the file with a text editor and modify it as suits you best.

 


 

You can try out the program online by clicking:    Open In Colab or Binder,    These are both Jupyter Notebooks. Open the file browser of the notebook (folder icon at upper left), create a folder named "mydata", and upload your data to it.

For more information, see the web page bomcheck_help.html

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bomcheck-2.4.tar.gz (1.2 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bomcheck-2.4-py3-none-any.whl (45.7 kB view details)

Uploaded Python 3

File details

Details for the file bomcheck-2.4.tar.gz.

File metadata

  • Download URL: bomcheck-2.4.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for bomcheck-2.4.tar.gz
Algorithm Hash digest
SHA256 9866eb81989b2f3d6900ec526f393b15de0b864b3fce2460802b97dcba03d626
MD5 4b0790cbec0a365060fb9ffb23d15608
BLAKE2b-256 d6d22443ab9cea17c52f2907d5fb61a25b6db6bcfa947b727de97ec8e314dfb1

See more details on using hashes here.

File details

Details for the file bomcheck-2.4-py3-none-any.whl.

File metadata

  • Download URL: bomcheck-2.4-py3-none-any.whl
  • Upload date:
  • Size: 45.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for bomcheck-2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 808be7945d2e078ec9d4761d8e7298204204f916e70541c00eb5715e2e97257d
MD5 2937d4364f323c23044948af15e7123f
BLAKE2b-256 d5ba5bbc0f26862bbfb1430dd6e4b145232f6f7cf018c57c150ffc077bbf8a9c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page