Hello Joe,
Somewhat OT, but would you happen to have an example of how to put two
queries in a single cfquery for oracle?
/t
----------------------------------------------------------Here is an example of how to put 2 queries in a single cfquery for SQL Server.
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Joseph Flanigan
Sent: Monday, June 13, 2005 6:26 PM
To: [email protected]
Subject: RE: [CFCDev] Application Data Source Names
The tContact table has a primary key, ContactID, that is of type identity.
<cffunction name="Create" returntype="query">
<cfargument name="theParams" type="struct" default="#this#" required="yes" >
<cfargument name="DSN" type="string" default="#this.DSN#">
<cfset var qtContact_INS = "" >
<cfquery name="qtContact_INS" datasource="#Arguments.DSN#" maxrows=-1 >
BEGIN TRANSACTION
INSERT INTO dbo.tContact
(
[ContactTypesID],
[StatusID],
[TimeZoneID]
)
VALUES
(
<cfqueryparam value="#theParams.$ContactTypesID#" cfsqltype="CF_SQL_smallint" >,
<cfqueryparam value="#theParams.$StatusID#" cfsqltype="CF_SQL_smallint" >,
<cfqueryparam value="#theParams.$TimeZoneID#" cfsqltype="CF_SQL_smallint" >
)
SELECT [ContactID]
FROM dbo.tContact
WHERE ContactID = SCOPE_IDENTITY()
COMMIT TRAN
</cfquery>
<cfreturn qtContact_INS >
</cffunction>
(Reference: This code is exactly what CFSQLTool generates.)
Joseph-----------------------------------------------------------------------
http://www.switch-box.org/CFSQLTool/Download/
Switch_boxMediaFirm, Inc.
www.Switch-box.orgLoveland, CO USA
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).
CFCDev is supported by New Atlanta, makers of BlueDragon
http://www.newatlanta.com/products/bluedragon/index.cfm
An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).
CFCDev is supported by New Atlanta, makers of BlueDragon
http://www.newatlanta.com/products/bluedragon/index.cfm
An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
