Results 1 to 2 of 2
  1. #1
    3 Star Lounger
    Join Date
    Nov 2001
    Location
    Brisbane, Queensland, Australia
    Posts
    330
    Thanks
    10
    Thanked 0 Times in 0 Posts

    Problem with QRY statement

    I'm having trouble with the following statement:

    CurrentDb.Execute "INSERT INTO tblOT SELECT tblOTemp.* FROM tblOTemp"

    The attached pic shows that tblOTemp has 13 records in it but tblOT behind it shows that only 6 (in this case) have been copied over.

    Any Ideas anyone? On other occasions I have had all, 1, 2, 4 records copied over but it should be a consistent 13 (employees).
    Attached Images Attached Images
    "Heading for the deep end"

  2. #2
    Lounger
    Join Date
    Feb 2011
    Posts
    43
    Thanks
    0
    Thanked 6 Times in 6 Posts
    The failures result probably because the OTID value in those inserted records already exist and I presume OTID is unique.

    CR

Posting Permissions

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