Project

General

Profile

Customer Database » History » Revision 2

Revision 1 (Ryan Supawarapong, 03/13/2026 02:23 AM) → Revision 2/9 (Ryan Supawarapong, 03/16/2026 01:45 PM)

# Customer Database 


 ``` 
 Table verification { 
   id uuid 
   email_id int 
   mobile_id int 
   appman_id int 
   cdd_id int 
   step int 
 } 

 Table mobile { 
   id int 
   value string 
 } 

 Table email { 
   id int 
   value string 
 } 

 Table cdd { 
   id int 
   face_compare_pass bool 
   mule string 
   freeze_04 string 
   freeze_05 string 
   pep bool 
   pep_message string 
   dopa bool 
 } 

 Ref: mobile.id - verification.mobile_id 
 Ref: email.id - verification.email_id 
 Ref: appman.id - verification.appman_id 
 Ref: cdd.id - verification.cdd_id 


 Table appman { 
   id int 
   verification string 
   attribute_id int 
 } 

 Table appman_attribute { 
   id int 
 } 

 Ref: appman_attribute.id - appman.attribute_id 

 Table identity { 
   id uuid 
   customer_code int 
   fullname_id int 
   current_address_id int 
   register_address_id int 
   work_address_id int 
   suite_test_id int 
   occupation_id int 
   education_id int 
   workplace_id int 
   income_id int 
   customer_type int 
 } 

 Table fullname { 
   id int 
   th_first_name string 
   th_middle_name string 
   th_last_name string 
   en_first_name string 
   en_middle_name string 
   en_last_name string 
 } 

 Table occupation { 
   id int 
   education_id int 
   occupation_id int 
 } 

 Table address { 
   id int 
   house_number string 
   floor string 
   village_building string 
   sub_street strign 
   street strign 
   country_code string 
   location_id    int 
 } 


 Table location { 
   id int 
   code int 
   zipcode string 
 } 


 

 Ref: location.id < address.location_id 

 Ref: fullname.id - identity.fullname_id 
 Ref: address.id - identity.current_address_id  
 Ref: address.id - identity.register_address_id 
 Ref: address.id - identity.work_address_id 
 Ref: suitetest.id - identity.suite_test_id 
 Ref: education.id - identity.education_id 
 Ref: occupation.id - identity.occupation_id 
 Ref: workplace.id - identity.workplace_id 
 Ref: income.id - identity.income_id 

 


 Table suitetest { 
   id int 
 } 

 Table suitetest_question { 
   id int 
   value string 
 } 

 Table suitetest_answer { 
   id int 
   suitetest_id int [ref: > suitetest.id] 
   question_id int [ref: > suitetest_question.id] 
   value stirng 
 } 


 Table occupation { 
   id int 
   code answer string 
   value string 
 } 

 Table education suitetest_question { 
   id int 
   code string 
   value string 
 } 

 Table income { 
   id int 
   code string 
   range string 
 } 

 Table workplace { 
   id int 
   position string 
   name string 
 } 

 // ---------------------- 

 Table verification { 
   id uuid 
   email_id int 
   mobile_id int 
   appman_id int 
   cdd_id int 
   step int 
 } 

 Table mobile { 
   id int 
   value string 
 } 

 Table email { 
   id int 
   value string 
 } 

 Table cdd { 
   id int 
   face_compare_pass bool 
   mule string 
   freeze_04 string 
   freeze_05 string 
   pep bool 
   pep_message string 
   dopa bool 
 } 

 Ref: mobile.id suitetest_question.id - verification.mobile_id 
 Ref: email.id - verification.email_id 
 Ref: appman.id - verification.appman_id 
 Ref: cdd.id - verification.cdd_id 

 suitetest.question_id 


 ```