This article provides a brief overview of EC Schema technology in MicroStation CONNECT.
EC Schemas were introduced with MicroStation V8i and their use is enlarged in MicroStation CONNECT. EC Schemas are meta data that define data types, analogous to a relational database schema. EC Schemas are not graphic elements; rather, they represent a MicroStation capability for storing structured alpha-numeric data. Bentley Systems terminology for data stored in Item Types include 'business data' and 'EC Schema data'.
EC Schemas are the foundation of Item Types.
The MicroStation ECX
command lets you
export a schema, or other information.
Q To define an Item Type Library implicitly defines an EC Schema?
Yes.
Q Is the schema that it defines a first-class schema, equivalent to a schema defined any other way?
Yes, to workflows which operate on EC Schemas, Item Type Libraries look like any other EC Schema. e.g., Reporting, Explorer, etc.
Q That is, do we lose any capability by creating an Item Type Library?
You lose some capabilities and gain others.
An Item Type Library supports a subset of the features supported by hand-rolled EC Schemas, for two reasons:
At the time of writing with respect to MicroStation CONNECT Update 6, some EC features are not supported by Item Types …
Some capabilities are only available for Item Types …
Neither of the above is a comprehensive list.
Q To define an Item Type Library implicitly defines an EC Schema?
It can be discovered easily:
- Create a new empty file.
- Use
ecx schema list
key-in to list all schemas stored in the file.- Create your Item Type definition and save it to the file.
- Use the key-in again to check how the number of stored schemas changed.
- You will see some standard (supplement) schemas area added and also
DgnCustomItemTypes_<name>.01.00
schema is created.
For further research you can export the schema and open it in Bentley Class Editor.
There a number of MicroStation key-in commands that enable export of an ECSchema or a sub-set of a schema …
ECX SCHEMA EXPORT schema-name
ECX SCHEMA IMPORT schema-name ! Use with caution !
ECX SCHEMA LIST
ECX SCHEMA UPDATE
ECX ITEMS COUNT
ECX ITEMS DUMP
Those ECX commands have some options …
TEMP
folder
with a unique name derived from the Active Design File Name.
About the time that MicroStation CONNECT Update 5 was released, Bentley Systems announced the first CONNECT ECSchema Editor 1.0. The title editor belies the fact that is a read-only viewing tool. Perhaps later versions will enable editing.
None the less, it provides a useful way to view the structure of a schema. Moreover, its help documentation provides a valuable insight into the raison d'être of ECSchemas and their use in products from Bentley Systems.
Bentley Systems developer Paul Connelly commented about Class Editor V8 …
Don't edit an Item Type Library schema in Class Editor V8!
Veteran independent MicroStation developer Jan Slegr commented …
I am not sure if there is "Bentley Class Editor CONNECT Edition" available. Checking my computer with CONNECT Edition SDK installed I can found Class Editor 8.1, which I guess was installed together with Navigator or V8i SDK (not sure ;-)
It would be nice if Class Editor will be enhanced. If I need to create some schema (which is not very often), I am quite happy with the current version, but:
From time to time it crashes or starts work in a strange way. Restart the app is quick but annoying. Very limited documentation about e.g. available Property Attributes ro more advanced concepts like relationship classes etc. This is not primarily Editor issue, but it limits its usage.
Jan further added My personal list …
Based on stable powerfull EC Framework technology. Maybe it's an "internal thing", but EC data is common and used by many Bentley products and it's stored as XAttributes, so it's fully supported and compatible with DGN V8, i-model and Bentley world in general. Not as tags, that were implemented "on top of DGN V7" with many limitations Fully compatible with i-Model, so nothing is lost when exported e.g. to Navigator and used on Android or iPad (including ability to search Can be attached not to elements only, but also to design while, to particular model and also to references and attached rasters Easy to search in Explorer for Item Types including standard table display format (including ability to export the results to CSV or Excel) Possibility to create (and store) complex queries Item Types can be used as an input to other tools (reports, charts etc) Standard storage format allows to access data easily by other applications
I am indebted to Bentley Systems staff member Paul Connelly and to Be Communities MVP Jan Slegr. Both have contributed both factual information about Item Types and EC Schemas as well as their interpretation of how they can be used. They contribute enthusiastically to the MicroStation Programming Forum.