<?php mysql_select_db($database_BA, $BA); $query_GetPackages = "SELECT * FROM destpackage WHERE DestinationName = 'Lake Guri Resort' ORDER BY PackageName ASC"; $GetPackages = mysql_query($query_GetPackages, $BA) or die(mysql_error()); $row_GetPackages = mysql_fetch_assoc($GetPackages); $totalRows_GetPackages = mysql_num_rows($GetPackages); ?>
I have the above query on a page where I'm using records selected to populate two drop downs.
I'd also like to select other fields from this same query based on specific ID column values.
For example I'd like to output the Price field for a record in the above query where the ID field = 41.
I know I could create another query to do this but I need to do this 6 times for this page and don't want to create 6 times the server load by using 7 queries on the page.
I know this should be real simple but I can't seem to formulate a search phrase correctly to get the answer from a forum or web search.