Re: [PHP-DB] storing and retrieving arrays in mysql

2002-01-30 Thread Corey Eiseman
Hi, thanks for the suggestions. Peter, I definitely think your second solution, the one you said you are probably going to upgrade to, is very clean: adding another table between categories and subcategories that defines relationships between the two. it seems like it will be much easier to code

Re: [PHP-DB] storing and retrieving arrays in mysql

2002-01-28 Thread olinux
I've done something similar by building a multidimensional array of categories and subcats in one query and then Loop thru this with a for each to build the category structure. Categories table looks like this CatID | ParentID | CategoryName Array is $category_menu[$ParentID][$CatID] I'm sure

RE: [PHP-DB] storing and retrieving arrays in mysql

2002-01-28 Thread Peter Adams \(IKN\)
I've been working on something like this since about September/October. It's not too hard, but it did take more coding than I thought it would. Now, there's a couple of ways you could do this. I chose the cheap (in terms of the number of DB tables) way out. The way I have it set up is this.