what i do is one big insert statement... as opposed to doing separate
inserts for each record.
This example inserts one record for each item in a list.... some idea tho.
<cfquery name="qAppendLotsOfRecords" datasource="blah">
INSERT INTO
table
(colA, columnB)
VALUES
<cfloop index="i" from="1"
to="#listlen(arguments.listOrderedQuestions)#">
(<cfqueryparam value="#somevariable#"
cfsqltype="CF_SQL_INTEGER">,
<cfqueryparam
value="#listgetat(arguments.listOrderedQuestions,i)#"
cfsqltype="CF_SQL_INTEGER">)
<cfif listlen(listOrderedQuestions) neq i>,</cfif>
</cfloop>
</cfquery>
This works in MySQL
HTH
Gav
On Wed, 19 Jan 2005 15:01:33 +1100, Scott Thornton
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> Is it possible to :
>
> Insert into a database table, using records selected from a query of
> query
>
> eg
>
> INSERT INTO A_REAL_DATABASE_TABLE
> (
> ..
> )
> SELECT
> ..
> FROM
> QUERY_OF_QUERY_RESULT
>
> ?
>
> ---
> You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
> To unsubscribe send a blank email to [EMAIL PROTECTED]
> Aussie Macromedia Developers: http://lists.daemon.com.au/
>
---
You are currently subscribed to cfaussie as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/