Results 1 to 12 of 12
  1. #1
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398

    Linking a table

    I'm having difficulty with linking a table.

    I've setup Bob Larsen's excellent feature of updating the FE DB. Both the FE DB and the BE DB are located on a server. A user has their own version of the FE DB on their PC. Within a form, the user creates an archived table. This table gets added to the BE DB.

    What I'm needing to do is link the newly created archive table to the FE DB that is on the server. I've viewed a lot of code to assist with linking, but nothing with what I'm trying to do.


    1. How do I set the db as being the FE DB on the server. I'm able to retrieve the path and name of the FE DB, but I can't figure out the correct syntax.

  2. #2
    Dal Jeanis is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2013
    Location
    Dallas TX
    Posts
    1,742
    I'm missing something in the question.

    You have a user FE on user's machine C. You have a BE on machine S. The user FE is already connected to the BE, and creates a table on the BE.

    The FE on the server is your current production "base" FE. It is already able to link to the BE, no matter where the production FE gets copied. The BE is in a single place.

    Every single FE copy is able to link to the BE that has the backup table. So, what is it that you are looking to do?

  3. #3
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862

    removed link code

    What Dal said....

    The syntax would like
    \\ServerName\FolderName\DBName.extensiontype
    enclosed in quotes and assigned to a String variable

  4. #4
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398
    When the user creates the table, I need the FE on the server, production "base" FE to have the link for the new table within the BE.

  5. #5
    Dal Jeanis is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2013
    Location
    Dallas TX
    Posts
    1,742
    You really do NOT want to be messing with the user FEs updating your production FE master. That's a design disaster in the making. Wow. Contention, corruption. Any number of headaches and surprises.

    I probably haven't said it strongly enough, so hopefully someone will chime in with a single N and a few hundred capital O's. Really, the FE master should only be updated, by professionals (you), when a version upgrade is occurring.

    A better strategy is to have each FE automatically, on opening, or when a particular form is opened/refreshed, look to see what backup tables might be present on the BE, and create the links. Much safer, clearer, and easier to code as well!

  6. #6
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862
    Your archive table should be running programmatically. Its structure should not change. Because the structure does not change, you only need one archive table. Imagining a need to create multiple tables causes me to believe you are not referring to an "Archive" action.

    Whatever action or task you are attempting to accomplish by creating additional tables sounds like a bad idea to me regardless. It is very rare that I encounter a need to create a new table. It almost ALWAYS happens in the development stage of an application or a module (expansion of function) of an application.

  7. #7
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398
    OK. So maybe the better idea is to have 1 archived table. Rather than create additional archived tables, append the current records within the current table into the single archived table.

  8. #8
    Dal Jeanis is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2013
    Location
    Dallas TX
    Posts
    1,742
    crowegreg - That is generally true. There are some types of data (for instance, auditing or accounting data) that may require another solution, but even those applications can usually be handled with adding a date field and one or two "archive type" fields to the backup record layout.

    This methodology has the advantage that every time you change the layout of your primary table, you will remember that you need to make the exact same change to your single archive table. The more archive tables there were, and the more variants of table names, the more likely that you'll accidentally (or intentionally) let the historical data rot.

    This kind of discussion is how you find out in advance that you might be aiming a blunderbuss at sensitive portions of your own anatomy. Better to find that out before the thing is loaded, right?

  9. #9
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398
    I'm building this DB at a client's location. I won't be here much longer.

    I was creating the archived tables to help produce audit reports. I thought it would be easier to have the data in separate tables. It's a good thing I raised this question now, so I can create my reports correctly.

    Thanks for the assistance!!

  10. #10
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862
    crowegreg,

    Maybe you can start with the task itself. What is the problem you are encountering? Are the users complaining about a specific thing they can not do? Do you have so many records in a specific table it is slowing down the data base? You may be able to adjust how you query the table and what columns are indexed.

    Just putting some ideas out there.

    EDIT: I see you are focused on the task

  11. #11
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398
    No problems. This data is imported in from other legacy systems. I'm creating audit reports to recognize the changes. The user needs to be able to select between the different imports to see the changes in the data. I thought it would be easier to have a separate audit file for each time the import is done. Then, when the report is needed, the user selects the different import dates, then I query the different tables to determine the changes.

    I'll go ahead and only have 1 audit file. Then when the user needs to create the report, they will select the import dates, and I'll create 2 recordsets based on their selection, then compare the 2.

  12. #12
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862
    If dates along with the prime key are not enough to distinguish the different imported data files, you could add Booleans and another unique identifier. Maybe you can grab the file name or use another way to identify the import session. Still believe it is easier than a table. Another option may be to link to the file and run your query while it is outside the DB.

    Once it is all in a single recordset you may discover a way to automate much of the comparison between old and new, which it seems you are doing now anyway.

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

Similar Threads

  1. Linking one linked table to another
    By th1nker in forum Import/Export Data
    Replies: 7
    Last Post: 09-05-2013, 11:16 AM
  2. Linking table
    By TDSRU in forum Access
    Replies: 18
    Last Post: 03-12-2013, 07:36 PM
  3. Fields not Linking to Table
    By jlclark4 in forum Forms
    Replies: 2
    Last Post: 12-20-2010, 08:04 AM
  4. BE / FE new table linking
    By jordanturner in forum Access
    Replies: 3
    Last Post: 10-22-2010, 10:48 AM
  5. Table linking
    By emccalment in forum Access
    Replies: 7
    Last Post: 01-28-2010, 03:51 PM

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