Results 1 to 5 of 5
  1. #1
    ribena1980 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jul 2015
    Posts
    7

    Referential Integrity On Linked Tables

    Hi,



    I have accounts Databases for each year dating back to 2007.

    I am trying to uniform the data and had the idea that each of the database years would import a table of valid account sections and subsections from a master database.

    These 2 tables of valid account sections and subsections would be on 1 database, where any new, amended or deleted item would cascade onto the database years.

    For example, adding the section Car and Subsections Insurance, Tax, Petrol, Parking onto the Master Database meaning that 2007.mdb, 2008.mdb, 2009.mdb etc would be able to have items Car and its sub items selected.

    The problem I have is enforcing the Referential Integrity of this. From doing some research it seems like this is not possible with Linked tables as it cannot guarantee that tables in the master database will always be available.

    Although I understand the theory behind this , how do we get around this issue to enforce a situation like the one I have described above.

    Thanks,
    Mark

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,527
    you wouldnt have separated databases for each year.
    ALL data would be in 1 database, for EVERY year. You wouldnt break it up.

  3. #3
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    The problem I have is enforcing the Referential Integrity of this. From doing some research it seems like this is not possible with Linked tables as it cannot guarantee that tables in the master database will always be available.

    Although I understand the theory behind this , how do we get around this issue to enforce a situation like the one I have described above.
    True, you won't be able to use the built in RI, but YOU could write (all of the) code to enforce RI between the different dBs. Lots of work!

    I would rather have all of the data in one dB, if possible.

  4. #4
    ribena1980 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jul 2015
    Posts
    7
    Hi Guys,

    Thanks for the replies. Although having everything in the one database probably is the best practical solution, I really dont want to go down that route if I can avoid it.

    Is there a mechanism where I can have the sections and descriptions on a main database and import the contents of those tables into each year.mdb file and enfor referential integrity from that point?

    Thanks,
    Mark

  5. #5
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    where I can have the sections and descriptions on a main database
    Do you have tables named section and description? Section and Description are reserved words and shouldn't be used for object names.

    Is there a mechanism where I can have the sections and descriptions on a main database and import the contents of those tables into each year.mdb file and enfor referential integrity from that point?
    If sections and descriptions are tables, then yes, I think you should be able to import the tables into each year.mdb file and enforce RI.

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

Similar Threads

  1. Referential Integrity
    By Paul H in forum Database Design
    Replies: 3
    Last Post: 11-14-2011, 03:07 PM
  2. referential integrity
    By askjacq in forum Database Design
    Replies: 1
    Last Post: 10-14-2011, 03:23 PM
  3. Referential Integrity
    By Desstro in forum Database Design
    Replies: 4
    Last Post: 06-13-2010, 01:29 PM
  4. Referential Integrity
    By U810190 in forum Access
    Replies: 1
    Last Post: 03-29-2010, 05:21 PM
  5. Referential Integrity
    By jbarrum in forum Access
    Replies: 5
    Last Post: 01-14-2010, 09:04 AM

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