Import
Overview
This page explains the general process, common to all imports.
For a particular data, you should read the specific page :
Example
Parameters name
If you have already saved a set of parameters, or if one is provided for you with the import, you can choose it here and all the parameters will be read from this file.
There are some parameter files to download on this site. Each one contains the right parameters for a software. If you have files to import, or if you have downloaded examples, download the parameters in the same folder.
If you can provide other working parameter files, you are welcome !
Import type
You can import data from 3 sources :
- separated : file with separated values
- fixed : file with fixed size columns
- sql query : database server
File
If you choose separated or fixed import type, you must provide a separated flat file or a fixed column size file.
Otherwise skip this paragraph and read Database connection.
Most accounting softwares can produce such files. Several features, explained below, should allow you to directly import in gestinux the data of various ERP or accounting softwares, without processing them first in a speadsheet or other software.
Filename
You must select on your system or network a file you have created by exporting from another software. Examples are available here
Field names on first line
If your import file starts with a line containg field names, not to be imported, check the box. You will see the name of these fields in the header.
Field separator
You can define the appropriate field separator and will see if it is the right one before importing.
Database connection
Supported DBMS are MySql, PostgreSQL, MS-Sql-Server, Oracle, Sybase, Interbase, Firebird, SqlLite, or others through ODBC.
For MySql you have already the drivers installed for gestinux. For other DBMS you may have to install the appropriate driver. On Windows this is generally a .dll file to put somewhere. On Linux Ubuntu, you only need to use the Software center (or Synaptics, or apt-get) to find and install a package. Use the forum if you need help.
You must provide a databasename, an username and a password to connect to the database. And the Sql Query to read the data from it.
You can download a Parameter files (.ini) from this site, to have the right sql query. There is a working example for importing from OpenERP.
Lines
Pour simple data (journals, accounts), each line of the file produces one data object. For more complex data, like accounting records, read the specific explanations.
Columns
The name of the fields expected by gestinux are displayed on the first row of the grid. An additional fake column means "not imported"
On the second line you see the field names or numbers from the file to be imported.
You can drag the cells of the first line, to match the order of your exported file. If there is no data for a column expected by gestinux, you can move the field to the right. A default value will be imported (see field description). If there is a column in the input file not used in the import, drag the "not imported" column in regard.
Fields or columns expected by par gestinux are detailed in the specific help pages.
In fixed column size import type, click on the imported column to define the number of characters of this column.
Formats
Date formats
Gestinux always display and decode dates according the system date format, defined at the computer level.
However, you can define the date format for a date field(s) existing in the import and a conversion will be done. Letter DD is for days digit, MM for months, YY or YYYY for years.
Example : MM-DD-YYYY for dates like 12-15-2010, DD/MM/YY for dates like 15/12/10
It is possible to omit the separator : DDMMYY will convert a date given as 151210.
Numeric Format
Gestinux always display and decode currency amounts according the system numeric format.
However, you can define a different decimal format for amounts fields of the import file, and a conversion will be done. If there is a decimal separator, gestinux will expect decimal values and retain the number of digits specified by the currency format. If there is no decimal separator in the format, the value expected is an integer value, and will be divided by 100 if there is 2 decimal digits in the currency format.
Exemples :
Import Decimal format Imported Value Stored in database System currency format Resultant value 9999,99 123,4 12340 999999.99 123,40 9999 12340 12340 999999.99 123,40 9999,99 123,4 12340 999999.999 12,340
Logical values
For fields or columns that must be equal to true or false, you can specify the character string to be interpreted as true. Others values will be interpreted as false.
Here are common examples for values to be interpreted as true : 1 T True
Character set
The gestinux database character set is UTF-8 but many softwares export with other charsets.
When the file to import is in another character set, accentuated characters in non english languages are not displayed correctly.
If you choose the right character set, your input file will be converted, and displayed correctly.
In version 0.5, only ISO-8859 is available. In version 1.0 much more character sets are available.