Books have a secondary directory in the database how to store them.


  
  
  

  
  
  

how to store a catalog like this?
I want to have a book table (book table, book title, introduction, cover, etc.)
articleOne association table (book and article id association table, book id, first-level article catalogue id)
articleTwo association table (first-level article catalogue and second-level article catalog id, first-level article catalog id)
check articleOne table first. Find out the first-level article directory id, and then according to the first-level article directory id to check the articleTwo table, find out the second-level article directory id, and then find out the article title according to id to article. I hope the gods can advise
whether the mysql data inventory string is the same as storing numbers that occupy memory?

Mar.24,2021

directory just put a table on it
id name bookid acticleid pid
first-level directory pid is 0 second-level directory pid is first-level directory id

in addition, the size occupied by mysql field types
https://dev.mysql.com/doc/ref.
take a look at the document directly

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e9d6b8-1957.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e9d6b8-1957.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?