I am attempting to work with my first normalized database (everything else I have made was simple little PHP projects that I never had the need for it).
Basically I am trying to pull data from multiple tables that needs to match up. Right now I have 10 results per page and had no problem getting that to work. I have tried a few approaches to pull the second tables data and match it to the first query.
Basically the end result for this is to manage rental properties.
"properties" is the main table that handles most the information. It has about 50 rows so I am not sure you need all the rows, but if you do let me know.
The second table has floor plans. I named this table "floorplans". It has several rows:
PlanID
PropID - this is the same one from the properties table that they both share
PlanName
Size
Bedrooms
Bathrooms
Den
Price
PriceTo
Deposit
SqFt
UnitImg
I am attempting to build a cataloging system and display the results as a set on the page. I am listing 10 items per page with various sub info on that page as well. Most of this information is in the primary 'properties' table, but I would also like to be able to list items from the sub table that match the primary ID all on the same page. A detailed page containing all the information on the subject would be easier to do since I could just call the ID from the $_GET on two separate querrys but I am trying to make a page to give previews before clicking through.
Basically the table in html is aiming to look like:
<--All from Primary Table--><---In the floorplan table--->
+----+-----------------------------------------------------------------+
| Image| 1 ABC DEF St | Floorplan information | Price |
| | 44 Evergreen | aka how many |Info |
| | Something | rooms | |
+----+----------------------------------------------------------------+
Is there some way to accomplish displaying the data how I am trying? With a join can I do all 5 rows that share the same PropID? If so how would I call the multiple fields that would be associated. For example if I joined the tables and a PropId had 4 PlanId's associated is it even possible to call all 4 rows of data and if so how.
I appreciate all the help.