Solved

Look in the list generated by a query

Posted on 2003-11-14
2
160 Views
Last Modified: 2013-12-24
hello experts

here is my situation:

i have a query

<cfquery name="getzip" datasource="woodmenzip">
        select Zipcode from ZipCode
        where State = '#state#' and Division = '#div#'
</cfquery>

that will give me a bunch of  zipcodes, say 100 of them. Working fine.

now i have another query:

<cfquery name="getmem" datasource="gchart">
select Member_FName, Member_LName, Member_Add1, Member_City, Member_State, Member_Zip, Member_Phone
from GC_Members
where Member_AgeRange = '#form.Member_AgeRange#' and
Member_Status = '#form.Member_Status#' and Flag = 1 or flag = 0 and Member_Zip = #QuotedValueList(getzip.ZipCode)#
ORDER BY Member_FName

In the above query, i want to display all the members who have a zipcode in the recordset that i get from earlier query. Note that these two reside in different DBs and i cant join the table. so what i was thinking was to store the query result in a list. Pls help.. i dont know if I have done a good job explaining.
0
Comment
Question by:adonis1976
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
jyokum earned 500 total points
ID: 9750933
you could join the two recordsets with a query of queries

<cfquery name="qryData" dbtype="query">
SELECT
    getmem.Member_FName,
    getmem.Member_LName,
    getmem.Member_Add1,
    getmem.Member_City,
    getmem.Member_State,
    getmem.Member_Zip,
    getmem.Member_Phone
FROM
    getmem, getzip
WHERE
    getmem.Member_Zip = getzip.Zipcode
</cfquery>
0
 
LVL 11

Author Comment

by:adonis1976
ID: 9751024
hey thanks a million..
0

Featured Post

Save the day with this special offer from ATEN!

Save 30% on the CV211 using promo code EXPERTS30 now through April 30th. The ATEN CV211 connects a laptop directly to any server allowing you instant access to perform data maintenance and local operations, for quick troubleshooting, updating, service and repair.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is a guide to setting up a new WHM/cPanel Server to be used for web hosting accounts. It is intended for web hosting company administrators and dedicated server owners. For under $99 per month (considering normal rate of Big Data Cetnters like …
Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

690 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question