5 Replies Latest reply: Feb 22, 2010 7:29 AM by QuestionsQuestions RSS

    Adding records to an existing table

      Hello there, me again, hope someonce can advise.

      I want to run a daily process that brings in records in an 'Outstanding' status, and records their 'Record ID', the 'Current Date' and the 'Team' that they are assigned to.

      I want to add a new set of records that meet the 'Outstanding' criteria each day, so that i can trend the volume of 'Outstanding' Records. What i dont want to happen is for the table to be completelty refreshed each day, i want all previous records to remain, and a new block or 'Outstanding' Records to be added to the bottom of the table.

      e.g.

      Day 1 run creates

      Outstanding Records:

      ID, Date. Team

      1, Day1, TeamA

      3, Day1, TeamA

      5, Day1, TeamB

       

      Day 2 Run adds new records to the table, tagged as Day2

      ID, Date, Team

      1, Day1, TeamA

      3, Day1, TeamA

      5, Day1, TeamB

      3, Day2, TeamA

      5, Day2, TeamB

      8, Day2, TeamA

       

      I would also like to only store each record ID once for each day, so if i run the import again on the same day i want to avoid creating duplicate entries in the table.

      Can someone advise how to add the new records to an existing table without creating duplicate records?

       

      Thanks...