How to Structure Databases in Laravel

Database Normalization: 1/2/3 Normal Forms


Hi Povilas,

I have doubts on creating table schema. Fields are different based on Customer Income type

customer form inputs; name, age,email,mobile, income_type (salaried, self_employed, salaried_professional)

salaried: company_name, designation, salary, salary_credited_type, salary_credited_bank, payslip, form16, form16_yrs, company_location, present_work_exp, total_work_exp, official_email, office_landline, office_address, office_landmark

self_employed biz_name, biz_location, biz_constitution, about_biz, turn_over, itr_status, itr_filed_yrs, gst_no_status, gst_no, dor, gst_return_status, biz_type banks_self_employed (multiple) bank_name, ac_no, ac_type

salaried_professional net_cross_salary, pt_deduction, epf_deduction, form16, exp_yrs, salary_credit_type, income_proof, bank_statment_months, company_name, professional_degree, valid_membership, negative_profile

Thanks Thananjeyan


I think you should structure that exactly as you've listed above, with such tables:

  • customer_types
  • customers (wth customer_type_id)
  • incomes_salaried (with incomes_salaried.customer_id) - just not sure of the best table name
  • incomes_employed (with incomes_salaried.customer_id) - just not sure of the best table name
  • incomes_salaried_professional (with incomes_salaried_professional.customer_id) - just not sure of the best table name

But then it depends on what data you would present and what DB queries you would run in the future.


Okay Thank you.