Alright I am still a little rusty at php/mysql. So this may not be the best method of achieving what I am trying so let me know what or how I should go about achieving this:
I am working on a small project for a storage unit list. In my database I have the following:
Unit id | Area | Row | Unit | Status |
| 1-9 | 1 - 200 | 1-20 | Empty / Renter |
Unit Id is made of sector.section.unit
Now what I would like to do is display a list of the 20 unites from each sector and section on a page.
1. 1.300.1 - Empty
2. 1.300.2 - John Doe - $75 Monthly - 10x10
...
19. 1.300.19 - Jane Evens - $40 Bi-Monthly - 10x10
20. 1.300.20 - Empty
What I am thinking is after grabbing all mysql data that is in area 1, and in row 300 convert the data to a php assosiative array by it's unit id. Then simply do a for() statement for the 20 units of a row. Displaying the array data if any follows it. How can I go about doing this?
Or should I just go ahead and just have every single unit in the database as empty till otherwise filled?
Thank you in advanced,