Document Type: TechNote Product(s): MicroStation Version(s): V8 Original Author: Bentley Technical Support Group Legacy Document Number: 8255
Document Type: TechNote
Product(s): MicroStation
Version(s): V8
Original Author: Bentley Technical Support Group
Legacy Document Number: 8255
OLE DB is a new option for database connections. It is available under the database options of the MicroStation V8 installer in the 08.00.05.xx version or higher. OLE DB provides open data access and uses a standard set of COM interfaces for accessing and manipulating many different types of data.
These interfaces are commonly referred to as Data Providers. The choices you have in the Data Link Properties dialog, Microsoft Jet 4.0 OLE DB Provider or Oracle Provider for OLE DB, are the Data Providers that you have installed on your computer. You must contact your database vendor to determine if one is available for your database. Software like MicroStation that accesses data through OLE DB is called a Data Consumer. OLE DB interfaces can be developed to access very simple types of data as well as true relational databases. Therefore, OLE DB interfaces can access data that cannot be accessed using the current ODBC technology.
Before you can access data using OLE DB, you must set up a UDL, or MicroSoft Data Link, file. This is similar to setting up an ODBC data source in that you must provide some information about the data you wish to access. You must know the following:
A new database configuration file (..\Bentley\Program\MicroStation\config\database\oledb.cfg) has been added. In addition, a new database ID of 22528 has been added for database linkages created with an OLE DB connection. The MS_LINKTYPE value for OLE DB has been added to the oledb.cfg file.
#------ Database Linkages ------#MS_LINKTYPE = OLEDB
To create a UDL file
If the Microsoft Data Link option is not available on your operating system, select the Text Document option. Once the text document has been created, rename the extension to .udl. It will now be recognized as a Microsoft Data Link file.
You may right-click on the file and select rename to give the file a more appropriate name.
You must enter the pertinent information for your database. This will differ based on the Provider selected. For this example, browse to the location of the delivered MicroStation Access database called GIS.mdb located in the ..\Bentley\Program\MicroStation\database\oledb\examples\access directory. You may also use the Test Connection button to verify the parameters that you have entered.
For further information on creating a UDL connection, click here.
The UDL file will be created with this name and a UDL extension, in the directory defined by MS_UDLDIR. By default, this is set to ..\bentley\Program\MicroStation\database\oledb\udl.
Note: Do not open the UDL file with a text editor to make changes. The UDL file may become corrupt.
Following is a list of supported OLE DB providers:
While Microsoft also supplies an OLE DB provider for Oracle, we recommend the provider supplied by Oracle.
The following databases are supported with an OLE DB connection:
%B - Full Month Name %d - Day of the month %Y - Year including the century
See the Microsoft Run-Time Library Reference page for more information.
Product TechNotes and FAQs
MicroStation Desktop TechNotes and FAQs
Bentley Technical Support KnowledgeBase
Bentley LEARN Server
Bentley's Technical Support Group requests that you please confine any comments you have on this Wiki entry to this "Comments or Corrections?" section. THANK YOU!