Home Search

DriveWorks Pro 21
BOM To Database

Send Feedback
This PowerPack has been superseded.

Please use the following method for exporting a SOLIDWORKS BOM to a database:

  1. Use the SOLIDWORKS PowerPack - Export BOM Generation Task to export the BOM as a text file.
  2. Apply the Specification PowerPack Import Lines From a Text File into an Existing Table Task to a paused State in the Specification Flow.
    The paused State will need to be entered after the Models are generated and the Generation Task is run.
  3. Set up one of the following to Export the table to a database:

When using DriveWorks Autopilot consider using a Triggered Action to automatically transition the Specification to each State.

BOM To Database

DriveWorks Labs PowerPacks can be updated more often than the main release.

Please consult the Online Help File for the most up to date information and functionality.

The BOM to Database plugin runs on a SOLIDWORKS Assembly and exports its BOM directly from the assembly to a database.

This plugin is machine specific and should be installed on each machine where specifications can be created. (DriveWorks Administrator, DriveWorks User, DriveWorks Autopilot, DriveWorks Live.)

Model Generation Method

This plugin will only run when using Queued Model Generation (Manual or Automatic).

Please see Model Generation Behavior for information on Queued Model Generation.

DriveWorks Plugins running inside SOLIDWORKS
This plugin can either be used in DriveWorks Administrator (In which case it will run as part of the DriveWorks Addin inside SOLIDWORKS during model generation) or added in to DriveWorks Autopilot to run as part of the Autopilot function. If you wish to use this plugin from the DriveWorks addin inside SOLIDWORKS, then you will need to ensure that the plugin version is matched to the exact version of DriveWorks that you are using. To make sure that the versions are matched, right click on the file DriveWorks.Engine.dll that comes with the plug in, and check its version number against the version that appears on the splash screen when you launch DriveWorks.

Install\ Uninstall

The installation file is available from the DriveWorks User Community website at https://my.driveworks.co.uk/ (login required).

Once downloaded double click the DriveWorksLabsBillOfMaterialsToDatabase.msi file to begin the installation process. DriveWorks and SOLIDWORKS should be closed while installing the plugin.

Once installed the plugin is automatically loaded in DriveWorks.

The plugin is uninstalled from Windows Programs and Features, and will be listed as DriveWorks Bill of Materials Export (Database).

DriveWorks should be closed and restarted once the plugin has been uninstalled to remove it from the plugin list in the DriveWorks settings.


Once installed the plugin can be configured by:

  1. Launching DriveWorks Administrator
  2. Click the Settings button from the header bar
  3. Select plugin Settings from the list on the left of the Settings dialog
  4. Scroll to the plugins section at the bottom of the main window
  5. Select DriveWorks BoM Database plugin
  6. Click the Settings button

Browse to Settings File

A settings file must be loaded to use the plugin.

Click this button to either browse to an existing settings file or create a new one in the desired location by just typing a filename in to the browse window.

Once the plugin has been configured, this settings file can then be transferred to any other machine that wishes to use the plugin.

Edit Model List

The plugin needs to know the name of each assembly it is to run on.

To Add a model to the list

  1. Click Edit Model List to open the Add Models dialog
  2. Enter the name of each master assembly in the top field

    This is the Master Model Name of any captured DriveWorks model minus the extension, and is case sensitive.

  3. Click Add after each master assembly name that is added.

To remove a model that has been added to the list

  1. Select an item in the list view
  2. Click Delete to remove the model.


Data Types

Writing to a database field where the Data Type is set to BIGINT will cause the export to fail.

This allows the connection parameters to be configured

  1. Click the Configure Connection Parameters button
  2. From the Connect by field choose one of the following
    • System DSN - To connect to a database that has a System Data Source Name configured see How To: Setup a DSN-Access or How To: Setup a DSN-SQL Server for more information.
    • File Path - To connect directly to a Microsoft Access database (.mdb or .accdb) that has no additional security set up.

System DSN

  1. Select the DSN Name from the DSN Name drop down box
  2. Enter and Username and Password credentials required to connect to the database
  3. Click the Connect button to connect to the database
  4. Once connected select the Table Name the BOM is to be exported to from the Table Name drop down box
  5. Check each field data is to be exported into
  6. Click OK to close the Database Connection dialog

File Path

  1. Click the Browse button to locate and select the Access database
  2. Click the Connect button to connect to the database
  3. Once connected select the Table Name the BOM is to be exported to from the Table Name drop down box
  4. Check each field data is to be exported into
  5. Click OK to close the Database Connection dialog


The plugin allows for different options and BOM Templates to be configured for each master model that can be generated from the DriveWorks group.

Once a Model has been selected in the Project List drop down, the rest of the settings can be configured.

Check the box next to each option required for the selected model.

Include Sub Assemblies

When checked will include Sub Assembly information in the Bill of Materials.

Traverse Sub Assemblies

When checked will drill down into sub assemblies to include their parts on the Bill of Materials.


When checked will adhere to the SOLIDWORKS setting "Exclude from BOM".

Different Configurations in Different Rows

When checked will create new rows in the BOM for different configurations of the same parts.

Cut List Items on Different Rows

Parts must have a custom property called "DWExportCutList" set to a specific value. This value must then appear as the name of a cut list item specific property.

Log Events

When checked will add logging information onto the Logging Section in the Settings Dialog.

Ignore Control fields for cut lists

When checked will force non-unique inserts into new rows. Checking this option means that non-unique items will be added to new rows regardless of the control fields set. (Not recommended).

Quantity Custom Property

If entered the quantity value will be summed from this custom property if found in any model, rather than the item count.

Field Mapping

The fields selected when configuring the database are populated in the list view as shown.

To map database fields to values to be written into the database:

  1. Select the Database field from the Field Mapping table
  2. Click Edit, this will open the Edit Database Field Mapping dialog
  3. Select the SOLIDWORKS Input Value type from the drop down box

These fields can be mapped to properties and values in the SOLIDWORKS assembly. Select a field and hit edit to map the fields to a SOLIDWORKS Value. This could be any of the following:

  • Filename - The filename of the component
  • Qty – the total qty of instances of the component in the assembly the BOM plugin is running on
  • AssemblyType - The name of the component
  • Configuration - The configuration of the component
  • Custom Property – Any SOLIDWORKS custom property captured in DriveWorks. The name of the property is required (Case sensitive)
  • Top Level Custom Property – The value coming from the Top Level SOLIDWORKS Assembly custom property captured in DriveWorks. The name of the property is required (Case sensitive)

Control Fields

Check the box next to any field that will be a control field.

A control field dictates whether the entry will be written or not.

  • If the value being written into the control field is unique the record will be inserted.
  • If the value being written into the control field already exists the record will not be inserted.

Plugin Use

For each unique component in the assembly the plugin is running on, the plugin will create a record and insert it into the database. When the BOM plugin is running, a progress dialog will pop up allowing the user to see its current task.

Once the plugin has completed compiling all the data for the clone, it will send it to the destination database.