Skip to content

Instantly share code, notes, and snippets.

@petrosagg
Created October 7, 2017 21:16
Show Gist options
  • Select an option

  • Save petrosagg/b5c35b50737f18eb362c5f6100929209 to your computer and use it in GitHub Desktop.

Select an option

Save petrosagg/b5c35b50737f18eb362c5f6100929209 to your computer and use it in GitHub Desktop.
Harmonise.it schema
# Schema V1 #
user(id, name)
--------------
1, petros
2, eva
themes(id, difficulty, description, theme_data)
--------------
1, hard, { stave: ... }
2, super hard, foobaz
theme_solution(user_id, theme_id, solution_data)
--------------------------
1,2, { ...... }
2,1, { ... }
2,2, {..}
# Schema V2 #
user(id, name)
--------------
1, petros
2, eva
3, bob
teacher_teaches_student(teacher_id, student_id, approved)
---------------------------
2, 1, false
themes(id, user_id, is_public, difficulty, description, theme_data)
--------------
1, NULL, true, hard, {}
2, NULL, true, super hard, {}
3, 2, false, super duper hard, {}
theme_solution(user_id, theme_id, solution_data)
--------------------------
1,2, {}
2,1, {}
2,2, {}
1,3, {}
@esarafianou

esarafianou commented Oct 14, 2017

Copy link
Copy Markdown

Schema V1: themes table require an extra column called given_voice defining weather the given voice is soprano or bass

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment