Structure of category_pages and page_categories tables

21 views
Skip to first unread message

Martin Min

unread,
Mar 28, 2016, 1:53:23 PM3/28/16
to jwpl-users
Hi, I am a little confused by the schema of these two tables, as shown here:

MariaDB [Wikipedia]> describe category_pages;                                                                                                                                                                                   
+-------+------------+------+-----+---------+-------+                                                                                                                                                                                        
| Field | Type       | Null | Key | Default | Extra |                                                                                                                                                                                        
+-------+------------+------+-----+---------+-------+                                                                                                                                                                                        
| id    | bigint(20) | NO   | MUL | NULL    |       |                                                                                                                                                                                        
| pages | int(11)    | YES  |     | NULL    |       |                                                                                                                                                                                        
+-------+------------+------+-----+---------+-------+                                                                                                                                                                                        
2 rows in set (0.95 sec)                                                                                                                                                                                                                     

This should be actually category_id ('id') and page_id ("pages"). Right? 
                                                                                                                                                                                                                                             
MariaDB [Wikipedia]> describe page_categories;
+-------+------------+------+-----+---------+-------+
| Field | Type       | Null | Key | Default | Extra |
+-------+------------+------+-----+---------+-------+
| id    | bigint(20) | NO   | MUL | NULL    |       |
| pages | int(11)    | YES  |     | NULL    |       |
+-------+------------+------+-----+---------+-------+
2 rows in set (0.01 sec)

This should be actually page_id ('id') and category_id ("pages"). Right?

In both tables, it uses the field name "id" and "pages" though. I hope this is only a naming issue.

Torsten Zesch

unread,
Apr 5, 2016, 8:49:34 AM4/5/16
to jw...@googlegroups.com
The database design is somewhat different from the actual object structure.
So your question is hard to answer without knowing why you think this is a problem.

-Torsten

--
You received this message because you are subscribed to the Google Groups "jwpl-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jwpl+uns...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages