Create an Import Definition to use with Process Orders.
You can use the Process Orders to import orders from another source (e.g, an Internet store). First, you need to define the import by matching the fields in your source file to similar fields in Channergy. You only need to define an import once. You can then reuse it every day to import new orders.
Note: If you already have an import definition created you can skip this topic. Go to the Process Orders instructions to import your orders.
- Tor create an import definition click on the
- This will open the Process Orders screen
- Click on the button in the upper right corner of the screen.
- You can also select an existing Import specification from the grid and click on the button.
- This will open the Order Import Setting screen.
- If you would like to use an existing definition: Click the button to open a menu of two options:
- Load from a file: Select this option to use an existing file import specification such as field separators, field mapping etc. For example, you can load the Yahoo-MOM.mwi file that is included with Channergy. It defines an import from Yahoo stores in the MOM format. You can then proceed to the next step to make changes to the definition, or go to the Process Orders help topic to import your orders.
- Save this definition to a file: Use this option to save an existing specification to a file.
- To create a new import specification do the following
- Import Name-Enter a name that defines what type of file you are importing
- Import Type-Unless you are integrating select the default option Standard Single File
- Table Type- In all cases you will keep the default table type as Text
- Order Source File-Click on the button in the Order Source file screen. This will open a Windows file browser, navigate to the file that you want to import and click on the Open button.
- Field Separator-Select the field separator that your file uses, the most common are Comma and Tab. You can open the import file with Windows Notepad to see the separator character.
- Record Separator-This is the character that separates one order from the next. Typically this will be a carriage return (CRLF).
- Text Qualifier-This is the character surrounding each whole word or phrase. Typically this will be a double quote (“).
- First Row-Normally you will select the default of 1 however, if the import file has headers in the first row you will need to select 2
- Last Row-Leave the default.
- Click the Preview tab to see a sample of your import.
- Click the Mapping tab to see a list of Destination Fields (Channergy fields into which you will be importing your data) and definable Source Fields (fields from your import file). The Mapping tab is used to define where each of your import file fields will appear in Channergy.
- For each Destination Field you can select a field from your import file by clicking in the Source Field next to it. A pull down will appear. Click it to see a list of field names from your import file. For each destination field you can select the appropriate field to import into it (e.g., for the Last Name Destination Field you can choose from your import file LastName, Name, LName etc. depending on how your fields are named).
- Note: If your import file has headers on the first row, you may want to select the first row to be 1 for the mapping portion of setting up the import specification. This will allow you to see the field names in the preview screen so that you can map the field numbers to the right field in Channergy.
- Click the Translations tab to see a list of Destination Fields (Channergy fields into which you will be importing your data) and translation fields. The Translation tab is used to change imported values to a different value (e.g., If your import file shows the Country field as 001, 002 etc. you can use the translator to change it to United States, Afghanistan etc.).
- For each Destination Field you can define a translation by clicking in the Translations field next to it. A dialog will appear with two columns titled Import Value and Change To Value.
- In the sample above the Import Value of 001, 002 etc. from the import file is changed to United States, Afghanistan etc. You may enter as many translations as necessary for each field. Click the Close button to save your changes and return to the Translations tab where you can select additional fields to translate as needed.
- Click the Defaults tab to see a list of Destination Fields (Channergy fields into which you will be importing your data) and definable Default Value fields. The Defaults tab is used to enter the value that will be imported into Channergy when the field in your import file is blank.
- For each Destination Field you can define a Default Value by clicking in the Default Value field next to it and typing. In the example above United States is entered automatically into Channergy when no Country is specified in your import file.
- To save this definition click the button and select Save this definition to a file. You can load the definition the next time you perform an import for this type of file. Click the OK button to complete the definition.
- The Additional Processing tab contains flags for determining how the software splits items into separate orders.
This tab contains two options
- Automatically set “Continued” field using Alternate Order Number 1: Checking this option groups all of the values that are the same in the Alternate Order Number 1 field as a single order.
- Copy order information from main record if record is marked as “Is Continued”: This option is used with the Yahoo MOM import specification. The StandardImport table in the software contains room for ten items in a single record. If there are more than ten items in an order, checking this option will add a new record in the standard import table for the additional items.
- To use the import you created go to the Process Orders help topic.
UNDER THE HOOD: The import orders feature stores the import order specification information in the following tables OrderImportSettings, OrderImportDefaults,OrderImportMap and OrderImportTrans.
When a new import specification is created a new record is added to the OrderImportSettings table. The data from the settings tab is added to the corresponding fields in the table. The primary key for this table, ImportNo is used to link this table to the other OrderImport tables. The additional processing information is also added to this table.
The OrderImportMap table contains the ImportNo value from the OrderImportSettings table and the field mappings between the Channergy StandardImport table fields (stored in the DestinationField field) and the Field numbers of the import file stored in the SorceField field.
The OrderImportDefaults table contains the ImportNo value from the OrderImportSettings table and any default values that are set in the Defaults tab in the Order Import Settings screen.
The OrderImportTrans table contains the ImportNo value from the OrderImportSettings table. The FieldName field contains the StandardImportTable field name that the translation applies to, the ImportValue field contains the values that can be expected from the table imported into the StandardImportTable and the ChangeToValue is what the data will be changed to in the StandardImport table.