Brief overview of how two different databases are queried to create various AutoCAD Electrical BOM reports.
This question comes up from time to time, most recently today. Here is a brief summary in the form of screenshots illustrating how a component on an AutoCAD Electrical drawing (a mechanical footprint symbol on a panel layout drawing) finds its way on to a BOM report. This illustrates just a simple, straightforward catalog assignment – without “ASSYCODE” and without “Multi-BOM” catalog assignments (future posting!).
A small portion of one drawing, DEMO08.dwg, which is part of a sample AutoCAD Electrical project drawing set “WDDEMO”, is shown below.
AutoCAD Electrical maintains a “scratch” database file, in Microsoft Access format, that follows what is going on in the project drawing set (it does not drive it, it follows it). The above mechanical footprint component, SS433 on drawing DEMO08.dwg of the project, shows up in the “PNLCOMP” table of the scratch database file for this project.
The scratch database file name is the same name as the active AutoCAD Electrical project name but with an “.mdb” extension. It is saved in the local AutoCAD Electrical “user” folder. The full name can be displayed by typing this at the AutoCAD “Command:” prompt.
Command: (c:wd_mdb_get_proj_scratch_dbnam nil) [Enter]
Here is a screenshot of the above panel component in the PNLCOMP table of the project scratch database:
And here’s another screenshot of the above record with a few other fields exposed. These fields are used to guide AutoCAD Electrical’s BOM reporting command to the appropriate “table” in the catalog lookup database file DEFAULT_CAT.mdb (shown shortly).
The actual table name that the BOM report queries for this “SS433″ symbol’s catalog description information is influenced by the WDBLKNAM value shown above. See this posting for a description of how auto-table selection works.
Ultimately, the BOM reporting goes to table “SS” in the DEFAULT_CAT.mdb file. It uses the MFG/CAT attribute values carried on the panel footprint symbol (and extracted into the PNLCOMP table shown above) to find the appropriate record in the “SS” table shown here:
And now the BOM reporting command merges the data in the record above with the data from the scratch database file. It is formatted into the report and shows up as an entry here in the BOM Report Generator dialog ( ! ):
Now, at this point, you can write the report out to a file (in various formats) or insert the report as a “smart” table on to your AutoCAD drawing.