Frequently Asked Questions
Arclab® Inbox2DB
ExecuteSQL failed:
- ERROR: ExecuteSQL failed: E: String data, right truncated SQL: INSERT ...
- ERROR: ExecuteSQL failed! E: An INSERT INTO query cannot contain a multi-valued field.
- ERROR: ExecuteSQL failed! E: Datetime field overflow
- ERROR: ExecuteSQL failed! E: Invalid character value for cast specification
Email Accounts:
- IMAP and POP3
- MS Exchange Server (self-hosted)
- warning Gmail
- warning Microsoft 365 (Exchange Online)
F.A.Q. Index:
- How do I enter the "License Key" to unlock the Test Version?
- I want to download the latest version
- My license key is not working with the latest version
- I want to download a previous version
- warning How to connect to a MS Exchange Server
- Does Inbox2DB support XOAUTH2 or "MS Modern Authentication"?
- IMAP settings for a Shared Mailbox (Exchange)
- warning How to define "Column Names" and "Data Types" in MS Excel
- Settings > Folder > Data Folder > Change Folder
- "Error: Cannot open ODBC" when using a target database/sheet inside a Dropbox folder
- How can I exclude the timestamp from "Order: abcd 2016-02-01"
- The program does not start any longer
- Security and SQL Injections
- Target Column Type: Date and Time
- Target Column Type: Numerical Values and Currencies
- Target Column Type: Integer
- warning MS Excel: The program says "x messages processed" but I cannot find the records in Excel
- How to transfer all program settings and the program database to a new computer
- Error Message "No Source Fields defined ... Nothing to do here"
- Error Message "No Account selected"
- Error Message "No Table selected"
- I have selected an "ODBC Connection" as "Connection Target", but no "Tables" will be shown
- How to store large text fields (>255chars) in an Excel sheet?
- warning ERROR: ExecuteSQL failed: E: String data, right truncated SQL: INSERT ...
- How to extract and save the complete message text
- How to restart from scratch
- How can I enter one of the header fields, e.g. the sender email address to my database?
- The program does not save the "Column Relationship" when using an Excel sheet as target.
- warning MS SQL Server: The program does not show any columns after selecting the table.
- Duplicate field names in the source email
- ERROR: ExecuteSQL failed! E: An INSERT INTO query cannot contain a multi-valued field.
- ERROR: ExecuteSQL failed! E: Datetime field overflow
- Can I use MS Access Database Engine 2016 instead of 2010?
- ODBC Driver (32bit) for *.accdb not found!
- warning ERROR: ExecuteSQL failed! E: Invalid character value for cast specification
- How to Compact and Repair the internal database file inbox2db.accdb
- warning Install and Repair ODBC Driver (MS Access Database Engine)
- How can I change the "connect string" of the connection without having to reselect the table and fields?
Related Knowledge Base Articles:
comment How do I enter the "License Key" to unlock the Test Version?
Click on "Settings" and "Enter License Key"
after you purchased a license.
Enter your license key and click on "Validate".
The license key has the format: AIDBXX-XXXXXX-XXXXXX-XXXXXX-XXXXXX
See also:
comment How to define "Column Names" and "Data Types" in MS Excel
Using an MS Excel sheet as "Connection Target" requires two steps:
- Define the "Column Names" (field names) by
typing in the names in the first row.
Samples: Address1, Address2, First_Name, Last_Name, Name, FirstName, LastName
Important: Don't use spaces, commas, ", ', ... in the column name! - Add a sample row (record) and define the field
types by formatting the cell(s), e.g. data type "Date", "Integer", etc.
MS Excel auto detects the correct data type in most cases. Make sure, that you add a complete sample row including all cells.
If you don't add a sample line all data types will be defaulted to 255 chars.
Add more than 255 chars in the sample cell for large text fields.
- Make sure that the column names in the first row
of the Excel Sheet have no extra spaces at the beginning
or at the end.
Such additional characters are often added inadvertently by the user when copying and pasting.
Sample: Change "Name: " to "Name:"
The MS Excel sheet should look like this:
The first row contains the "Column Names", e.g. Name, Email, Date, Total and the second row contains a sample record with the data type definition (use the Excel format cell functions). Format each cell which should not be text, e.g. "07.11.2014" as "Date" and "199" as "Number"
If you don't add a sample row, then all columns will be treated as text with max. 255 chars!
comment Settings > Folder > Data Folder > Change Folder
Important: Changing the data folder using Folder > Data Folder > Change Folder creates a new blank program database. This equals a restart from scratch. The new program database will NOT contain data connections or information about processed messages from the previous data folder. All messages in the inbox will be processed again!
If you want keep the data connections (and information about processed messages) copy the data folder before changing the folder in the program:
- Locate the current data folder
- Exit the program (make sure it's not running in tray-mode!)
- Copy the current data folder to the new location
- Start the program and change the data folder to the new location
- Optional: delete the old data folder if you are sure you don't need it anymore
comment "Error: Cannot open ODBC" when using a target database/sheet inside a Dropbox folder
The ODBC driver cannot update the database or sheet because the Dropbox
client has locked the file during the Dropbox synchronization.
Please
disable/end the Dropbox client when running the program or move the target
database/sheet out of the Dropbox folder.
comment How can I exclude the timestamp from "Order: abcd 2016-02-01"
To extract "abcd" in:
Order: abcd 2016-02-01
use:
- Source Field incl. Separator: Order:[SPACE]
- Source End Marker: [SPACE]
(type in "[SPACE]" - don't use the space button)
See also: Define Source Fields and Values in the Sample Message
comment The program does not start any longer
Please download and re-install the program
(it's not required to uninstall the software).
If you have installed
MS Office 16 (365) also take a look at
this page.
comment Security and SQL Injections
Arclab Inbox2DB adds values from an email into a database, which means that you cannot rely on the input data, e.g. someone could send a manipulated SQL statement. The program uses “bind parameter” to avoid SQL injections, e.g. it uses:
SQLBindParameter to bind each parameter before calling:
INSERT INTO tablename (col1,col2,col3) VALUES (?,?,?);
instead of directly calling:
INSERT INTO tablename (col1,col2,col3) VALUES ('abc', 'abc', 'abc');
This ensures, that no manipulated SQL statement could be used for SQL injections. If you access the database values using a third-party application or script, then you should do the same or filter the values before you run any SQL call containing one of the values.
Read more about SQL Injections: http://en.wikipedia.org/wiki/SQL_injection
comment Target Column Type: Date and Time
The program accepts a date in the formats:
- MM/DD/YYYY
- DD.MM.YYYY
- YYYY-MM-DD
The program accepts a time in the formats:
- HH:mm
- HH:mm:SS
The program accepts a timestamp (a timestamp contains the date and time) in the formats:
- MM/DD/YYYY HH:mm
- MM/DD/YYYY HH:mm:SS
- DD.MM.YYYY HH:mm
- DD.MM.YYYY HH:mm:SS
- YYYY-MM-DD HH:mm
- YYYY-MM-DD HH:mm:SS
There must be a space between date and time!
Y = Year | M = Month | D = Day | H = Hour | m = Minute | S = Second
comment Target Column Type: Numerical Values and Currencies
1,000,000.00 = 1000000.00
1.000.000,00 = 1000000.00
1.00 = 1 (1.00)
1,00 = 1 (1.00)
1,000 = 1 (1.000) (!)
1.000 = 1 (1.000) (!)
Abc123 = 123
1.35 $ = 1.35
1,99 € = 1.99
Abc = 0
comment Target Column Type: Integer
1,000,000.00 = 1000000
1.000.000,00 = 1000000
1.00 = 1
1,00 = 1
1,000 = 1 (!)
1.000 = 1 (!)
Abc123 = 123
1.35 $ = 1 (!)
1,99 € = 1 (!)
Abc = 0
comment MS Excel: The program says "x messages processed" but I cannot find the records in Excel
This happens quite often when people have used the excel sheet before.
Please scroll down and search for the records. There are empty rows before the record.
The program adds the new records after the last "used" row/line in the excel sheet. If you have e.g. deleted the cell contents, but not the whole row in Excel, then you will get empty lines/rows. You can fix this easily by selecting the empty lines, right-click and remove the whole rows (not just the content).
comment How to transfer all program settings and the program database to a new computer
- Install Inbox2DB on the new computer and run it once.
Don't create a new data connection! - Exit the program on the new computer.
- Start the computer on the old machine and locate the "Data-Folder"
in "Settings".
If you cannot start Inbox2DB on the old computer:
The default location of the "Data-Folder" is: C:\Users\Public\Documents\Arclab Inbox2DB\
Please make sure, you have not changed the "Data-Folder" to a custom location:
The "last modified" date of program database file "inbox2db.accdb" should reflect your last use.
If you cannot locate the custom "Data-Folder" location: search for "inbox2db.accdb" on your computer.
- Exit the program on the old computer.
- Now copy/replace the "Data-Folder" on the new computer with the
files from the old computer.
- Run Inbox2DB on your new computer and enter your license key.
comment Error Message "No Source Fields defined ... Nothing to do here"
The program cannot synchronize the connection because you have not defined any source fields.
Please edit the "Connection" and define source fields using "Edit Relationship".
See:
Edit Column Relationship: Define Source Fields and Values in the Sample
Message
comment Error Message "No Account selected"
The program cannot synchronize the connection because you have not specified the source (email) account.
Please edit the "Connection" and select the source account for the connection.
See also: Data Connections - Source
(Email) Account
comment Error Message "No Table selected"
The program cannot synchronize the connection because you have not specified the target database table or sheet.
Please edit the "Connection" and select the data connection target.
See also: Data Connection
Target (Target Database)
comment I have selected an "ODBC Connection" as "Connection Target", but no "Tables" will be shown
Please check the following issues:
- No "Database" was selected in the ODBC connection configuration.
Edit the ODBC/DSN connection (or create a new ODBC DSN) and select a "Database" in the configuration.
See also: How to use a MySQL Database as Connection Target - The database does not contain any tables.
Create a database table. - The specified user has no permissions to access/view the
specified database.
Check the database/table permissions of the database.
comment How to store large text fields (>255chars) in an Excel sheet?"
Insert a sample line (below the field names) to the sheet and add more than 255 chars in the sample cell for large text fields.
See also: How to define "Column Names" and "Data Types" in MS Excel
comment ERROR: ExecuteSQL failed: E: String data, right truncated SQL: INSERT ...
The error "ExecuteSQL failed: E: String data, right truncated..." is shown if the char or text field in the target database is too small and the program cannot insert the (long) string extracted from your email into the (small) target database field.
Solution: Edit the target database
structure and change the field length (or field type) to
the needed size.
When using MS Excel: How to define "Column
Names" and "Data Types" in MS Excel
If you get the error message "right truncation" when inserting a file attachment into the database, click here.
comment How to extract and save the complete message text
First you need to ensure that the target field in your database (field type) is large enough to store the complete message text.
Important: This function stores the extracted message
text (as shown in the preview).
Please take a look at "HTML/Text
Source", if you want to save the complete (unmodified) HTML source code
instead.
Please take a look at "Email
Source and File Attachments", if you want to save the complete EML source
instead.
The program adds FULL-MESSAGE-START at the start of
the message text and FULL-MESSAGE-END at the end.
This
text can be used to select the complete (extracted) message text:
Source Field incl. Separator: FULL-MESSAGE-START
Source Value End Marker: FULL-MESSAGE-END
comment How to restart from scratch
Please follow the steps below if you want to restart using a blank installation.
Warning: This will permanently delete the connection
settings, information about processed messages and all log files!
The
program will re-process all messages in the email account's inbox if you
re-create the same connections!
- Locate the "Data Folder" in "Settings > Folder >
Data Folder"
The default location is: C:\Users\Public\Documents\Arclab Inbox2DB\
(If you want to use the same data connections later, use the "Export" function to export the connection settings) - Make sure you have a copy of your license key!
Click on "Settings > Enter License Key" to view/copy the license
key.
You need to unlock the software again after the restart.
- Exit the program completely. Make sure it's not running in the system
tray!
- Delete the complete "Data Folder", e.g. delete:
C:\Users\Public\Documents\Arclab Inbox2DB
If you cannot delete the folder, the program is still running. - Restart the program.
(import the connections and check the connection settings)
comment How can I enter one of the header fields, e.g. the sender email address to my database?
You can use all the header fields shown in the preview, e.g. use:
Source Field incl. Separator: Header-From-Address:
to select the sender "From Address" (email address).
To select e.g. the message "Subject" use:
Source Field incl. Separator: Header-Subject:
See also: Source Fields
comment IMAP settings for a Shared Mailbox (Exchange)
The following instructions only refer to a "Shared
Mailbox". This is not necessary with a normal mailbox.
See also:
How to connect to a MS Exchange Server
Exchange Configuration:
- User Email: user@yourdomain.tld
- Shared Mailbox: shared@yourdomain.tld (or other domain)
- Shared Mailbox Alias (Name): shared-mailbox-alias
Important: Create the unique "Shared Mailbox Alias" with the mailbox!
IMAP Settings:
- Server Type: IMAP - SSL Encrypted
- Port: 993
- Email Address: shared@yourdomain.tld
- IMAP Server: host name of your IMAP/Exchange server
- User Name: user@yourdomain.tld\shared-mailbox-alias (Syntax: user\shared-mailbox)
- Password: user's password
comment The program does not save the "Column Relationship" when using an Excel sheet as target.
Please check the column names in the first line of the Excel sheet and
remove extra spaces before and after the column names.
Such additional
characters are often added inadvertently by the user when copying and pasting.
Samples:
"Name: " > change to "Name:"
" Name:" >
change to "Name:"
comment MS SQL Server: The program does not show the columns after selecting the table.
This issue is related to the used database schema.
Solution: Create the database in the default (dbo) schema.
Info: The schema is set at the database user level. It cannot be set in the program or connection string.
If you can not use the default schema "dbo" or do not want to use it:
- Edit the database user and change the default database schema from "dbo" to the new schema.
- Alternative: If you do not want to change the user's default database schema, create a new user and set the default scheme for the new DB user accordingly. Now create a new ODBC connection and explicitly select the newly created database user.
comment ERROR: ExecuteSQL failed! E: An INSERT INTO query cannot contain a multi-valued field.
This error message often occurs in connection with MS Access when the
field type "Attachment" is used.
The MS Access field type "Attachment"
is a special field type that cannot be filled externally with binary data.
If you want to insert a file attachment from the email to an MS Access
database, please select the "OLE Object" field type in MS Access.
To
do this, switch to the design view in MS Access and use
the field type "OLE Object" instead of "Attachment".
Please check all relevant field in the source (MS Access) database table.
Please note that you have to delete the field and then add it again! If the table already contains data, you should first save it or create a new table, because when a field is deleted, all data in it is deleted !!
comment ERROR: ExecuteSQL failed! E: Datetime field overflow
One of your date/time fields contains an invalid value, e.g. MM/DD/YY
instead of MM/DD/YYYY.
Use 4 digits for the year!
Don't specify fractional
seconds for a time field!
The program accepts:
- MM/DD/YYYY, DD.MM.YYYY and YYYY-MM-DD as date
- HH:mm and HH:mm:SS as time
- MM/DD/YYYY HH:mm, MM/DD/YYYY HH:mm:SS, DD.MM.YYYY HH:mm, DD.MM.YYYY HH:mm:SS, YYYY-MM-DD HH:mm and YYYY-MM-DD HH:mm:SS as datetime
comment Can I use MS Access Database Engine 2016 instead of 2010?
Inbox2DB should work with any ODBC driver.
If you have installed the
32bit version of MS Office (365) then it's not required to install any additional
driver.
You can install the 2016 version as follows:
- Uninstall Microsoft Access Database Engine 2010 (32bit)
- Download Microsoft Access Database Engine 2016 (32bit) - don't download the x64 version!
- Run AccessDatabaseEngine.exe
- If you cannot install because there is a 64bit component blocking,
open a command prompt and run the installation using:
AccessDatabaseEngine.exe /quiet - See also: Install ODBC driver
comment ERROR: ExecuteSQL failed! E: Invalid character value for cast specification
ERROR: ExecuteSQL failed! E: Invalid character value
for cast specification (English)
ERROR: ExecuteSQL failed! E: Ungültiger
Zeichenwert für Konvertierungsangabe (German)
This problem can occur after an MS Office (365) update of the
ODBC driver.
When inserting the time into a "Time", "Date/Time"
or "Timestamp" field in the database, the error is displayed, although the
time was transferred correctly.
If you only insert the date in a "Date/Time"
or "Timestamp" field in the database, the error does NOT occur.
According
to our tests, this happens with all time fields (or fields which contain
the time), date only fields are working.
We hope that MS will fix this
issue soon.
error_outline If you want to use a different version of the ODBC driver:
The problem does not occur if you are using the 2010/2016 ODBC driver.
- The simplest solution is to reinstall the program
and select the option to install the ODBC driver "Microsoft
Access Database Engine" in the setup.
This will install and repair the Microsoft Access Database Engine 2010 automatically. It is not necessary to uninstall the program before.
- To prevent the ODBC driver from being changed during a new update,
you can use the option:
"MS Access Database Engine (32bit): Enforce Version" in the section "Settings" after you have installed the program.
Alternatively, you can also install the corresponding ODBC driver manually. See also: Install ODBC driver
error_outline If you want to continue to use the current version of the ODBC driver:
As a workaround you can e.g.
- Assign the date only (intead of data and time) in the "Field Relationship"
- or change the target field type to "Text" (string) in your database table definition
You can also split up a "Date/Time" or "Timestamp" field into two fields
(one field for date and one for time).
In this case you can use the target
field type "Date", "Date/Time" or "Timestamp" for date and "Text" (string)
for the time.
comment How to Compact and Repair the internal database file inbox2db.accdb
If the internal program database (inbox2db.accdb) is defective or has
become too large, you can try to repair it using MS Access.
The inbox2db.accdb
file can be found in the data folder (see "Settings > Folder > Data
Folder").
We recommend making a backup beforehand in
order to avoid any data loss in the event of an error.
- Make sure the program is closed and not running in the system tray.
- Start MS Access
- Open the database file inbox2db.accdb
- Select "Database Tools > Compact and Repair Database"
- Save the database file
- Exit MS Access
- Start Inbox2DB
comment Does Inbox2DB support XOAUTH2 or "MS Modern Authentication"?
- No, authentication is only possible via user name and password (SSL/TLS).
- Web-based authentication, XOAUTH2 or "MS Modern Authentication" cannot be used because the program does not have a web service or backend.
- Some providers allow you to create a special app password
that allows access via IMAP without using XOAUTH2.
In this case, use the app password you created instead of your normal password.
See also:
Alternatives:
If access via user/password (SSL/TLS) is not possible, you can use another email account, e.g. from your web space provider, which allows normal IMAP access via user/password. In this case, you must then redirect or send the messages to be processed to this alternative email account.
comment Install and Repair ODBC Driver (MS Access Database Engine)
It is possible that the ODBC driver has become corrupted or there is
a problem after a system update.
In this case, please restart
the computer and reinstall the software (without
uninstalling).
Check the "Install and repair MS Access Database
Engine" option in the setup program, if this option is available.
See also: Install ODBC driver
comment How can I change the "connect string" of the connection without having to reselect the table and fields?
(Version 6.3++)
- Edit the connection
- Click on "Data Connection Target" > "Target Connect String" > "Select Target"
- Check "Edit Connect String"
- Check "Preserve existing Table and Field Mappings" to change the target database or the ODBC connect string without remapping the table or fields
- Change the connect string and hit "Ok"
See also: Data Connection Target