| # Import using the Data Access Layer (DAL) The import module allows you to import through the Data Access Layer (DAL). This means all logic specified in the DAL can be applied when importing data, without any programming. This will reduce the costs of interface development, because for those constraint checks, integrity checks and side effects (e.g. updates on other tables) programmed in the DAL, no condition scripts have to be written. The user can use DAL by simply selecting one or more check boxes for an Exchange table relation (import). When the DAL is used for a table relation when importing data for a table, then the functions dal.new, dal.update and dal.destroy are used as an alternative for the db.insert, db.update and db.delete. This means that all functionality included in these DAL functions is executed when importing data. Depending on the settings in the Table Relations (Import) (daxch0121s000) session, the DAL property checks and DAL 2 field dependencies will or will not be executed. Using DAL for certain tables can be combined with not using DAL for other tables, so an import batch can contain both types of table relations simultaneously. The import through DAL works for both the import based on audit or indicators (inserts, updates, deletes) and the full import (inserts only). Note The settings regarding DAL (that is, whether DAL must be used and whether DAL property checks and DAL 2 field dependencies must be executed) are runtime aspects. This means they can be changed without having to regenerate the import program. For that reason they are also logged in the log table at batch line level, to be able to check the settings regarding DAL as they were at the moment the import was run. Error reporting When importing using the DAL, errors are reported as usual. Additionally, hook errors returned by the DAL will also be logged. A DAL can set multiple error messages, but only the first error is logged. If DAL error occurs then both the error message code and the description are logged, in the same way as the database error and description are logged in case of a database error. Related topics Infor LN Exchange - User Guide (U8405 US) DAL 1 Overview DAL 2 Overview |