Column Header Block Attributes
The Database Import function, which draws a database table on a drawing, inserts a column header block for each column that is imported. Each column header block contains the configuration made during importing so that the data can be refreshed without re-importing.
Column header blocks have the file name "IMPCOL*".
DATABASE | Visible |
Name of the database. This is relative to the drawing location (or a full path if not relative). This value should be identical for all column blocks of the table. |
COLUMN | Visible |
The data source that defines the contents of the cells in the column: This value is used only to specify the column from the database if the COLTITLE attribute exists and contains a value, in which case the value from the COLTITLE attribute is drawn above the column in the drawing.
If the COLTITLE attribute does not exist (or is blank), this attribute's contents will also be used for the title of the column (displayed above the column data in the header area title of the table). |
SORTWEIGHT | Visible |
Weighting of the sort for this column, if sorted. Lowest number has greatest weight. If the attribute is left blank then it will not add to any sorting. |
SORTDIR | Visible |
Direction of the sort, if sorted. Either ASCENDING or DESCENDING or leave empty. |
ROWSTART | Visible |
Number of the first record to be drawn. |
ROWEND | Visible |
Number of the last record to be drawn. |
ROWWIDTH | Visible |
Width of the column (in drawing units). |
ROWHEIGHT | Visible |
Height of the column (in drawing units). |
GUTTER_H | Visible |
Distance text is drawn from the left/right edge of the column. |
GUTTER_V | Visible |
Distance text is drawn from the top/bottom edge of the row. |
TEXTHEIGHT | Visible |
Height of the text to be drawn (in currently active style). Set this value to 0 if you want to prevent a column from being shown, thus allowing filtering or sorting without it being visible on the drawing. |
JUSTIFY | Visible |
Justification of the text: LEFT,RIGHT,CENTER,TL,TC,TR,ML,MC,MR,BL,BC,BR. |
BORDERCONF | Visible |
Configuration of the lines to be drawn around the data. (See description below) |
HEADERCONF | Visible |
Configuration of the lines to be drawn around the column heading. (See description below) You can also insert a symbol for the header. Each column may have a symbol inserted, or a single column could be used to insert a symbol to replace the whole table header. To use a symbol as a header, enter its file name (including .dwg extension) in this attribute. The path of the file will default to the RFIN folder in your installation. If this attribute contains NONE, then the column header will not be drawn at all. |
FILTER | Visible |
Filter to be applied to the data. This allows the fields of the records to be filtered by a pattern of your choosing. (See description below). |
TEXTSTYLE | Visible |
Specifies the text style to use to draw the text for the column titles and data values when refreshing the table contents. |
COLTITLE | Visible |
User-editable title shown for this column. In most cases this will be the same as the column name in the DBF file although it is set initially from the FieldDescriptors.dbf file. |
Line Configuration (BORDERCONF and HEADERCONF)
The BORDERCONF and HEADERCONF attributes control the lines that are drawn around each data item and header for each column. The attributes may contain items from the following list, comma separated.
LEFT | Draw a line to the left of the data of this column. |
RIGHT | Draw a line to the right of the data of this column. |
TOP | Draw a line above the data of each row. |
BOTTOM | Draw a line below the data of each row. |
FIRST TOP | Draw a line above the first row of data. |
LAST BOTTOM | Draw a line below the last row of data. |
Record Filtering (via FILTER attribute)
The FILTER attribute can be used in two distinct ways.
It can be set to "THISDWGONLY", which is a special value enabling the Elecdes 'The drawing's records only' filter. When used in this way the records of the database to be imported will only be included if TAG information (PNLNO, TAGNAME, TSTRIP etc) in that record matches TAG information used inside Elecdes blocks on the drawing the database is being imported into.
Any other value in the FILTER attribute will be used to pattern match against the data in the field of the database of the same name as that in the COLUMN attribute. Records will only be included if their data matches ALL of the filters that have been specified in the column header blocks for that database. In this way a database can be filtered by any number of fields.
The FILTER attribute of a single column header block can contain multiple filters for filtering the values of that one column. Separate filters by the ; semicolon character. You can use both "ThisDwgOnly" and other filter values in the same FILTER attribute.
Filters must conform to the Specmatch syntax.
'=' or '==' for "equal to"
'!=' or '<>' for "not equal to"
'<' for "less than"
'<=' for "less than or equal to"
'>' for "greater than'
'>=' for "greater than or equal to"
'*' will match any number of letters or digits
'?' will match any single letter or digit
'@' will match one or more letters
'#' will match one or more digits
For example, the FILTER attribute of the column header for the TAGNAME column may contain:
ThisDwgOnly;!="EARTH*"
This would show rows that matched the current drawing that did not have names starting with the value "EARTH".
Notes
-
The Database Import function loads the attributes of the column header blocks according to the choices made when importing a database table.
-
You may modify the attributes to change the content and the appearance of the imported data. Especially the sorting order and the column filtering may be useful to modify in many applications.
The easiest way to do this is to use the TEXTIMPEDIT command to modify an imported table.
-
A column that is included only for filtering but not to display its data can be made invisible by setting the TEXTHEIGHT attribute to 0.