Changes between Version 19 and Version 20 of RelationalDesign
- Timestamp:
- 08/24/26 15:43:19 (13 days ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
RelationalDesign
v19 v20 9 9 10 10 == Tables == 11 11 12 1. **USER** (**__{{{user_ID}}}__**, {{{username}}}, {{{email}}}, {{{user_name}}}, {{{surname}}}, {{{password}}}, {{{user_created_at}}}, {{{user_updated_at}}}) 12 13 13 2. **ADMIN** (**__{{{user_ID*}}}__** (USER) )14 2. **ADMIN** (**__{{{user_ID*}}}__** (USER), {{{assigned_at}}}) 14 15 15 3. **REGULAR_USER** (**__{{{user_ID*}}}__** (USER) )16 3. **REGULAR_USER** (**__{{{user_ID*}}}__** (USER), {{{joined_at}}}) 16 17 17 4. **WRITER** (**__{{{user_ID*}}}__** (USER) )18 4. **WRITER** (**__{{{user_ID*}}}__** (USER), {{{bio}}}) 18 19 19 5. **STORY** (**__{{{story_ID}}}__**,{{{title}}}, {{{mature_content}}}, {{{short_description}}}, {{{image}}}, {{{story_content}}}, **__{{{user_ID*}}}__** (WRITER), {{{story_created_at}}}, {{{story_updated_at}}}) 20 * status (multi-valued attribute, see table **STATUS**) 20 5. **STORY** (**__{{{story_ID}}}__**, {{{title}}}, {{{mature_content}}}, {{{short_description}}}, {{{image}}}, {{{story_content}}}, {{{status}}}, **__{{{user_ID*}}}__** (WRITER), {{{story_created_at}}}, {{{story_updated_at}}}) 21 21 22 6. ** STATUS** (**__{{{story_ID*}}}__** (STORY), **__{{{status}}}__**)22 6. **CHAPTER** (**__{{{chapter_ID}}}__**, {{{chapter_number}}}, {{{chapter_name}}}, {{{title}}}, {{{chapter_content}}}, {{{word_count}}}, {{{rating}}}, {{{published_at}}}, {{{view_count}}}, **__{{{story_ID*}}}__** (STORY), {{{chapter_created_at}}}, {{{chapter_updated_at}}}) 23 23 24 7. ** CHAPTER** (**__{{{chapter_ID}}}__**, {{{chapter_number}}}, {{{chapter_name}}}, {{{title}}}, {{{chapter_content}}}, {{{word_count}}}, {{{rating}}}, {{{published_at}}}, {{{view_count}}}, **__{{{story_ID*}}}__** (STORY), {{{chapter_created_at}}}, {{{chapter_updated_at}}})24 7. **GENRE** (**__{{{genre_ID}}}__**, {{{genre_name}}}) 25 25 26 8. ** GENRE** (**__{{{genre_ID}}}__**, {{{genre_name}}})26 8. **READING_LIST** (**__{{{list_ID}}}__**, {{{list_name}}}, {{{list_content}}}, {{{is_public}}}, **__{{{user_ID*}}}__** (USER), {{{list_created_at}}}, {{{list_updated_at}}}) 27 27 28 9. ** READING_LIST** (**__{{{list_ID}}}__**, {{{list_name}}}, {{{list_content}}}, {{{is_public}}}, **__{{{user_ID*}}}__** (USER), {{{list_created_at}}}, {{{list_updated_at}}})28 9. **NOTIFICATION** (**__{{{notification_ID}}}__**, {{{notification_content}}}, {{{content_type}}}, {{{is_read}}}, {{{link}}}, **__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{notification_created_at}}}) 29 29 30 10. **NOTIFICATION** (**__{{{notification_ID}}}__**, {{{notification_content}}}, {{{is_read}}},**__{{{recipient_user_ID*}}}__** (USER), {{{link}}},{{{notification_created_at}}}) 31 * content_type (multi-valued attribute, see table **CONTENT_TYPE**) 30 10. **AI_SUGGESTION** (**__{{{suggestion_ID}}}__**, {{{original_text}}}, {{{suggested_text}}}, {{{suggestion_type}}}, {{{accepted}}}, {{{suggestion_created_at}}}, {{{applied_at}}}, **__{{{story_ID*}}}__** (STORY)) 32 31 33 11. ** CONTENT_TYPE** (**__{{{notification_ID*}}}__** (NOTIFICATION), **__{{{content_type}}}__**)32 11. **LIKE** (**__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{liked_at}}}) 34 33 35 12. ** AI_SUGGESTION** (**__{{{suggestion_ID}}}__**, {{{original_text}}}, {{{suggested_text}}}, {{{accepted}}}, {{{suggestion_created_at}}}, {{{applied_at}}}, **__{{{story_ID*}}}__** (STORY))34 12. **COMMENT** (**__{{{comment_ID}}}__**, {{{comment_content}}}, **__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{comment_created_at}}}, {{{comment_updated_at}}}) 36 35 37 13. ** SUGGESTION_TYPE** (**__{{{suggestion_ID*}}}__** (AI_SUGGESTION), **__{{{suggestion_type}}}__**)36 13. **COLLABORATION** (**__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{role}}}, {{{permission_level}}}, {{{collab_created_at}}}) 38 37 39 14. ** LIKE** (**__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{like_created_at}}})38 14. **HAS_GENRE** (**__{{{story_ID*}}}__** (STORY), **__{{{genre_ID*}}}__** (GENRE)) 40 39 41 15. ** COMMENT** (**__{{{comment_ID}}}__**, {{{comment_content}}}, **__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{comment_created_at}}}, {{{comment_updated_at}}})40 15. **READING_LIST_ITEMS** (**__{{{list_ID*}}}__** (READING_LIST), **__{{{story_ID*}}}__** (STORY), {{{added_at}}}) 42 41 43 16. **COLLABORATION** (**__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), {{{collab_created_at}}}) 44 * role (multi-valued attribute, see table **ROLE**) 45 * permission_level (multi-valued attribute, see table **PERMISSION_LEVEL**) 46 47 17. **ROLE** (**__{{{user_ID*}}}__** (COLLABORATION), **__{{{story_ID*}}}__** (COLLABORATION), **__{{{role}}}__**) 48 49 18. **PERMISSION_LEVEL** (**__{{{user_ID*}}}__** (COLLABORATION), **__{{{story_ID*}}}__** (COLLABORATION), **__{{{permission_level}}}__**) 50 51 19. **HAS_GENRE** (**__{{{story_ID*}}}__** (STORY), **__{{{genre_ID*}}}__** (GENRE)) 52 53 20. **READING_LIST_ITEMS** (**__{{{list_ID*}}}__** (READING_LIST), **__{{{story_ID*}}}__** (STORY), {{{added_at}}}) 54 55 21. **NOTIFY** (**__{{{user_ID*}}}__** (USER), **__{{{story_ID*}}}__** (STORY), **__{{{notification_ID*}}}__** (NOTIFICATION)) 56 57 22. **NEED_APPROVAL** (**__{{{suggestion_ID*}}}__** (AI_SUGGESTION), **__{{{story_ID*}}}__** (STORY), **__{{{chapter_ID*}}}__** (CHAPTER)) 42 16. **NEED_APPROVAL** (**__{{{suggestion_ID*}}}__** (AI_SUGGESTION), **__{{{story_ID*}}}__** (STORY), **__{{{chapter_ID*}}}__** (CHAPTER)) 58 43 59 44 === DDL script for creation and deletion of tables ===
