12Archiving Objects

Archiving Objects

Overview of Archiving Objects

Archiving is a process where you export objects from the repository to an archive file. You can then import objects from the archive file back into the repository. You can use an archive to back up sets of objects or move them to another environment that shares the same physical database schema as the source environment. Note the following:

  • An archive does not depend on a database because it includes only repository information. You can use it to exchange repository data between environments with different database platforms, including local and server databases, as long as these databases use the same schema.

  • If you import objects from an archive, then you can specify conflict resolution rules for each object. You can configure Siebel Tools to ignore an imported object, replace an existing object with an imported object, or merge two objects according to object properties.

  • You can archive individual objects or entire projects to an archive.

  • You can use code control software to control an archive.

  • If you want to back up or move the entire repository to another environment, then see Exporting and Importing Repositories.

For more information about the files that you use when archiving objects, see Files That You Use to Manage Repositories.

    Using Export and Import for Different Versions of Siebel CRM

    If you export objects from one version of Siebel CRM to another version, then do not import these objects through .sif files into a different version of Siebel CRM because Siebel CRM might modify object definitions between these versions. If you import an object that is not valid, then an invalid configuration might result. Oracle does not support an invalid configuration.

      Where Siebel Tools Stores Archive Files

      The Temp parameter in the Siebel section of the tools.cfg file identifies the folder where Siebel Tools stores the following items:

      • Archive files

      • Projects and objects that you check out or check in

      Siebel Tools sets this Temp parameter to the client_root\TEMP folder of your Siebel Tools installation folder, by default.

        Exporting Objects to an Archive

        You can export top-level objects to an archive, such as business components, applets, views, and projects. Siebel Tools exports and imports child objects with their parents. For information about top-level object types, see Displaying Object Types in the Object Explorer.

        Note: Web Tools supports only export in Innovation Pack 2017.

        Do not export the repository object to export an entire repository. If you do this, then the export file is too large and it degrades performance. For more information, see Exporting Repositories.

        This task is a step in Roadmap for Setting Up and Using Siebel Tools.

        To export objects to an archive

        1. In the Object List Editor, locate the object you want to export.

          For more information, see Locating and Modifying Object Definitions in the Object List Editor.

        2. Click the Tools menu, and then click Add To Archive.

          Siebel Tools displays the Export to Archive File dialog box. The status bar in this dialog box indicates the child objects that Siebel Tools includes in the export. When the process finishes, this dialog box displays the top-level objects in the Objects to Archive list.

          Tip: The dialog box displays as Add To Archive in Web Tools. The Objects textbox displays the name of the selected object. You can archive only one object at a time.
        3. If you want to add more objects, then repeat Step 1 through Step 2 for each object. Do not close the Export to Archive File dialog box while you add these objects.

          You can add objects of the same object type or you can add objects of another object type.

        4. In the Export to Archive file dialog box, in the Archive File window, enter the path and file name of the archive file.

          For example, enter C:\Siebel\8.2\Tools_1\objects\objects.sif.

        5. Click Save.

          Siebel Tools creates a SIF file in the location that you specify in Step 4. Web Tools creates the same file and exports using the browser functionality.

          Note: Use Siebel Tools to import an archive.

          Using the Command Line to Export Objects to an Archive

          You can use the command line to export objects to an archive.

          To use the command line to export an archive

          1. Open a command line, and then navigate to the SIEBEL_TOOLS_ROOT\BIN folder.

          2. Use the following command to run the siebdev.exe file:

            siebdev /c config_file /d database /u user_name /p password /ws workspace_name /
            batchexport repository_name input_file_name log_file
            

            The following example exports the objects that the obj.txt input file specifies. It logs results to the export.log file:

            siebdev /c tools.cfg /d sample /u sadmin /p sadmin /ws MAIN /batchexport "siebel 
            repository" obj.txt export.log
            

            For more information about the input file, see Input File That Batch Export Uses.

            Input File That Batch Export Uses

            The batch export switch uses an input file that specifies the objects to export. This input file uses the following format. You cannot use a space before or after a comma in this file:

            object_type,object_name,query_expression,file_name.sif 
            

            where:

            • object_type identifies the object type to export, such as Business Component.

            • object_name identifies the name of the object to export, such as Account.

            • query_expression can include any query that Siebel Tools can use. For more information, see Using the Query Menu to Run a Query.

            • file_name.sif can use an absolute file path or a relative file path to the current folder.

            You can include multiple lines in the input file and each of these lines can specify to export multiple objects to a different SIF file. If you specify the same SIF export file in multiple lines, then batch export uses only the last export that you specify.

            For example, consider the following line from an input file. In this example, the batch export switch exports all business components where the Name property is like *Account* to a repository file named export.sif:

            Business Component,*Account*,export.sif
            

              Preparing the Siebel Tools Environment to Import Objects from an Archive

              You must prepare the Siebel Tools environment before you import an archive.

              To prepare the Siebel Tools environment to import objects from an archive

              1. Make sure the local computer can access the import file through a network or local drive.

              2. Make sure the repository you use to create the archive and the repository to which Siebel Tools imports the archive use the same schema version.

                You can export or import an archive only among repositories that use the same schema version. To determine the schema version that a repository uses, see Viewing Information About the Current Repository.

              3. Make sure the repository is open in Siebel Tools and is the active repository.

                For more information, see Viewing Information About the Current Repository.

              4. Make sure the projects that the import affects are checked out.

                For more information, see Locking Projects Before You Import an Archive.

                Locking Projects Before You Import an Archive

                For non-workspace enabled objects, you need to lock the project before importing an archive file. The Import wizard informs you of any unlocked projects that you must lock. It does this after it analyzes the objects in the archive and compares them to the objects that reside in the repository. For workspace-enabled objects, object locking is done at the database level. Therefore, there is no need to lock any project or object for importing.

                  Importing an Archive

                  This topic describes how to use Siebel Tools to import an archive.

                  To import an archive

                  1. Log in to Siebel Tools.

                  2. Prepare the Siebel Tools environment to import an archive.

                    For more information, see Preparing the Siebel Tools Environment to Import Objects from an Archive.

                  3. Click the Tools menu, and then click Import From Archive.

                  4. In the Select Archive To Import dialog box, choose the archive file, and then click Open.

                    Siebel Tools displays the Import Wizard - Preview dialog box. It lists the projects and other top-level objects that the archive file you opened contains.

                  5. Specify the work that Siebel Tools does if it determines that the archive and the repository both contain the same top-level object. In the Conflict Resolution section, choose an option.

                    For more information, see Options You Can Choose to Resolve a Conflict.

                  6. Click Next.

                    Siebel Tools does one of the following:

                    • If the objects in the archive already exist in the repository, and if Siebel Tools finds no conflicts, then it makes no modifications. It displays a dialog box that describes that it found no conflicts and made no modifications to the repository. In this situation, click OK and exit this procedure.

                    • If any object involved in this import is not locked, or if any project that this object references is not locked, then Siebel Tools displays a warning message. You must cancel the import, lock the objects and projects, and then restart the Import wizard.

                    • If the objects in the archive already exist in the repository, and if Siebel Tools finds a conflict, or if the objects do not exist in the repository, then it displays the Import Wizard - Review Conflicts and Actions dialog box. This dialog box includes information about the differences. In this situation, go to next step.

                  7. In the Import Wizard - Review Conflicts and Actions dialog box, in the Conflicting Objects section, choose an object.

                    If you choose an object, then Siebel Tools displays differences in the Object Differences and Attribute Differences sections. Siebel CRM uses the terms attribute and property. These terms have the same meaning. For more information, see Using the Review Conflicts and Actions Dialog Box of the Import Wizard.

                  8. To make an adjustment, right-click a difference, and then choose an action.

                  9. Click Next.

                    Siebel Tools displays the Summary dialog box and starts the import.

                  10. When Siebel Tools finishes the import, you can click Finish.

                    Siebel Tools creates a log file named importlog.txt in the following folder:

                    SIEBEL_TOOLS_ROOT\TEMP
                    

                    It includes the list of messages that it displayed in the Summary dialog box. To maintain a record of this import, you can modify the importlog.txt file name to the current date.

                    Options You Can Choose to Resolve a Conflict

                    A conflict is a situation that occurs if an object that Siebel Tools attempts to import from an archive does not match the corresponding object in the repository. Siebel Tools examines these objects to determine if they include the same properties, property values, and child objects. If these items are not the same, then Siebel Tools recognizes this situation as a conflict.

                    The following table describes options you can choose to resolve a conflict that occurs during an import. It describes the work that Siebel Tools does if it determines that the archive and the repository both contain the same top-level object.

                    Table Options You Can Choose to Resolve a Conflict

                    Option Description

                    Overwrite the Object in the Repository

                    Siebel Tools deletes the object in the repository and the child objects of this object, and then copy the object and child objects from the archive to the repository.

                    Merge the Object Definitions From the Archive With the Definition in the Repository

                    Siebel Tools does the following:

                    • Replaces the properties that are different in the repository with the properties that the archive contains.

                    • If the archive includes child objects that the repository does not contain, then it copies these objects from the archive to the repository.

                    • Does not modify child objects in the repository that are not also in the archive.

                    When Siebel Tools finishes this merge, the top-level objects in the repository include the same properties and child objects that the object in the archive includes. It also includes any child objects that already exist in the repository.

                    Siebel Tools merges objects, by default. This option is typically the safest option.

                    Do Not Import the Object Definition From the Archive

                    Siebel Tools does not modify the objects in the repository.

                      Importing Multiple Archives

                      This topic describes how to import multiple archives.

                      To import multiple archives

                      1. Log in to Siebel Tools.

                      2. Prepare the Siebel Tools environment to import an archive.

                        For more information, see Preparing the Siebel Tools Environment to Import Objects from an Archive.

                      3. Click the Tools menu, and then click Import from Archives.

                      4. In the Select Archives to Import dialog box, choose one or more SIF files to import, and then click OK.

                      5. In the Conflict Resolution section of the Import from Archives dialog box, choose an option.

                        You specify the work that Siebel Tools must do if it determines that the archive and the repository both contain the same top-level object. For more information, see Options You Can Choose to Resolve a Conflict.

                        You can also do the following, as necessary:

                        • To control the order that Siebel Tools uses to import the archive, choose a row, and then click the up arrow or down arrow.

                        • To add more archive files, click Add, choose the files you want to add, and then click OK.

                          Siebel Tools does not add duplicate files to the import list.

                        • To remove an archive, choose the archive you want to remove, and then click Remove.

                        • To view the objects that a SIF file includes, choose this SIF file in the SIF Files list, and then click Preview. After you finish previewing, click OK.

                      6. In the Import from Archives dialog box, Click Import.

                        Siebel Tools begins the import in the order that you specify. You can click Cancel to cancel the import.

                        Siebel Tools displays Done in the status bar at the end of the Import from Archive(s) dialog box when the import finishes. It displays the following status for a SIF file in the SIF Files list:

                        • Completed. Import for this SIF file completed successfully.

                        • Failed. Import for this SIF file encountered an error and did not complete successfully.

                      7. If a conflict occurs, then review the Import from Archive(s) - Review Conflicts and Actions dialog box, and then click Continue.

                        Using the Command Line to Import an Archive

                        You can use the command line to import objects from an archive. You can also use the command line to do other work.

                        To use the command line to import an archive

                        1. In Siebel Tools, make sure the projects that the import affects are checked out or locked.

                          You cannot use the command line to check out or lock these projects. For more information, see Open a command line, and then navigate to the SIEBEL_TOOLS_ROOT\BIN folder.

                        2. Use the following command to run siebdev.exe:

                          siebdev.exe /c tools.cfg /d ServerDataSrc /u SADMIN /p MSSQL /ws dev_sadmin_m9 /
                          batchimport "Siebel Repository" merge "C:\Tools75\import.sif" import.log
                          

                          Here /ws refers the workspace name and this workspace needs to be in the editable state for import to be successful. You can use the full path or the relative path to the current folder to specify the SIF file and the log file.

                          To import, also note the following options:

                          • import_mode determines how to handle a conflict. You can use one of the following values with it:

                            • overwrite.

                            • merge.

                            • skip. If you use skip, and if a corresponding object does not exist in the repository, then there is no conflict and the utility imports the record.

                            For information, see Options You Can Choose to Resolve a Conflict.

                          • sif_files specifies the name of one or more sif files that contains the objects that batchimport imports, such as sif_file1, sif_file2, sif_file_n, or the path to a folder that includes .sif files.

                          • log_file specifies the name of the file that siebdev uses to log information.

                          Example of Using the Command Line to Import an Archive

                          The following example imports an archive:

                          siebdev.exe /c tools.cfg /d ServerDataSrc /u SADMIN /p MSSQL /ws dev_sadmin_m6 /
                          batchimport "Siebel Repository" overwrite import1.sif, import2.sif" import.log
                          

                          It uses the overwrite option for conflict resolution. It logs the results to the import.log file. For more information, see Options You Can Choose to Resolve a Conflict.

                          Example of Importing All Files

                          The following example imports all files:

                          siebdev.exe /c tools.cfg /d ServerDataSrc /u SADMIN /p MSSQL /ws dev_sadmin_m4 /
                          batchimport "Siebel Repository" merge C:\23075\Tools\importfiledir import.log
                          

                          This command imports all files in the following folder:

                          C:\23075\Tools\importfiledir 
                          

                          It uses the merge option for conflict resolution. It logs the results to the import.log file.

                            Using the Review Conflicts and Actions Dialog Box of the Import Wizard

                            The following image includes the dialog box that appears if Siebel Tools determines that a difference exists between an object in the repository and an object in the archive. You can use this dialog box to review differences and to modify the work that Siebel Tools does to resolve the conflict.

                            Review Conflicts and Actions Dialog Box of the Import Wizard

                              Conflicting Objects Section

                              The Conflicting Objects section displays the hierarchy of objects that include differences. This hierarchy uses the same structure as the object type hierarchy in the repository but it displays only objects that include conflicts rather than all repository objects. The objects in the Object Differences dialog box include objects for all hierarchical levels, not just top-level objects.

                                Object Differences Section

                                The Object Differences section lists the objects that include a difference. It includes the following columns:

                                • File column. An X in this column indicates that the object exists in the archive.

                                • Repository column. An X in this column indicates that the object exists in the repository. An object can exist in the archive and in the repository. These columns provide only information. You cannot modify them.

                                • Action column. Indicates the proposed resolution for the object. Siebel Tools uses the choices you make in the Conflict Resolution section of the Preview pane to determine the work that it does to display information in this column. To modify this work, you can right-click the value in the Action column, and then choose another action. For a description of these values, see Options You Can Choose to Resolve a Conflict.

                                  Attribute Differences Section

                                  The Attribute Differences section displays the property value conflicts for the object you choose in the Object Differences section. It lists only the properties that include a conflict. Siebel CRM uses the terms attribute and property. These terms have the same meaning.

                                  The following table describes the columns in the Attribute Differences section.

                                  Table Columns in the Attribute Differences Section

                                  Column Description

                                  Attribute

                                  Name of the object.

                                  File

                                  Value of the object in the archive.

                                  Repository

                                  Value of the object in the repository.

                                  Resolution

                                  Includes one of the following values:

                                  • File. Siebel Tools deletes the value in the repository during the import and replaces it with the value from the archive.

                                  • Repository. Siebel Tools does not modify the value in the repository.

                                  You can modify this resolution depending on the following value that the Action column in the Object Differences contains:

                                  • Merge. You can modify the resolution. To modify it, you can right-click the value in the Resolution column, and then click Repository or File.

                                  • Not Merge. You cannot modify the resolution.

                                    Using the Application Deployment Manager

                                    The Application Deployment Manager (ADM) is a feature that you can use to administer a Siebel CRM deployment. Siebel Tools supports ADM through the following business service:

                                    Siebel Tools Export Support for ADM

                                    It allows you to export individual objects to a hotfix or to export all objects that Siebel CRM modified after a particular date and time to a mid-level release. For more information, see Siebel Application Deployment Manager Guide.