1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

very slow query on access databse over Lan dir

Discussion in 'MS Access' started by LUCA90, Apr 11, 2014.

  1. LUCA90

    LUCA90 New Member

    Joined:
    Mar 3, 2009
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    0
    I use the tipical ado jet ole 4.0 connection and VB6 classic. for example:

    Set CONN = New ADODB.Connection
    With CONN
    .Open _
    "Provider=Microsoft.Jet.OLEDB.4.0;" & _
    "Data Source=C:\DATABASE\QA1.mdb;" & _
    "Jet OLEDB:Engine Type=4;"
    .Properties("Jet OLEDB:Max Locks Per File") = 25000000
    End With

    and i open the recordset with:

    Set RSTX = New ADODB.Recordset
    RSTX.CursorLocation = adUseClient
    SQL = "SELECT ecc where ecc"
    RSTX.Open SQL, CNT, adOpenStatic, adLockReadOnly, adCmdText

    but the result of query is very very very slow.

    I need assistente for conn and recordset.for correwt the setting

    suggest my is i need to add cursor type or change completly the strategy.
    Tks
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,285
    Likes Received:
    364
    Trophy Points:
    83
    Is the connection slow or execution of query slow?
     
  3. LUCA90

    LUCA90 New Member

    Joined:
    Mar 3, 2009
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    0
    only the query.
    But i think a good connection improve the good query.
     
  4. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,285
    Likes Received:
    364
    Trophy Points:
    83
    A select statement should not be very slow

    SQL = "SELECT ecc where ecc"

    And so it has to be your connection. Try connecting to your local Access and see if it is this slow.
     

Share This Page