You can use the following Autodesk Navisworks tags with SQL queries:
Property of the currently selected object. Category is the name of the tab in the property windows (for example, Item or Entity Handle) and property is the name of the property in that tab (for example, Value or Layer).
Property of the currently selected object. This is the same as the previous tag except instead of using the publicly visible category and property name use the internal Autodesk Navisworks names. The benefit of using internal names is that they are not language dependent. This is advanced tag suitable for users familiar with the Autodesk Navisworks API.
This tag represents the full path and filename that the currently selected object comes from. Even when a collection of model files have been combined into a single NWD file this tag still remembers the path and filename of the original model file.
This tag represents the full path and filename of the currently loaded model. If you currently have an NWF or NWD loaded that contains many other models it will just return the path and filename of the top level NWF/NWD.
If the provided text includes a filename with an extension, this tag removes the extension.
If the provided text includes a path and filename, this tag remove the paths and just returns the filename.
If the provided text includes a path, this tag removes the top level. If it the text also includes a filename, it counts as the top level and is removed. For example, %poppath(“c:\temp”) becomes c:\ and %popath(c:\temp\readme.txt”) becomes c:\temp.
If text1 is a path and text2 is a file or folder name, then text2 is added onto the path in text1. For example, %pushpath(“c:\test”,”model.nwd”) becomes c:\test\model.nwd.
This tag simply joins the two pieces of text together. For example, %join(“c:\”,”model.nwd”) returns c:\model.nwd.
The examples below illustrate how tags could be used with SQL queries.
SELECT * FROM Test WHERE "Entity Handle" = %prop("Entity Handle","Value") AND “File Name” = $removeext(%removepath(%sourcepath));
Here the path and the extension of the file name are being stripped, so a file like c:\model\3rdFloorDucts.dwg would come out as 3rdFloorDucts.
SELECT Name,Part FROM Test WHERE "Entity Handle" = %prop("Entity Handle","Value");
SELECT * FROM Test WHERE Value BETWEEN %prop("Pressure","Minimum") AND %prop("Pressure","Maximum");