gadjodilo77
Programmer
If you see the following thread:
You see at the bottom the results. They are being showed in a loop:
<cfoutput>#myString# / #typenumber# / #codenumber#</cfoutput><br>
How can I insert these loop results into another database table? row by row?
Like this:
auto_id column1 column2 column3
1 value1(myString) value1(typenumber) value1(codenr
2 value2(mystring) value2(typenumber) value2(codenr)
etc....
I tried something like this:
<CFQUERY NAME="update" DATASOURCE="rug">
INSERT INTO dev
(
<CFLOOP query="q">
dev_volgnr <CFIF #currentrow# NEQ #q.recordcount#>,</cfif>
</cfloop>
)
VALUES
(
<CFLOOP query="q">
'#myString#' <CFIF #currentrow# NEQ #q.recordcount#>,</cfif>
</cfloop>
)
</CFQUERY>
But that doesn't work!!
Is there a solution?
Gr, Kabbi
You see at the bottom the results. They are being showed in a loop:
<cfoutput>#myString# / #typenumber# / #codenumber#</cfoutput><br>
How can I insert these loop results into another database table? row by row?
Like this:
auto_id column1 column2 column3
1 value1(myString) value1(typenumber) value1(codenr
2 value2(mystring) value2(typenumber) value2(codenr)
etc....
I tried something like this:
<CFQUERY NAME="update" DATASOURCE="rug">
INSERT INTO dev
(
<CFLOOP query="q">
dev_volgnr <CFIF #currentrow# NEQ #q.recordcount#>,</cfif>
</cfloop>
)
VALUES
(
<CFLOOP query="q">
'#myString#' <CFIF #currentrow# NEQ #q.recordcount#>,</cfif>
</cfloop>
)
</CFQUERY>
But that doesn't work!!
Is there a solution?
Gr, Kabbi