Previous Topic

Next Topic

Book Contents

Book Index

User-defined Keys

There are a number of places in AQT where you need to specify a unique key for your table/view. For instance:

In all these cases, AQT will try to automatically determine the unique keys for the table. It does this by:

If your table has neither a primary key nor a unique index, AQT will prompt you for the columns that comprise the unique key of the table. After you have selected these, AQT will then ask you whether you want AQT to remember this key. If so, AQT will create a user-defined key for the table/view.

AQT will use that key when you are using that table in the future; this saves having to specify the key columns every time.

User-defined keys are particularly useful if you are dealing views, since primary keys and unique indexes cannot be defined on views.

Other notes:

Editing your list of User-Defined Keys

To see the user-defined keys that have been defined for your database:

User-defined keys are held in file key<dbname>.txt (example keyAQTDemo.txt) in your Default Directory. The file name is given in the caption on the User-Defined Keys window.

You can manipulate these files are per normal files - edit, copy between machines etc.