Understanding database worksheets

connectCAD makes a lot of use of Vectorworks worksheets for reporting so it’s useful to review some the concepts. Here we’ll use the Rack Equipment Report from the standard template.

Locate the worksheet in the Resource Browser

Locate_the_worksheet_in_the_Resource_Browser.png

Right-click on it and select Open so we can edit the worksheet.

Show Database Headers

Show_Database_Headers.png

That in the worksheet’s View menu.

Inspect the database row criteria

Inspect_the_database_row_criteria.png

Right-click the row number and pick Edit Criteria from the pop-up menu

media_1461890226254.png

So this database row will list all EquipItem objects. i.e. a dtabase sub-row will be created for each object that has an EquipItem record attached. Now let’s see how we display their characterisitics.

Listing equipment names

Listing_equipment_names.png

If we click on cell A2 we can see its contents ” =(‘EquipItem’.’name’) “. What that means is that the sub-rows show the values of the ‘name’ field in the ‘EquipItem’ record attached to each listed object.

So now armed with this knowledge you can go and add extra columns to show other parameter values. Give it a try.

The next level

The_next_level.png

If you are looking to display values that come from other objects referenced by the object in the list, then you will need to use Python script. For database experts that’s called a JOIN and unfortunately the VW database can’t do that (yet). But we have an example for you in the All Layers Cable Report.

in the Length column we enter a value calculated by a Python script ‘WScCADGetCableLength.py’. It’s a file located in the Plug-ins/connectCAD folder. You’ll find some useful functions in there for intereacting with connectCAD objects. Try stuff and by all means contact us if you have questions.

Leave a Reply