Application of MYSQL Views With GORM

Vikas Avnish
Jul 9, 2023

--

I am working on dashboard development which involves a complex join. Creating a complex join in database and Expose it to API is problematic.

Source of Problem:

  1. With Change in Requirement, You need to change the sql. Writing long sql chain with join is troublesome.
  2. Testing SQL in sql console require sql commands to be shared .
  3. Preview and Migration

The Process Simplified with SQL views. With Views, We can visualize a table. Some other benefits

  1. Abstract all joins as a simple table output
  2. Column rename
  3. Data type conversion
  4. Conditional logic application
  5. Select and Filter as normal table

Rest Simulated Application Will be update Here.

View layer is programming language independent and more robust . Try using it and get an better output, ease of development

--

--

No responses yet