Ciao.

Periodicamente devo trasferire dei dati contenuti in una tbl access ad una identica tbl contenuta invece in mysql.

Lo script ASP mi va in errore:

codice:
Response object error 'ASP 0251 : 80004005' 
Response Buffer Limit Exceeded 
/s_conn.asp, line 0 
Execution of the ASP page caused the Response Buffer to exceed its configured l
I campi delle due tabelle sono indicizzati.

Presumo per la mole di dati contenuti nella tbl access più di un milione di record... lo script è questo, cosa posso fare?


codice:
   Set cn = Server.CreateObject("ADODB.Connection")
   cn.Open "DRIVER={MySQL ODBC 5.1 Driver};SERVER=localhost;PORT=3306;DATABASE=db_mysql;USER=root;PASSWORD=XXXXXX;OPTION=3;"   

   Set conn = Server.CreateObject("ADODB.Connection")
   OpenStr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\Inetpub\wwwroot\mdb-database\DB_ACCESS.mdb;Persist Security Info=False"
   conn.Open openStr

   SQL = " SELECT * FROM "
   SQL = SQL & " tbl_access "
   SQL = SQL & " WHERE "
   SQL = SQL & " ( "
   SQL = SQL & " EST LIKE '%DI%' "
   SQL = SQL & " OR "
   SQL = SQL & " EST LIKE '%DM%' "
   SQL = SQL & " OR "
   SQL = SQL & " EST LIKE '%DS%' "
   SQL = SQL & " ) "   
   response.write SQL & "
"
   Set objRs = Server.CreateObject("ADODB.Recordset")
   objRs.Open SQL, conn, 3, 3
   
   if not objRs.eof then    
   do while not objRS.eof
     
   query_select = "SELECT * FROM "
   query_select = query_select & " tbl_mysql "
   query_select = query_select & " WHERE "
   query_select = query_select & " COD = '" & objRs("Cod") & "' " 
   response.write query_select & "
"

   set Rs = Server.CreateObject("ADODB.Recordset")
   Rs.Open query_select, cn
   
   if Not Rs.eof then   
      response.write Rs("COD") & "
"    
   end if

   Rs.Close()
   Set Rs = Nothing   
   
   objRS.movenext()
   Loop

   end if

   objRs.Close()
   Set objRs = Nothing   

   conn.Close()
   Set conn = Nothing

   cn.Close()
   Set cn = Nothing