Database Schema - CroissantAhhh/animevideo GitHub Wiki

Avatune Database Schema

Database Scheme

Users

* id
* username
* email
* hashedPassword

Tracks

* id
* fileURL: external link to the track file mp3
* name: title of the track
* userId: ID of the user who uploaded the track
* artist: name of the artist who composed/created the track
* albumId: ID of the album that the track belongs to
* mediumId: ID of the anime/video game that the track belongs to
* trackImageURL: external link to the track artwork

Albums

* id
* name: name of the album
* albumImageURL: external link to the album artwork
* artist: name of the artist who composed the album
* mediumId: ID of the anime/video game that the album belongs to

Media

* id
* name: name of the anime/video game
* bannerURL: external link to a representational image of the medium
* description: a text summary of the anime/video game
* infoLink: a link to more official information about the anime/video game (eg: myanimelist, Steam page, official website page. etc.)

Comments

* id
* body: text body of the comment
* userId: ID of the user who posted the comment
* trackId: ID of the track that the comment was posted under

Relationships:

One to Many:

  • One user can upload/post many tracks
  • One user can write/post many comments
  • One medium can have many albums
  • One medium can have many tracks
  • One album can have many tracks
  • One track can have many comments