Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2002

    Unanswered: Appending data from a Recordset to a table

    I have a record set that I want to append to a table, how would I go about doing this?


  2. #2
    Join Date
    Oct 2002
    Leicester - UK
    chech the help files on recordset (Dao) method addnew

    the basics are

    dim rs As DAO.Recordset
    set rs = currentdb.openrecordset("<tablename>")
    With rs
    !<fieldname1> = <value1>
    !<fieldnamex> = <valuex>
    End With

    or you can use a append query that looks like

    INSERT INTO <tablename>(<fieldname1>,...,<fieldnamex>)
    SELECT <value1>,...,<valuex>;

    (the select part can be a full select query ie select ... from ... where)
    Definition of a Beginner, Someone who doesn't know the rules.

    Definition of an Expert, Someone who knows when to ignore the rules.

Posting Permissions

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