I have a text file with about 65000 records to be looped and
inserted into a
database. I am using cfhttp to read the list and turn it into
a query. I am
then using that query to loop and insert the records into a
database.
However, its too large and the server is timing out. Is there
a break the
list into 2 pieces and do it in serial?
I am using:
<cffunction name="getResidential" access="private"
returntype="void"
output="false" hint="">
<cfargument name="ResFile" type="string"
required="yes">
<cfhttp timeout="6600"
url="
http://www.mywebsite.com/assets/property/#ResFile#"
method="GET"
name="Property" delimiter="|" textqualifier=""
firstrowasheaders="yes" />
<cfloop query="Property">
<cfquery name="loopProperty" datasource="bpopros">
INSERT STATEMENT HERE
</cfquery>
</cfloop>
</cffunction>
Is it possible to do something like:
Function 1
<cfloop from="1" to="40000" index="i">
</cfloop>
Function 2
<cfloop from="40001" to="#Query.RecordCount#"
index="i">
</cfloop>
Any ideas? Thanks
--
Wally Kolcz
MyNextPet.org
Founder / Developer
586.871.4126