Results 1 to 4 of 4

Thread: Ado

  1. #1
    Prakash Guest

    Default Ado

    I would like to know whether there is a limit on the size of the data, a recordset object can hold. I&#039ve been facing some problems with this. I have around 2000 records (300 kb). When i loop thru the recordset, at some point it&#039s failing and giving me weird errors. In each iteration i do a database update and add a couple of rows. Some of the error messages.... <BR><BR>1) Oracle Error occured, Unable to retrieve the oracle error message. <BR><BR>2) Operation is not allowed when the object is closed. <BR><BR>I can interprept the second error. But the biggest problem is, lack of consistency. once every 10 runs, the program goes fine. <BR>(That&#039s quite a low probability of success). <BR>Please advice me on this... <BR>Thanks in advance, <BR>Prakash <BR><BR>Ps: iam using the same data for each run..<BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Ado

    What does your Query look like? Also how many records are you looping through? You say 2000, 2000 out of what? What type of loop? Please show some code.<BR>Thanks

  3. #3
    Prakash Guest

    Default RE: Ado

    I mean after the query is executed, the recordset might contain any where between 1000 and 5000 records. <BR>The code looks like this.<BR><BR>While not rs.eof<BR> --Get each record<BR> --Do lot of business validation<BR> --Update a row in a table<BR> --Add 2 rows in 2 different tables<BR>wend<BR><BR>Since we were using com+(MTS), we were opening and closing connections each time we update or add a new row. So i changed my code to pass in the connection object as a parameter so that i can use the the same connection for the entire loop. But still the code rarely works. I know that there is no problem in my code, b&#039coz, the program works fine if i run it as a project group from a Vb executable in VB(calling the DLL in a project group). If i run it from the browser, it fails somewhere randomly. (Very rarely it succeeds. But why should it run 1 time and fail 9 times out of 10?. (i use the same data for each run).<BR><BR>Thanks,<BR>Prakash<BR> <BR>

  4. #4
    J Guest

    Default RE: Ado

    Is it timing out? Or are you getting an error? Consumes alot of resources doing these nested queries. I am not too firmiliar with com+(MTS). However I remember having the same problem before, except sometimes it would time out, sometimes it wouldnt run at all. What is your original SQL statement to get the RS?<BR>Try defining it more, make sure it is exactly what you need and not going through the whole DB. Try using an indexed field? Let me know what happens.<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts