<?xml version="1.0" encoding="utf-8"?>
<ManualTopic ID="/baanerp/tf/onlinemanual/000436" xml:lang="en">
   <Header>
      <Title>Archiving finalized transactions</Title>
      <Keyword type="header" order="d1e1670945">
         <Level1>Multicompany archiving</Level1>
         <Level2>Financials</Level2>
      </Keyword>
      <Keyword type="header" order="d1e1670950">
         <Level1>Archiving</Level1>
         <Level2>multicompany Financials</Level2>
      </Keyword>
   </Header>
   <GeneralSection>
      <List>
         <ListIntro>To support correct archiving in a multicompany structure, the
		  following rules apply:</ListIntro>
         <ListItem>Each company must have its own archive company. Companies
		  cannot share an archive company.</ListItem>
         <ListItem>The structure of archive companies must be an exact copy of the
		  live environment.</ListItem>
         <ListItem>A company must keep the same archive company until the end of
		  its lifetime. Once data has been archived, you cannot change the archive
		  company.</ListItem>
      </List>
      <Paragraph>If extra archiving capacity is required, it is recommended that
		you set up a second archiving environment, which must also be an exact copy of
		the live environment. Define the companies of the second archive environment as
		the archive companies of the companies of the first archive environment. If
		necessary, a third and more archiving environments can be set up. You must then
		archive the data from each archive company to its archive company in the second
		archiving environment, and so on.</Paragraph>
      <Paragraph>When you archive the data, LN builds an array with all the
		companies of the group and the archive company linked to each company. If any
		of the companies in the group does not have an archive company, LN reports
		an error and aborts the archiving process.</Paragraph>
      <Paragraph>Batches and batch lines are only archived and/or deleted if you
		perform archiving and deletion in the company in which they exist. This is
		always the source company. Any intercompany documents and related finalized
		transactions that belong to the batch are not archived and/or deleted until the
		target company is archived.</Paragraph>
      <Paragraph>If the batch has been deleted from the live environment, such
		intercompany documents and transactions will then temporarily exist without a
		batch in the live environment until the target company’s transactions are
		archived. Therefore, it is recommended to archive all the companies of a group
		within a short time.</Paragraph>
      <Paragraph>Finalization runs are also archived. A finalization run can only
		be deleted from the live environment if all the attached batches have also been
		deleted.</Paragraph>
      <Paragraph>Financial documents are archived and/or deleted if you perform
		archiving and deletion in the company in which they exist. For each document, LN searches whether a related intercompany document exists.</Paragraph>
      <Paragraph>If the document’s transaction type indicates that the document
		numbering does not have to be in a fixed sequence, the document is not deleted
		from the live environment, to avoid duplicate document numbers.</Paragraph>
      <Paragraph>A finalized transaction is not deleted from the live environment
		if the fiscal year of the transaction does not equal the fiscal year of the
		batch and the fiscal year of the transaction cannot yet be archived. If the
		Archive option is selected, the related batch, batch line, and document are
		copied to the archive company and retained in the live environment.</Paragraph>
      <Paragraph>If a transaction is still referenced by open sales orders or
		purchase orders, it is marked as <GUIRef href="" role="manual">Deleted</GUIRef> but not actually
		deleted. The related batch, batch line, and document are copied to the archive
		company and retained in the live environment. They are deleted when the
		referenced open transactions are closed and archived, for example, when you run
		the <GUIRef href="/baanerp/tf/acp/tfacp2250m000" role="session">Archive / Delete Fully Paid Purchase Invoices (tfacp2250m000)</GUIRef> session</Paragraph>
      <Paragraph>If the transaction’s ledger account is a matchable account, any
		related matching data is also archived.</Paragraph>
      <Paragraph>During the archiving process, the originating company of the
		finalized transaction is replaced with the originating company’s archive
		company. In this way, the archive environment will not contain references to
		the live environment.</Paragraph>
      <Paragraph>During archiving, intercompany document relations are also
		copied to the archive environment. In the archive environment, these relations
		are updated in such a way, that each document in the relation refers to the
		environment in which the document actually exists. In the live environment, the
		document relation is retained until all related finalized transactions have
		been deleted. For invoice-related transactions, this only occurs during the
		removal of fully-paid invoices. The document relation is also updated in the
		live environment, in order to refer to the archived document if all related
		finalized transactions have been removed from the live environment.</Paragraph>
      <Paragraph>After the normal archiving process, an additional archiving step
		is performed in which all transactions and documents in the live company that
		arise from intercompany postings, are archived. During this step, intercompany
		relations are archived and/or deleted as described earlier.</Paragraph>
      <Paragraph>Batches, batch lines, and documents that have the <GUIRef href="" role="manual">Deleted</GUIRef> status are deleted from the live environment, unless
		the document’s transaction type indicates that the document numbering does not
		have to be in a fixed sequence. Such documents are not deleted from the live
		environment, to avoid duplicate document numbers.</Paragraph>
   </GeneralSection>
   <RelatedTopics>
      <SectionTitle>Related topics</SectionTitle>
      <RelTopic>
         <Link href="/baanerp/tc/onlinemanual/000035" role="manual">To use an archive company</Link>
      </RelTopic>
   </RelatedTopics>
</ManualTopic>