Forum Moderators: coopster

Message Too Old, No Replies

PHP/SQL-how to run a recursive search through a table

how to run a number of search queries(variables) thru a table?

         

Lucas13

5:45 am on Jul 10, 2005 (gmt 0)



Hi guys, sorry I'm a bit new to this php/sql caper. I've got the basics under control, know how to connect to the database and retrieve recordsets off search queries using a?variable=whatever in the url and then print them back to show all the matching records on screen.
I have hit a snag, however.
Now, when the user clicks a link, I need to go into my sql table and search through one column for about 25 different strings to see if they match. Then i need to return the data for each match. Basically, I am running through an address database and want to list everything in a certain area, as defined by my list of post codes i have for each area (each area is about 25 post codes).
I've looked at arrays and strings and exploding and I'm really stuck and can't work out how to do this.
Any help would be greatly appreicated.
Regards, Lucas

jatar_k

3:36 pm on Jul 10, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld Lucas13,

do you take form input and then use that to base your search on?

Does this thread help?
Developing MySQL search query [webmasterworld.com]

if not then maybe a look at the form or the input you need to manipulate will help us better explain it for you.