
| | | |
| Applies To | | |
| | | |
| Product(s): | MicroStation, MicroStation GeoGraphics, MicroStation GeoOutlook | |
| Version(s): | All | |
| Environment: | N/A | |
| Area: | N/A | |
| Subarea: | N/A | |
| Original Author: | Bentley Technical Support Group | |
| | | |
Overview
This TechNote will explain how to eliminate the "Unable to load AE table" error when attempting to create an active entity in MicroStation when connected to a database. There can be various causes for this error when trying to build the Active Entity. Here are things to try that can help you resolve the error.
- The leading reason for this error is that you are using either an SQL Reserved Word as a column name or an invalid character in the column name. Column names cannot contain any of the following:
- SQL Reserved Words (they are used by the ANSI SQL language). A list of SQL Reserved Words can be obtained from your database documentation (for example, if you're using Microsoft Access, look up "reserved words" in the online help index).
- Spaces: For example Parcel Lot is invalid but Parcel_Lot is acceptable.
- Symbols: For example slashes, asterisks, etc. Parcel# is invalid but Parcel_Num is acceptable.
- Numbers: Any columns (or tablenames) beginning with a number are invalid. For example 2_date is invalid but Date_2 is acceptable.
- Another cause of the "Unable to load AE" error is using improper SQL syntax in the AE= or FI= statement. Both the AE= and FI= statement are typical SQL insert statements. The AE= statement will always be in the form of an insert statement, for example
insert into <table> (<column1, column2>) values (<value1, value2>)
. The FI= statement will always be a select statement, for example: select * from <tablename> where <column> = <value>
. If you are unsure of the syntax, test these statements in the SQL Window first (without the AE= or FI=) and see if they return data from the table. If they don't, then you most likely have an error with the statement that must be fixed. When you have corrected the error, try the AE= or FI= in the Key-in field. Examples of these statements are on page 13-13 in the MicroStation 95 Administrator's Guide.
- Database permissions may also cause problems creating the Active Entity table. In Microsoft Access, it is possible to assign certain workgroup privileges through a system.mda (or .mdw) file. If you are required to supply a login name and password when you enter Access, you have login privileges assigned to your account. If you want to use MicroStation with this database, you must add a step when setting up your ODBC data source. In the ODBC Setup dialog that contains your data source, go to the bottom where it says System Database. Turn on Database instead of None, and choose your system.mda file by clicking the System Database... button. Now when you connect through MicroStation, ODBC will prompt you with an additional dialog to enter your login name and password. In addition, make sure that there is no Read-Only attribute on the .mdb file itself.
- If you are using an Oracle database, make sure you have write privileges for MicroStation to create the AE table on the fly (a temporary table MicroStation creates to hold the active entity). If the Oracle user permissions do not allow new tables such as the AE table to be created, the "Unable to load AE" error will result. Also, when you create a new table in Oracle that you'd like to link, you must enter a starter "seed" row in the table first before performing AE or FI to avoid the "Unable to load AE" error.
- Make sure that your table has a MSLINK column and that the data type is Number. This is a required field for all tables containing data that will be linked to graphics.
- To further debug the "Unable to load AE" error, the Session Debug tool can be used. Disconnect and reconnect to the database to establish a fresh connection. In the MicroStation Key-in window, key in
session debug on
. This will open a text window on top of MicroStation. Then send your active entity statement again. Database server calls will appear in the Messages dialog. When this is finished scrolling, you can scroll back to the point where the FI= or AE= statement was first sent and look for an error message from the database driver. You may see an error such as "Improper SQL syntax" or "Datatype Mismatch"; you should be able to determine the cause of the problem from this message.
See Also
Product TechNotes and FAQs
Geospatial Product TechNotes And FAQs
External Links
Bentley Technical Support KnowledgeBase
Bentley LEARN Server
Comments or Corrections?
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!