-
Notifications
You must be signed in to change notification settings - Fork 0
Structure of database (en)
Our database consists of two constant tables: words
and tags
. First one is used to store all data connected with all types of words and translations in the whole dictionary. The second one lists all tag-names used to describe the content.
Moreover each ever tag used by editors generates it's own table (named after this tag) which stores ids of all words form words
table connected with the given tag. If at some moment of time no words are marked with certain tag, it's table is dropped form database.
##Content of words
record
Each row of words
is called a 'word'. Each word consists of several elements listed below:
-
base
- this row specifies meaning of the word in native (also called 'from language') language of given list of words. This field is mandatory. -
trans
- abbreviation of 'translation'. If this record is supposed to be a cross-language translation (eg. french-english word-list) here you should put the translation in foreign language (database uses utf-8 encoding, so don't worry about special characters). This field may be left empty. -
mono
- abbreviation of 'monolingual definition'. If this record is supposed to be a quiz or monolingual (eg. english-english) wordlist, you should put the definition ofbase
here. This field may be left empty.
Please notice, that at least one oftrans
andmono
fields has to be filled. You may also want to create word with both these filled for certain purposes. -
author
- name of author of this db record. Should be unique. This field is mandatory. -
level
- specifies difficulty level of this word and helps others recognise whenever it belongs to 'basic communication' or 'faith vocabulary' sections. Those are two main purposes of this database existence. See level specification page for more information. -
time
- date and time when this word was submitted to the database. Generated automatically. -
id
- generated automatically, unique identifier inwords
table. Used for precise identification the record.
To make content of the database more searchable, we introduced a system of tags. Each word in database should be marked with appropriate tags in order to be easily classified by other users. As mentioned before each tag has it's own table, so it may be assigned to multiple words and simultaneously - given word may have multiple tags. To get more information about how and why use several tags, see "How to deal with tags?" page.
Tag-table consists of three columns:
-
id
- generated automatically -
word_id
- value of theid
field of the word associated with this tag -
word_base
- value of thebase
field of the word associated with this tag. Allows you to easily get some idea on which word are we talking about, without querying the database by id.
tags
lists all currently available tags. Each row consists of:
-
id
- generated automatically -
tag_name
- name of table in db, where tag's data is stored. Uses only small letters and underscores. -
readable
- human-readable name for this tag -
flag
- flag given to this tag for maintenance purposes. Flags in use: 'from', 'to', 'hidden'. First two indicate base and translation's language. 'hidden' prevents the tag from displaying in web interface.