-
mysql, arrays?
I was wondering if mysql had arrays. Because I want to work on a forum in mysql from scratch (lots of work I know) and need to think of a way to store topics/posts.
If mysql has arrays I was going to do a table for topics and an array inside the topics table for posts.
If mysql doesn't have arrays I was going to do a table for topics and a table for posts (very messy imo).
So does mysql have arrays?
-
Re: mysql, arrays?
you could do an array inside of each record, but that is not the way to do it for a forum.
you would want a table for threads, and a table for posts.
-
Re: mysql, arrays?
SQL databases are relational, not hierarchical. Anything that can stand as its own entity with its own properties — such as a topic or post — should have its own table.