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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query of Queries problem

Status
Not open for further replies.

Biglop

IS-IT--Management
Aug 16, 2001
25
0
0
US
I'm trying a Q of Q for the first time and I must be doing something wrong. Can somebody enlighten me? I have two databases, both with email addresses. I want to come up with a list of addresses from DB1 that are not in DB2.

Here's what I tried:

<cfquery name=&quot;addresses_phx&quot;
datasource=&quot;email_phx&quot;
dbtype=&quot;ODBC&quot;>
SELECT first_name, email
FROM email_addresses
</cfquery>

<cfquery name=&quot;addresses_ibs&quot;
datasource=&quot;apps_copy&quot;
dbtype=&quot;ODBC&quot;>
SELECT Email
FROM IBS_apps
</cfquery>

<cfquery name=&quot;queryofqueries&quot;
dbType=&quot;query&quot;>
SELECT email
FROM addresses_phx, addresses_ibs
WHERE addresses_phx.email NOT IN addresses_ibs.email

</cfquery>

<cfoutput query=&quot;queryofqueries&quot;>
#addresses_phx.email#

</cfoutput>
 
Are you using CF Server 5.0? What is the error you are getting? - tleish
 
I don';t get an error message, it just hangs and eventually depletes server memory.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top