Results 1 to 3 of 3
  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Ephrata, Washington, USA
    Posts
    683
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Access 97 (Sync laptop to network)

    I have a db on a laptop that is used in the field for data entry. The user wants to "dump" the data to the network at the end of each day, thus updating the network "main" database. Not quite synchronize because he wants the laptop db to start empty every morning. My first thought was append queries, but the primary keys confuse me. Every table has a primary key, so if I append the laptop data to the network, how do you maintain relationships. I have almost zero knowledge of VB, so if this can be done with code, I will need some serious 'hand holding' to accomplish this. Thanks!

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Access 97 (Sync laptop to network)

    Without knowing the structure of and relationships between the tables, it is hard to give specific advice.

    You could create a series of append and delete queries.

    Start with append queries that transfer records with newly created primary key values, then append queries that contain values that refer to those primary keys. For exampples, if you have customers and orders, the orders table will contain a Customer ID. You need to append newly entered customers to the customers table before appending newly entered orders to the orders table, otherwise you'll cause a key conflict.

    If you have set cascading deletes for the relationships between the tables, deleting a record will also delete dependent records in related tables. Otherwise, start by deleting the dependent records (the orders in my example), then the "main" records (the customers.)

    To make things easy, you can include the execution order in the naming of the queries.

  3. #3
    Star Lounger
    Join Date
    Jun 2001
    Location
    Christchurch, New Zealand
    Posts
    73
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Access 97 (Sync laptop to network)

    In a recent experience of similar nature to your position, unknown to the user was that on some days the data did not actually make it onto the network db.

    If your user needs a clean db after the upload, make sure that you either build into your delete queries a check to ensure that the data is present in the network db before deleting or don't delete the data & store it in a secondary table on the laptop PC (size etc may impact on this of course)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •