DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

+ Reply to Thread
Results 1 to 2 of 2

Hybrid View

  1. #1
    Duane Guest

    Long time to search through Access database


    I have created an application using VB and Access. The database will have
    over 12,000 records to a max of 200,000 records. It seems to take forever
    to search for a given item, eg. make sure there is no duplications in the
    database. Is there anyway to speed up this process?

    I was told to use FoxPro, but I do not have FoxPro. Does the FoxPro provided
    with VB6 have the tools to compact and repair the database?

    please email me at dsnelling@msc.ca

  2. #2
    Aleksandr Guest

    Re: Long time to search through Access database


    "Duane" <dsnelling@msc.ca> wrote:
    >
    >I have created an application using VB and Access. The database will have
    >over 12,000 records to a max of 200,000 records. It seems to take forever
    >to search for a given item, eg. make sure there is no duplications in the
    >database. Is there anyway to speed up this process?
    >
    >I was told to use FoxPro, but I do not have FoxPro. Does the FoxPro provided
    >with VB6 have the tools to compact and repair the database?
    >
    >please email me at dsnelling@msc.ca


    The time used to find a particular record doesn't depends on the database
    exclusively, is your skill in programming too.
    If you use this

    Dim Rst as New ADODB.Recordset

    Rst.Open "SELECT Code, Name FROM Items WHERE Active = 1", Conn
    rst.Find "Code = '" & searchvalue & "'"

    it will take an eternity to complete, assuming you have 200,000 records.

    But if you do the following,

    Dim Rst as New ADODB.Recordset

    Rst.Open "SELECT Code, Name FROM Items WHERE Active = 1 AND Code = '" & searchvalue
    & "'", conn

    Then the record you want will be found in less than a second.

    The most important thing is you programming technics.

    Luck!

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


Top DevX Stories

Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL


Sponsored Links