Results 1 to 3 of 3
  1. #1
    Villa123 is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Jun 2016
    Posts
    9

    Linked tables from frontend keep disconnecting from backend db

    I am working with an existing split database, where the frontend db is used by 4 users and a copy is saved to their local desktop, and the backend db is located on a shared network drive and contains tables and data.

    From the frontend db I have linked several tables to the backend, however only half of the tables remain linked after a period of time. I have tried deleting the tables, and then adding them again as a linked table from the back end. It will save and work as a linked table for about 30 minutes, and then after closing and re-opening the frontend, the tables no longer show as being linked. Linked Table Manager is useless at this point, because it does not show the tables as being linked therefore i cannot reconnect the path to the backend.

    The location of the backend does NOT change.

    Anyone have this issue, and what solutions worked?


    Here are the naming convention of db and tables, those marked with an asterisk are the tables that keep disconnecting:

    Frontend DB = Resource_Database_Business_Office - V8.accdb
    Backend DB = Data_Back_End.accdb
    Tables:
    tbl_Import_It
    tbl_accounts
    tbl_annual_role_rates
    tbl_clarity_projects *
    tbl_clarity_projects_WBS_Level_5 *


    tbl_clarity_projects_WBS_Level_6 *
    tbl_Monthly_Actuals *
    tbl_PO
    tbl_Rate_History
    tbl_Resource_Allocation
    tbl_Resources
    tbl_SDMS *
    tbl_tower_list *

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    This can't be possible. Once linked in they stay unless someone,or some code, removes them.
    Is there code?

  3. #3
    Villa123 is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Jun 2016
    Posts
    9
    I was able to find this code within the Switchboard. VBA is not my strong suit, so I am unable to tell if this is the cause:

    Private Sub Form_Open(Cancel As Integer)
    On Error GoTo Error_Handler
    Dim NewDate As Date
    Dim TblNm As String
    Dim DelTab As String
    Dim Sql1 As String
    Dim Sql2 As String
    Dim db As Database
    Dim Rst1 As Recordset
    Dim Rst2 As Recordset
    Set db = CurrentDb()

    NewDate = Date

    Sql1 = "SELECT Import_It.New_Import, Import_It.Table_Name, Imported.Import_received" _
    & " FROM Import_It LEFT JOIN Imported ON (Import_It.New_Import = Imported.Import_received) AND (Import_It.Table_Name = Imported.Table_To_Import)" _
    & " WHERE Imported.Import_received Is Null"
    Set Rst1 = db.OpenRecordset(Sql1)
    With Rst1
    If .EOF Then
    MsgBox "Rst1 is at EOF"
    Else
    MsgBox "One moment while your new tables are being imported"

    With Rst1
    Do While Not .EOF
    Sql2 = "SELECT Imported.ID, Imported.Import_received, Imported.Table_To_Import" _
    & " FROM Imported" _
    & " WHERE Imported.Table_To_Import = " & Chr(34) & Rst1.Fields(1) & Chr(34)

    Set Rst2 = db.OpenRecordset(Sql2)
    If Rst2.EOF Then

    Else
    Rst2.Edit
    Rst2.Fields(1) = NewDate
    Rst2.Update
    End If
    ' modified to check if table exists before trying to delete it
    If Not IsNull(DLookup("Name", "MSysObjects", "[Name]=" & Chr(34) & Rst1.Fields(1) & Chr(34))) Then
    DoCmd.DeleteObject acTable, Rst1.Fields(1)
    End If
    TblNm = Rst1.Fields(1)
    DoCmd.TransferDatabase acImport, "Microsoft Access", "\\catomcgfspuwby\corpdatay$\Visteon\Data_Back_End. accdb", acTable, TblNm, TblNm, False
    .MoveNext
    Loop
    End With
    End If
    End With
    Me.Repaint
    MsgBox "Your Import Complete"

    Exit_Procedure:
    Exit Sub


    Error_Handler:
    MsgBox "An error has occured in this application. " _
    & "Please contact XXXXXXXXX and " _
    & "tell him this information:" _
    & vbCrLf & vbCrLf & "Error Number: " & Err.Number & ", " _
    & Err.Description, _
    Buttons:=vbCritical

    Resume Exit_Procedure
    End Sub
    Last edited by Villa123; 06-02-2016 at 04:12 PM. Reason: additional info found

Please reply to this thread with any new information or opinions.

Similar Threads

  1. backend-tables in cloud, frontend on desktop
    By raffi in forum Import/Export Data
    Replies: 4
    Last Post: 12-15-2014, 11:57 AM
  2. Replies: 3
    Last Post: 05-14-2014, 01:30 PM
  3. Access Switching to frontend and backend
    By caliskier in forum Access
    Replies: 4
    Last Post: 11-19-2012, 11:58 AM
  4. Replies: 1
    Last Post: 08-24-2012, 07:11 AM
  5. Replies: 2
    Last Post: 03-21-2011, 12:55 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums