Menu

Fixed: Quick Import issue

0 votes

When importing a CSV with only 140 lines I get the error message:

Import Failed while Saving Data, Row #1, String or binary data would be truncated.
The statement has been terminated.

Confused as to what the problem is. The Data Type hasn't changed.

in Version 1.0 or older by (350 points)
recategorized by

1 Answer

0 votes
 
Best answer

The message "String or binary data would be truncated" is a database server message that simply means that the data you are importing is too large for one of the table fields. dbFront also let you know that this happened on the very first row of your CVS file.

The two possibilities are that the data is just simply too long, or that the data is being imported into the wrong field.

Since this is a database error, dbFront will have logged the entire SQL and error message in the Logfile for you to examine and debug. The Logfile can most easily be accessed by opening [Help] \ [Log Viewer] and searching for your error message in the bottom log.

NOTE: A related bug was fixed in dbFront version 1.0.14.2801.

by (65.1k points)
selected by
This makes sense, except the fields aren't too small for the data being entered.  In addition to this I'm now seeing this when attempting to create a new record right in the interface.  In this new record I only put in data to one field which is the Primary Key leaving the rest blank.  In SQL this field is set to nvarchar(255) and the string being entered isn't anywhere near that long.  I'm stumped...
You just ran into a bug that I fixed in 1.0.14.2561.  Your option is to upgrade to the beta release or change the column type to an INT, BIGINT or similar type with a inherent size.  Assuming of course that you are storing a number....
I upgraded to the beta and this solved the problem with the manual entry and the issue I was experiencing with the import.  Thanks for your assistance.
Welcome to the dbFront Q&A site, where you can ask questions and receive answers from other members of the community.
 | Minimalist Answer Theme by Digitizor Media
 |
Powered by Question2Answer
...