11.16.15 Specification rules for a synonym list definition file
This subsection describes the specification rules for a synonym list definition file.
- Organization of this subsection
(1) Specification example of a synonym list definition file
In this example, the following two synonym groups are registered in a synonym dictionary. The following describes an example of specifying the synonym list definition file.
-
database,data bank,DB
-
application server,AP server
<Specification example of a synonym list definition file>
database,data bank,DB↓ application server,AP server↓
Legend: ↓: Line feed
- Explanation:
-
-
If you perform a search by specifying one of database, data bank, and DB as the search-target character string, all of database, data bank, and DB are searched for as synonyms.
-
If you perform a search by specifying one of application server and AP server as the search-target character string, all of application server, and AP server are searched for as synonyms.
-
(2) Specification rules for a synonym list definition file
-
Specify a synonym group per line.
-
Specify individual synonyms by delimiting with a comma (,).
-
Input a line feed at the end of each line (at the end of each synonym group). Also, input a line feed at the last line of the synonym list definition file. In the preceding example, you need to input a line feed after application server.
-
Use as the linefeed code one from X'0A' (LF), X'0D0A' (CRLF), or X'00'.
-
If there is a line on which no synonym is specified (a line that has only a line feed), execution of the adbsyndict command results in an error.
-
Create a synonym list definition file by using the character encoding specified for environment variable ADBLANG.
-
You can specify a character string consisting of 1 to 1,000 characters for a synonym.
-
You can specify 2 to 1,000 synonyms for a synonym group.
-
You can specify no more than 1,000,000 synonym groups.
-
You cannot register a synonym that contains a horizontal tab X'09' (HT), line feed character X'0A' (LF), or X'00'.
-
You can specify double quotation marks (") as enclosing characters. If a synonym contains ,, enclose the synonym by the enclosing characters.
-
Half-width spaces before and after the synonym character string are not deleted. For example, if "∆ab∆c∆d∆∆" is specified, "∆ab∆c∆d∆∆" is registered as a synonym. ∆ indicates a half-width space.
(3) Relationship between synonym list definition files and synonym dictionaries
Depending on the search conditions or contents of the search-target document data, you can create multiple synonym dictionaries and use them differently. When you create multiple synonym dictionaries, create a synonym list definition file per synonym dictionary.
For example, if you perform the following retrievals, create two synonym list definition files and two synonym dictionaries:
-
Retrieving sentence data that contains general terms for database
-
Retrieving sentence data by narrowing down the database type (for example, retrieving sentence data regarding relational database, or retrieving sentence data regarding NoSQL database)
- ■ Specification of the synonym list definition file (Terminology.txt) for the preceding item 1
-
database,data bank,DB,relational database,RDB,NoSQL database,No-SQL database,cloud database↓
Legend: ↓: Line feed
Create synonym dictionary Terminology by using this synonym list definition file. When retrieving sentence data that contains general terms for database, use synonym dictionary Terminology.
- ■ Specification of the synonym list definition file (Terminology_detail.txt) for the preceding item 2
-
relational database,RDB,relational data base↓ NoSQL database,No-SQL database,cloud database↓
Legend: ↓: Line feed
Create synonym dictionary Terminology_detail by using this synonym list definition file. When retrieving sentence data regarding relational database or sentence data regarding NoSQL database, use synonym dictionary Terminology_detail.