CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2007

    DataAdapter.Fill(Dataset) is slow


    I am using ASP.NET 2.0 + C#, we need to retreive the data from DB2 database located in US. We are using ODBC driver to connect to the db2.

    As there was problem with the query we are going for dataview in our code using a single query to retreive all the data from the table. But to fill the dataset with 3000 rows its taking around 10 seconds.We need to display the required data in a gridview.

    I used the following piece of code

    OdbcCommand ocmdDPSR = new OdbcCommand(query, oconnDPSR);

    OdbcDataAdapter odpDPSR = new OdbcDataAdapter(ocmdDPSR);



    Can anyone suggest me how to reduce this time of filling so that the report can be generated within 5 seconds.

    Thanks in advance

  2. #2
    Join Date
    Jan 2006
    Fox Lake, IL

    Re: DataAdapter.Fill(Dataset) is slow

    What is the actual Query? Maybe it can return less records? Users rarely like to scroll thru 3000 records.

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

Posting Permissions

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

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.