A couple of different ways that immediately come to mind:

1. Using your existing query:

<cfquery name="GetMasterID" datasource="master_data">
select masterID
form   MasterTable
where  SignUpDate = #SignUpDate#
</cfquery>

<cfloop query="GetMasterID">
    <cfquery datasource="master_data">
    DELETE FROM MasterTable
    WHERE masterID=#GetMasterID.masterID#
    </cfquery>
</cfloop>

- OR -

<cfquery datasource="master_data">
DELETE FROM MasterTable
WHERE masterID IN (#GetMasterID.masterID#)
</cfquery>

2. Simply passing the date via URL or Form:

<cfquery datasource="master_data">
DELETE FROM MasterTable
WHERE SignUpDate = #SignUpDate#
</cfquery>





----- Original Message -----
From: "aslam bajaria" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 20, 2000 4:54 PM
Subject: Help!


> I have come across a problem that has to be solved
> today.
>
> I have a query that gets the list of all the MasterIds
>
> under some conditions:
>
> <cfquery name="GetMasterID" datasource="master_data">
>     select masterID
>     form   MasterTable
>     where  SignUpDate = #SignUpDate#
> </cfquery>
>
> My goal is to delete all the masterids I get from this
> query. Can someone tell me how to do it?
>
> Appreciate.
> A.B.
>
>
>
>
> __________________________________________________
> Do You Yahoo!?
> Send instant messages with Yahoo! Messenger.
> http://im.yahoo.com/
> --------------------------------------------------------------------------
----
> Archives: http://www.eGroups.com/list/cf-talk
> To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.

------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to