Looping through results from a Database Query
Posted: Thu Jan 16, 2003 8:01 am
Hi,
i have a database in which i have 3 tables
1 contact
2 website
3 emails
im trying to bring up information from all 3 that related. The thing is
table 3 mite have an array of related information i.e if i looked for related info on 'books' i get 1 reuslt from table 1, 2 results table 2 and 5 results from table 3
the thing is i used one query to search all three
"SELECT * from contact,website, email WHERE...."
my problem lies when trying to loop through the results in which the result of a table is more than one as i get repetition of the same information.
Now to overcome this i had to do 2 separate queries. in order to properly sort through the results but is there a way to do it without having to do 2 separate searches on the same issue??
Kendall
i have a database in which i have 3 tables
1 contact
2 website
3 emails
im trying to bring up information from all 3 that related. The thing is
table 3 mite have an array of related information i.e if i looked for related info on 'books' i get 1 reuslt from table 1, 2 results table 2 and 5 results from table 3
the thing is i used one query to search all three
"SELECT * from contact,website, email WHERE...."
my problem lies when trying to loop through the results in which the result of a table is more than one as i get repetition of the same information.
Now to overcome this i had to do 2 separate queries. in order to properly sort through the results but is there a way to do it without having to do 2 separate searches on the same issue??
Kendall