Navigator > Setup > Data Interchange > Import Designer > Definition tab
Use the Import Designer to create import routines to import data from files into Accredo. The Definition tab contains the import file details and the MaxBasic code to execute to complete the import. The code on the Definition tab should call:
ProcessLineType(X) - run the code in the Line Type X tab, for all line types. You can add as many line types as are required. ProcessSave - run the code in the Process Save tab.EDI Import definitions require knowledge of MaxBasic scripting and Accredo Automation objects. Designing import definitions and ensuring correct validation of imported data is a specialised task. Contact your Accredo QSP if you require assistance.
Sample import definition files for most masterfiles are provided in the \Imports\EDIImports\SampleImports directory. Corresponding export script files for all import files are also provided in the \Scripts\EDIExports\SampleExports directory. We recommend starting with a sample import definition and modifying it to meet your requirements.
See also the Import Invoices Example.
Input Format |
Select the import file type. Note: If your file contains embedded line-feed characters within fields, as can occur in CSV files saved from MS Excel, you should select User Delimited with the default delimiter
|
|||||||||||||||
Unquoted |
Unquoted checkbox is enabled when any of the CSV Input formats is selected. Unselected, the default. Quotes around field values are treated as metadata. Selected, quotes are treated as data only not metadata - select to handle CSV files where no values are quoted and data values include quote marks. |
|||||||||||||||
Default Input File |
The path and filename of the EDI import data file. When you use EDI Importing, this file name will be set by default. To have the user select the file name and path, clear this field before you Save. May be specified as just a default path ending with \ which will set the default folder for browsing to select the Input file. |
|||||||||||||||
|
Add Line Type Delete Line Type |
Insert a new line type tab or delete the last line type tab. Include one line type for each type of data line in the import file. |
||||||||||||||
First Line Contains Header checkbox |
Selected, the input file contains one or more Header lines. |
|||||||||||||||
Perform Import |
Code to execute the import. You can use Accredo automation. |
|||||||||||||||
Objects: |
||||||||||||||||
Company |
Contains details of the Company name and address. |
|||||||||||||||
ImportFile |
Properties and methods for the input file to be imported. |
|||||||||||||||
System |
Fields from the System record. |
|||||||||||||||
SystemUser |
Fields from the System User record. |
|||||||||||||||
User |
Fields from the User record. |
|||||||||||||||
Note: See Import Functions for functions specific to the Import Designer. |
||||||||||||||||
Buttons |
||||||||||||||||
|
Check Code |
Check that the code entered compiles correctly. |
||||||||||||||
|
Breakpoint |
Set a code breakpoint on the current line. Click again to toggle to clear the breakpoint. You can also click to the right of a line to set or clear a breakpoint. Hover the mouse over a breakpoint, then right-click to make a breakpoint unavailable, or access the Breakpoint Properties. If a condition has been set for a breakpoint, it will be shown when you hover over the breakpoint. |
||||||||||||||
|
Run |
Run the import from the Design Window using the file selected from Default Input file. You can run the import against test data. Imported records are not removed from the import file. |
||||||||||||||
View Data... |
Formatted data from the input file displays in a grid. You can check the format validity against the data. |
|||||||||||||||
|
Print |
Print the code from the different tabs. |
||||||||||||||
|
Load... |
Load an Import Definition file. |
||||||||||||||
|
Save... |
Save the Import Definition file. |
||||||||||||||