Writing Data

Overview

ODBClink allows you to write data into your accounting package.

Note that this feature is only available in ODBClink Pro Edition.

ODBClink provides a two-stage import process. First, you need to insert records into specialised import tables. Secondly, you can click the Write Data button from the command centre or use the WriteData macro to import all data back into your accounting package. Additional fields are included in the import tables to provide feedback information.

Configuring ODBClink to write data

Specialised import tables have been designed in ODBClink to allow you to import data back into your accounting package. These tables are "prefixed" with specialised names (e.g. MYOXIMPORT_ for MYOB AccountRight Live). For a complete list of the import tables, see Import Tables.

To configure ODBClink to write data, you will need to Edit your data warehouse and include the appropriate import tables.

Adding records to the write data table

Once the import tables have been included, you will need to insert records into the import table. The fields of the import table are broken into three groups:

  • Fields used to control the import process;
  • Fields used to return result information;
  • Fields used to provide data.

Fields used to control the import process

Each import table include three fields used to control the import process.

  • CompanyRecordID is an optional field which allows you to control into which data file the record will be recorded. This fields is only required in a multi-data file environment. It can be left blank in a single-data file environment.
  • InternalID is an optional field which allows you to control how the transaction are group. For instance, if multiple lines of an invoice relate to each other. It also allows you to provide a key to your own data so you can integrate your system's identifier with that of your accounting package. If left blank, the system will group lines based on a specific rules documented in the relevant import table.
  • InternalLineIndex is an optional field which allows you to control the order of the lines within a transaction.

Fields used to return result information

Each import table include specialised fields to provide result information. These fields do depend on the accounting package you are integrating with.

These fields should be left blank.

ODBClink will update these fields with information when writing data back to your accounting package.

  • RecordedUID is used for MYOB AccountRight Live and provides the UID of the transaction or data recorded. For endpoints that do not have a UID, the field will either contain the words Imported or Not Imported.
  • RecordedRowVersion is used for MYOB AccountRight Live and provides the RowVersion of the transaction or data recorded. For endpoints that do not have a RowVersion, the field will either contain the words Imported or Not Imported.
  • RecordedDate is used for MYOB AccountRight Live and provides the date when the transaction was recorded. If the import process failed, it will be set to NULL. This fields is also used a control field. ODBClink will only attempt to import records which have a RecordedDate of NULL.
  • RecordedResult is a text field used for MYOB AccountRight Live and provides the descriptive result returned by the import process. If the import was successful, it will set to Success. Any other value is an error and provides the description of the error.

Fields used as data

All other fields in an import table are used as data field.

Writing Data

ODBClink provides multiple means to write data back into your accounting package.

The command centre includes a Write Data button. Using this button, ODBClink will iterate through each data warehouse, data file and import table and record the data available.

A WriteData macro can also be used and called which behaves exactly as the command centre Write Data button.

Lastly, the Write Data macro accepts 3 parameters being an import table name, a data warehouse name and a data file name. All three parameters can be used independently and allows you to control/refine how the data gets written into MYOB.

Related Topics