Database Documentation

TCExam ERD database schema

Table: tce_sessions

Description:

Columns:

ColumnData typeAttributesDefaultDescription
cpsession_idVARCHAR(32)PRIMARY, Not null
cpsession_expiryDATETIMENot null
cpsession_dataTEXTNot null

Indices:

NameColumnsTypeDescription
PRIMARYcpsession_idPRIMARY

Table: tce_users

Description:

Columns:

ColumnData typeAttributesDefaultDescription
user_idBIGINTPRIMARY, Auto increments, Not null
user_nameVARCHAR(255)Not null, Unique
user_passwordVARCHAR(255)Not null
user_emailVARCHAR(255)NULL
user_regdateDATETIMENot null
user_ipVARCHAR(39)Not null
user_firstnameVARCHAR(255)NULL
user_lastnameVARCHAR(255)NULL
user_birthdateDATENULL
user_birthplaceVARCHAR(255)NULL
user_regnumberVARCHAR(255)UniqueNULL
user_ssnVARCHAR(255)UniqueNULL
user_levelSMALLINTNot null1
user_verifycodeVARCHAR(32)UniqueNULL
user_otpkeyVARCHAR(255)NULL

Indices:

NameColumnsTypeDescription
user_verifycodeUNIQUE
PRIMARYuser_idPRIMARY
ak_user_nameuser_nameUNIQUE
ak_user_regnumberuser_regnumberUNIQUE
ak_user_ssnuser_ssnUNIQUE

Table: tce_modules

Description:

Columns:

ColumnData typeAttributesDefaultDescription
module_idBIGINTPRIMARY, Auto increments, Not null
module_nameVARCHAR(255)Not null, Unique
module_enabledNot null'0'
module_user_idBIGINTNot null1foreign key to column user_id on table tce_users.

Indices:

NameColumnsTypeDescription
PRIMARYmodule_idPRIMARY
ak_module_namemodule_nameUNIQUE
p_module_user_idmodule_user_idINDEX

Table: tce_subjects

Description:

Columns:

ColumnData typeAttributesDefaultDescription
subject_idBIGINTPRIMARY, Auto increments, Not null
subject_module_idBIGINTNot null, Unique1foreign key to column module_id on table tce_modules.
subject_nameVARCHAR(255)Not null, Unique
subject_descriptionTEXTNULL
subject_enabledNot null'0'
subject_user_idBIGINTNot null1foreign key to column user_id on table tce_users.

Indices:

NameColumnsTypeDescription
PRIMARYsubject_idPRIMARY
ak_subject_namesubject_module_id, subject_nameUNIQUE
p_subject_user_idsubject_user_idINDEX

Table: tce_questions

Description:

Columns:

ColumnData typeAttributesDefaultDescription
question_idBIGINTPRIMARY, Auto increments, Not null
question_subject_idBIGINTNot nullforeign key to column subject_id on table tce_subjects.
question_descriptionTEXTNot null
question_explanationTEXTNULL
question_typeSMALLINTNot null1
question_difficultySMALLINTNot null1
question_enabledPRIMARY, Not null'0'
question_positionBIGINTNULL
question_timerSMALLINTNULL
question_fullscreenNot null'0'
question_inline_answersNot null'0'
question_auto_nextNot null'0'

Indices:

NameColumnsTypeDescription
PRIMARYquestion_id, question_enabledPRIMARY
p_question_subject_idquestion_subject_idINDEX

Table: tce_answers

Description:

Columns:

ColumnData typeAttributesDefaultDescription
answer_idBIGINTPRIMARY, Auto increments, Not null
answer_question_idBIGINTNot nullforeign key to column question_id on table tce_questions.
answer_descriptionTEXTNot null
answer_explanationTEXTNULL
answer_isrightNot null'0'
answer_enabledNot null'0'
answer_positionBIGINTNULL
answer_keyboard_keySMALLINTNULL

Indices:

NameColumnsTypeDescription
PRIMARYanswer_idPRIMARY
p_answer_question_idanswer_question_idINDEX

Table: tce_tests

Description:

Columns:

ColumnData typeAttributesDefaultDescription
test_idBIGINTPRIMARY, Auto increments, Not null
test_nameVARCHAR(255)Not null, Unique
test_descriptionTEXTNot null
test_begin_timeDATETIMENULL
test_end_timeDATETIMENULL
test_duration_timeSMALLINTNot null0
test_ip_rangeVARCHAR(255)Not null'*.*.*.*'
test_results_to_usersNot null'0'
test_report_to_usersNot null'0'
test_score_rightDECIMAL1
test_score_wrongDECIMAL0
test_score_unansweredDECIMAL0
test_max_scoreDECIMALNot null0
test_user_idBIGINTNot null1foreign key to column user_id on table tce_users.
test_score_thresholdDECIMAL0
test_random_questions_selectNot null'1'
test_random_questions_orderNot null'1'
test_questions_order_modeSMALLINTNot null0
test_random_answers_selectNot null'1'
test_random_answers_orderNot null'1'
test_answers_order_modeSMALLINTNot null0
test_comment_enabledNot null'1'
test_menu_enabledNot null'1'
test_noanswer_enabledNot null'1'
test_mcma_radioNot null'1'
test_repeatableTINYINTNot null0
test_mcma_partial_scoreNot null'1'
test_logout_on_timeoutNot null'0'
test_passwordVARCHAR(255)NULL

Indices:

NameColumnsTypeDescription
PRIMARYtest_idPRIMARY
ak_test_nametest_nameUNIQUE
p_test_user_idtest_user_idINDEX

Table: tce_test_subjects

Description:

Columns:

ColumnData typeAttributesDefaultDescription
subjset_tsubset_idBIGINTPRIMARY, Not nullforeign key to column tsubset_id on table tce_test_subject_set.
subjset_subject_idBIGINTPRIMARY, Not nullforeign key to column subject_id on table tce_subjects.

Indices:

NameColumnsTypeDescription
PRIMARYsubjset_tsubset_id, subjset_subject_idPRIMARY
p_subjset_subject_idsubjset_subject_idINDEX
p_subjset_tsubset_idsubjset_tsubset_idINDEX

Table: tce_tests_users

Description:

Columns:

ColumnData typeAttributesDefaultDescription
testuser_idBIGINTPRIMARY, Auto increments, Not null
testuser_test_idBIGINTNot null, Uniqueforeign key to column test_id on table tce_tests.
testuser_user_idBIGINTNot null, Uniqueforeign key to column user_id on table tce_users.
testuser_statusSMALLINTNot null, Unique0
testuser_creation_timeDATETIMENot null
testuser_commentTEXTNULL

Indices:

NameColumnsTypeDescription
PRIMARYtestuser_idPRIMARY
ak_testusertestuser_test_id, testuser_user_id, testuser_statusUNIQUE
p_testuser_user_idtestuser_user_idINDEX
p_testuser_test_idtestuser_test_idINDEX

Table: tce_tests_logs

Description:

Columns:

ColumnData typeAttributesDefaultDescription
testlog_idBIGINTPRIMARY, Auto increments, Not null
testlog_testuser_idBIGINTNot null, Uniqueforeign key to column testuser_id on table tce_tests_users.
testlog_user_ipVARCHAR(39)NULL
testlog_question_idBIGINTNot null, Uniqueforeign key to column question_id on table tce_questions.
testlog_answer_textTEXTNULL
testlog_scoreDECIMALNULL
testlog_creation_timeDATETIMENULL
testlog_display_timeDATETIMENULL
testlog_change_timeDATETIMENULL
testlog_reaction_timeBIGINTNot null0
testlog_orderSMALLINTNot null1
testlog_num_answersSMALLINTNot null0
testlog_commentTEXTNULL

Indices:

NameColumnsTypeDescription
PRIMARYtestlog_idPRIMARY
ak_testuser_questiontestlog_testuser_id, testlog_question_idUNIQUE
p_testlog_question_idtestlog_question_idINDEX
p_testlog_testuser_idtestlog_testuser_idINDEX

Table: tce_tests_logs_answers

Description:

Columns:

ColumnData typeAttributesDefaultDescription
logansw_testlog_idBIGINTPRIMARY, Not nullforeign key to column testlog_id on table tce_tests_logs.
logansw_answer_idBIGINTPRIMARY, Not nullforeign key to column answer_id on table tce_answers.
logansw_selectedSMALLINTNot null-1
logansw_orderSMALLINTNot null1
logansw_positionBIGINTNULL

Indices:

NameColumnsTypeDescription
PRIMARYlogansw_testlog_id, logansw_answer_idPRIMARY
p_logansw_answer_idlogansw_answer_idINDEX
p_logansw_testlog_idlogansw_testlog_idINDEX

Table: tce_user_groups

Description:

Columns:

ColumnData typeAttributesDefaultDescription
group_idBIGINTPRIMARY, Auto increments, Not null
group_nameVARCHAR(255)Not null, Unique

Indices:

NameColumnsTypeDescription
group_nameUNIQUE
PRIMARYgroup_idPRIMARY

Table: tce_usrgroups

Description:

Columns:

ColumnData typeAttributesDefaultDescription
usrgrp_user_idBIGINTPRIMARY, Not nullforeign key to column user_id on table tce_users.
usrgrp_group_idBIGINTPRIMARY, Not nullforeign key to column group_id on table tce_user_groups.

Indices:

NameColumnsTypeDescription
PRIMARYusrgrp_user_id, usrgrp_group_idPRIMARY
p_usrgrp_user_idusrgrp_user_idINDEX
p_usrgrp_group_idusrgrp_group_idINDEX

Table: tce_testgroups

Description:

Columns:

ColumnData typeAttributesDefaultDescription
tstgrp_test_idBIGINTPRIMARY, Not nullforeign key to column test_id on table tce_tests.
tstgrp_group_idBIGINTPRIMARY, Not nullforeign key to column group_id on table tce_user_groups.

Indices:

NameColumnsTypeDescription
PRIMARYtstgrp_test_id, tstgrp_group_idPRIMARY
p_tstgrp_test_idtstgrp_test_idINDEX
p_tstgrp_group_idtstgrp_group_idINDEX

Table: tce_test_subject_set

Description:

Columns:

ColumnData typeAttributesDefaultDescription
tsubset_idBIGINTPRIMARY, Auto increments, Not null
tsubset_test_idBIGINTNot nullforeign key to column test_id on table tce_tests.
tsubset_typeSMALLINTNot null1
tsubset_difficultySMALLINTNot null1
tsubset_quantitySMALLINTNot null1
tsubset_answersSMALLINTNot null0

Indices:

NameColumnsTypeDescription
PRIMARYtsubset_idPRIMARY
p_tsubset_test_idtsubset_test_idINDEX

Table: tce_testuser_stat

Description:

Columns:

ColumnData typeAttributesDefaultDescription
tus_idBIGINTPRIMARY, Auto increments, Not null
tus_dateDATETIMENot null

Indices:

NameColumnsTypeDescription
PRIMARYtus_idPRIMARY

Table: tce_sslcerts

Description:

store hash codes of SSL certificates

Columns:

ColumnData typeAttributesDefaultDescription
ssl_idBIGINTPRIMARY, Auto increments, Not null
ssl_nameVARCHAR(255)Not nullcertificate name
ssl_hashVARCHAR(32)Not nullhash of the string composed by concatenating some certificate data
ssl_end_dateDATETIMENot nullcertificate expiration date
ssl_user_idBIGINTNot null1

Indices:

NameColumnsTypeDescription
PRIMARYssl_idPRIMARY

Table: tce_testsslcerts

Description:

map the enabled certificated for tehe selected test

Columns:

ColumnData typeAttributesDefaultDescription
tstssl_test_idBIGINTPRIMARY, Not nullforeign key to column test_id on table tce_tests.
tstssl_ssl_idBIGINTPRIMARY, Not nullforeign key to column ssl_id on table tce_sslcerts.

Indices:

NameColumnsTypeDescription
PRIMARYtstssl_test_id, tstssl_ssl_idPRIMARY
fk_tce_testsslcerts_tce_sslcerts1_idxtstssl_ssl_idINDEX
fk_tce_testsslcerts_tce_tests1_idxtstssl_test_idINDEX
 

© 2004-2026 – Nicola Asuni - Tecnick.com - All rights reserved.
about - disclaimer - privacy