Connecting Tech Pros Worldwide Help | Site Map

searching from more than one table

Newbie
 
Join Date: Oct 2007
Posts: 1
#1: Oct 11 '07
Please help. I am creating a site that needs to do a search based on postocode from the postcode table and then use it to use the solicitorsid's it receives and search the solicitors details table and the fees tables. I have the following code

[HTML] <cfquery name="getpostcode" datasource="conveyancingshoppers"> SELECT solicitorsid from postcodesselected where RM="RM"</cfquery><cfloop query="getpostcode"><cfquery name="getname" datasource="conveyancingshoppers">SELECT * FROM solicitors inner join fees on solicitors.solicitorsid = fees.solicitorsid AND solicitors.isonholiday <> 1 AND solicitors.Noofleadstoget <> solicitors.notofleadsreceived order by solicitors.timelastleadreceived asc </cfquery></cfloop>[/HTML]

It gives me the following error
ODBC Error Code = S1000 (General error)


[Microsoft][ODBC Microsoft Access Driver] Join expression not supported
.

I have tried a number of ways to try and fix this. Does anyone have any sugesstions on what is wrong or an alternative method of doing this.
acoder's Avatar
Site Moderator
 
Join Date: Nov 2006
Location: UK
Posts: 14,581
#2: Oct 14 '07

re: searching from more than one table


Welcome to TSDN!

You're not actually using the ids from the postcode table in your second query.

Can you show some sample data?
Newbie
 
Join Date: Dec 2007
Posts: 5
#3: Dec 18 '07

re: searching from more than one table


can post the database tables' schema??
Reply