Add client to terms that do not have it

You can use SQL commands in Déjà Vu X3 to add a client attribute to terms that don't have one, in a Termbase.

Client numbers

The SQL commands shown in this article can be used to add a Client to any term in the Termbase that does not already have one.

Déjà Vu X3 does not store the name of a client in a Termbase; instead, it stores the client's code number. When you open a Termbase in Déjà Vu X3, it looks this number up to find the name of the client, and then displays the name. Therefore, when you modify a Termbase using SQL, you must use the client's code number in the commands you use, rather than the client's name.

How to find a client's number

You can see the list of clients that Déjà Vu X3 uses by accessing to menu option File>Options, and the selecting the Clients tab:

There you can see the list of clients that Déjà Vu X3 uses, showing their names and the client number for reach. Find the client you want to add, and take note of its number.

The Client attribute

If you are adding a client to terms in a termbase that does not have any client information at all, it is likely that the Termbase does not a definition for the Client attribute. If the Termbase does not have the Client attribute defined, you will not be able to add client information for individual terms effectively.

Therefore, you must check that the Termbase you are working with has the Client attribute defined, and add the definition yourself if it is not there. To do so:

  1. Open the Termbase in Déjà Vu X3.
  2. In the Home section of the Ribbon, click Properties.
  3. The Termbase Properties dialog appears. Select the Attributes tab.
  4. Here you can see if the Client attribute is defined. The image above shows a properly defined Client attribute. If you find that, you can close the Termbase Properties dialog.
  5. If the Client attribute is not defined, you can add a new attribute, using the same definitions shown in the image above. To learn how to add a new attribute to a termbase, read this article.

The SQL commands

How to run SQL commands on a Termbase

To see how to use the SQL commands to make changes in a Termbase, read this article.

The SQL commands

Type and run the following statements, one at a time, into the Execute SQL dialog:

INSERT INTO Attributes (LemmaID) SELECT ID FROM Lemmas WHERE ID NOT IN (SELECT LemmaID FROM Attributes WHERE AttrTypeID IN (SELECT ID FROM AttrTypes WHERE Token = 'client'));
UPDATE Attributes, AttrTypes SET Attributes.AttrTypeID = AttrTypes.ID WHERE AttrTypeID = 0 AND Token = "client";
UPDATE Attributes SET TextValue = 'CodeOfNewClient' WHERE TextValue = '' AND AttrTypeID IN (SELECT ID FROM AttrTypes WHERE Token = 'client');

Be aware that:

  • The 'CodeOfNewClient' should be the client number of the client you wish to add.
  • The apostrophes (') have to be vertical, rather than the curly ones that Word and other word processors use; otherwise you may get a syntax error.
Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request


Powered by Zendesk