Page 3 of 3 FirstFirst 123
Results 31 to 33 of 33

Taking data from 1 table and writing it to a second table provided certain conditions are met

  1. #31
    Bob M is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    30
    Not sure I comprehend what Table 3 is telling me

    Every record in Table 1 should have a Table 2 reference
    At the moment they do NOT

    Also Table 1 records MUST remain in their initial ordering while being processed
    At the moment they do NOT seem to be

    Otherwise, how can the 15th record (assuming that Table 1 is processed in Date/Time order ALWAYS) [2.1.2013:13] have a Table 2 reference of 15 when we only have 5 Table 2 records at that point ?



    Bob M

    I think (after the code run) that Table 1 records - the first 15 records - should look like this
    i.e. records in Table 1 retain their original order, all records have a Table 2 ID and the 15th record should have a '6' for Table 2 ID not '15'

    ID Table2_ID Local Time
    1 1 01.01.2013 00
    2 2 01.01.2013 01
    3 3 01.01.2013 02
    4 3 01.01.2013 03
    5 3 01.01.2013 04
    6 3 01.01.2013 05
    7 4 01.01.2013 06
    8 4 01.01.2013 07
    9 4 01.01.2013 08
    10 4 01.01.2013 09
    11 5 01.01.2013 10
    12 5 01.01.2013 11
    13 5 01.01.2013 12
    14 5 02.01.2013 11
    15 6 02.01.2013 12
    Last edited by Bob M; 01-15-2018 at 12:59 PM.

  2. #32
    Bob M is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    30
    Hi Steve
    finally figured what was wrong here...................
    the field 'localtime' is not an acceptable date time format - thus the jumping around of the Table 1 records

    All good now, except for the 178 Table 1 records which don't get a Table 2 reference each time a new Table 2 record is written

    Many thanks again for your assistance

    Bob M

  3. #33
    ridders52's Avatar
    ridders52 is online now Long time standing
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    328
    Glad you got it working
    Having read this thread from the sidelines, I think Steve deserves a huge reward for persevering with this thread
    Colin (Mendip Data Systems)
    Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10, Website, email

Page 3 of 3 FirstFirst 123
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 03-07-2017, 04:02 PM
  2. Replies: 0
    Last Post: 03-12-2013, 01:51 PM
  3. writing data from recordset to table
    By akrylik in forum Access
    Replies: 5
    Last Post: 05-23-2012, 04:48 PM
  4. Replies: 3
    Last Post: 07-13-2011, 07:01 AM
  5. Writing data from textbox to table
    By mll in forum Forms
    Replies: 4
    Last Post: 03-10-2010, 04:10 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
  •  
Tech Forums: Microsoft Office Forums