by default, if you don't specify a QUERY attribute in the CFOUTPUT, and just
scope the variable with the query name, you'll get the first record.
if you wrap the second CFQUERY in a CFOUTPUT, you'll be good.
eg.
CFOUTPUT QUERY="Query1"
CFQUERY NAME="Query2" DATASOURCE="#Search#"
SELECT
Try this...
cfquery name="Query1" datasource="#Search#"
SELECT *
FROM SearchDetails, UserDetails
WHERE SearchDetails.name = UserDetails.name
AND SearchDetails.adress = UserDetails.address
AND SearchDetails.email = UserDetails.email
/cfquery
-Original Message-
From: Adam Smith
Adam,
If you want only the records that match from table 1 and table 2, try this:
CFQUERY NAME="yourquery" DATASOURCE="yourDSN"
SELECT *
FROMSearchDetails, UserDetails
WHERE SearchDetails.name = UserDetails.name AND
SearchDetails.address = UserDetails.address AND
Just a thought: I don't know the details of your database
application but from your description, I wonder whether you need to
have two tables. If the same fields are in both, perhaps you could
manage with one table and perhaps an additional field that makes
whatever distinction having them
30, 2000 2:50:54 PM GMT
Subject: Re: Query with a Query problem!
Just a thought: I don't know the details of your database
application but from your description, I wonder whether you need to
have two tables. If the same fields are in both, perhaps you could
manage with one table and perhaps
ot; [EMAIL PROTECTED]
To: "'[EMAIL PROTECTED]'" [EMAIL PROTECTED]
Sent: August 30, 2000 2:20:38 PM GMT
Subject: RE: Query with a Query problem!
by default, if you don't specify a QUERY attribute in the CFOUTPUT, and just
scope the variable with the query name, you'll get the first record.
if
I think what you want is something like so:
cfoutput query="yourquery" group="thegroupthatthethreerelateto"
cfoutput
#name#br
#address#br
#email#br
/cfoutput
/cfoutput
See if that works.
-d
Deanna Schneider
Interactive Media
7 matches
Mail list logo