Using the ARMImporter Tool in Event Rules

To use the ARMImporter tool in Event Rules, follow the procedures below to create a batch file, create a custom Command that references the batch file, then create an Event Rule to execute the Command at a specified date and time.

Create a Batch File

Create a DOS batch file that contains the commands that you would normally type at a command line. You can then run the command using a custom Command. You can run and verify this batch file from the command line before creating the custom Command to call this batch file. Use the commands below depending on which Server you are using.

SQL Server batch file example:

ARMImporter_SQL -U admin -P a -d EFTDB-S 192.168.38.207\GlobalScape -I "H:\SQLFile_Parse\ARMImporter" -o "H:\SQLFile_Parse\ARMImporter" -p -I

Oracle batch file example: 

ARMImporter_ORACLE_-U system -P admin -S localhost:1521/XE -i  "D:\Files"  -o "D:\Files"  -p -I -l

Create a Custom Command

Create a custom Command to execute the batch file automatically.

  1. In the Administrator, connect to EFT Server and click the Server tab.

  2. In the left pane, expand the Site node for the Site on which you want to create the Command, then click Commands.

  3. In the right pane, click New. The Custom Command wizard appears.

  4. In the Command name box, provide a descriptive name for the Command. This name will appear under the Commands node of the tree and in Event Rules when you add the Action Execute command in folder.

  5. In the Description box, provide a brief explanation of the rule. (Optional)

  6. Click Next.

  7. In the Exe path box, provide the location of the bat file that you created.

  8. Click Next.

  9. In the Parameters box, provide any switches that EFT Server must pass in when the command is executed.

  10. The following switches can be used with the ARMImporter utility:

    Switch

    Description

    -U

    User name for SQL login

    -P

    Password for SQL Login

    -d

    SQL Server Database name

    -S

    SQL or ORACLE server name/IP

    -i

    Source path for the *.sql files.

    -o

    Path where *.arm files will be generated.

    -p

    Parses .sql files.

    -I

    Imports the .arm files into the SQL or ORACLE server. This switch is case sensitive.

    -l (el)

    Enables the generation of log files during the file parsing phase.

    -h

    Provides more information about the tool.

  11. Click Finish. The Command appears in the Commands node and in the Command Settings tab.

Create an Event Rule

Create a Scheduler (Timer) Event Rule to schedule when the Command will execute the batch file.

  1. Refer to Scheduler (Timer) Event, if necessary.

  2. In the Actions list, double-click Execute Command in folder.

  3. In the Rule window, click the blue "select" link. The Custom Command dialog box appears. (Refer to Editing a Command if necessary.)

  4. In the Specify command working folder box, type or browse to the path to the ARMimporter.bat, then click OK.

  5. In the right pane, top-left corner, ensure the Enable this rule check box is selected.

  6. The Rule is defined by default to trigger each hour starting on the date you create the Rule. To change the start date, start time, recurrence pattern, and/or interval, in the Rule pane, click repeat each 01:00:00. The Timer Event dialog box appears.

  7. In the Recurrence pattern area, specify that the Rule is to run no more often than Daily. Weekly should be sufficient.

  8. Specify the Start time and Start date, then click OK. The frequency is updated in the Rule pane.

  9. Click Apply to save the Event Rule on EFT Server. The Event Rule is now ready to execute the command on a schedule that you specify. You can click Run Now to run the Rule immediately or to test the Rule.

Related Topics