CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2001
    Posts
    11

    Heavy MS-Access Database - Need Help urgently

    I am using VB as front end and MS Access as backend. When i am retrieving records from the database, its taking too long (30 - 40 seconds when there are some 8000 records). I came to know that the order by clause is causing it so much time. But order by is required ( a must ). So how can i go about with it. This is an urgent requirment. So, please someone help me. I would apreciate any kind of help from anyone.
    Thanking you all in advance.
    Mahesh


  2. #2
    Join Date
    Jan 2000
    Location
    Olen, Belgium
    Posts
    2,477

    Re: Heavy MS-Access Database - Need Help urgently

    What you can try to do is to create an index on the field that you are sorting on. This will cause the provider to search the field faster, thus sorting it faster.

    Tom Cannaerts
    [email protected]

    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning -- Rich Cook
    Tom Cannaerts
    email: [email protected]
    www.tom.be (dutch site)

  3. #3
    Join Date
    Oct 2001
    Posts
    11

    Re: Heavy MS-Access Database - Need Help urgently

    Thanks Tom for your reply. But i have already given index on the particular field and still the records are accessed very slowly. Can you or someone else please suggest some other options?

    Thanks,
    Mahesh


  4. #4
    Join Date
    Oct 2001
    Posts
    13

    Re: Heavy MS-Access Database - Need Help urgently

    HI,

    If you have a Where clause, make sure you have the right indexes on both tables. Also, try to change the order of the joined tables in the select clause or the order of the joins to a way in which the small tables will be joined first (sometimes, the provider doesn't do the best join process). Anyway, 8000 records are a lot of records and it consumes time even on faster databases like SQL-Server. If you're filling a grid or a combo, the drawing process also consumes a lot of time.

    Ben


  5. #5
    Join Date
    Jul 2001
    Location
    Mumbai,India
    Posts
    382

    Re: Heavy MS-Access Database - Need Help urgently

    Can you post the SQL Query?

    Regards,
    The Beret.


Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured