• append tables (Access 2000)

    Author
    Topic
    #360406

    I am trying to append two tables, products and products1 with the following code:
    INSERT INTO products1 ( branch1 )SELECT products.branch1 FROM products;
    The table Products has 2 fields: productid and branch1.The Productid is an autonumber and branch1 is Number.However the appending seems not to follow the productid number.For example, the field branch1 for the productid is 6 but it is not shown in the results.I suspect i am doing
    a grave error in my code.May i have some help?

    Viewing 0 reply threads
    Author
    Replies
    • #542692

      Do you mean that a particular record for branch1 has a productID of 6 but when you append that record, the productID changes? If you don’t append the productID field from the table as well as the branch1 field, then no, the productIDs won’t be the same in the table you append to. That’s why I suggested using the CLng() function to convert the ProductID to a long integer so it could also be appended to the other table in this thread.

      • #542713

        Dear Charlotte,

        I realy have to let you know that what you suggested about appending tables works excellent and you really helped me a lot indeed.I appreciate very much what you and your colleagues are doing

    Viewing 0 reply threads
    Reply To: append tables (Access 2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: