Validating imported data

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Stewart Allen

    #1

    Validating imported data

    Hi there

    Opinions on the best way to do this.

    I want to import data from an Excel spreadsheet into Access and want the
    data to be tested before the tables are updated. At the moment all the data
    is validated via the data entry form where the BeforeUpdate event is used
    for some fields and also in the form. I know these events won't fire if the
    data is imported via code.

    I was thinking about importing the data into another table first and then
    use code to check the data. If the data is validated successfully, transfer
    the data into the proper table via Append and Delete queries, or prompt the
    user that there is something wrong with the data and the main table will not
    be updated.

    Now if the data is not transferred because it's not valid and the user wants
    to import data from a different Excel spreadsheet, would it be better to
    move the invalid data into a different table for the user to come back to at
    a later date? This is so the table that holds the imported data only holds
    one record at a time, checks the data and moves it to the correct location.

    Are there any better ways to do this? I don't really want to import the data
    directly into the proper table and find out that the data was not correct or
    even that this data has been imported before.

    TIA
    Stewart


Working...