Archiving question

archiving means that my old data will move to another tables, is this tables outside of my database or inside database? when i need to make query, am i going to make something special to find old record?
LVL 1
fahadmanAsked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
the history/archive tables can be inside the same database, but can also be outside of the database.
in sql server, you would at least put them into a different filegroup than the actual table.

if you are really in the situation to create history/archive tables, you need to make that difference clear in the user forms, so the user searches by default only the current (active) data, and has to explicitely "extend" the search for the history data, if needed.
for that, you then indeed need to query both the active and the archive table then, using a UNION ALL, or, if you work with a stored procedure that "hides" the exact table layout, eventually using a table variable storing the hits first, and  the returning the data from there.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.