Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sort by relevance?

Status
Not open for further replies.

snowboardr

Programmer
Feb 22, 2002
1,401
PH
I am doing a nested loop using MySQL database, basicly I have

loop1
- city, state, city1, city2, city3, state1, state2, state3

loop2
- city, state

movenext loop2
movenext loop3


Lets say loop1 has a city= 'Riverside', state='CA'

on loop two I would like to show all matches to Riverside first or matches to the other cities first. Cities are more important than states but states do take a factor.

Right now its working but it throws the important matches in the middle of the 10 results, because CA is part of the display criteria.


Thanks in advanced.

Jason

Site San Diego www.sitesd.com

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top