Hi all,
hoping for some advice with querying a query - at least I think that's what's a 
good fit here but feel free to advise otherwise. 

I've got a folder which contains 35,000 folders. I've also got a table with 
lots of records, where the roomid column matches the name of one of the 
folders. 
I know some folders do not have a matching record, and I want to identify those 
records. 

<cfdirectory action="list" name="roomList" type="dir" directory="#roomsDir#">

<cfquery datasource="#dsn#" name="roomsDB">
        SELECT roomid from rooms
</cfquery>

I *think* I need to do something along these lines:

<cfquery name="orphanRooms" dbtype="query">
 select * from roomList  
 WHERE name ...
</cfquery> 

But somehow I cannot figure out the correct syntax. The resultset from 
orphanRooms should contain all the records that are in roomList but not in 
roomsDB.

Any help appreciated.

Stefan



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:341722
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to