This article was designed to help explain and resolve the dreaded 1,000 error.
What does it mean?
There is nothing in the error that is obvious, just a number. There is also nothing in the log that is obvious. If you look in the idashboards log you might see something like this.
com.microsoft.sqlserver.jdbc.SQLServerException: String or binary data would be truncated.
The only way to figure out the problem is to look at your data. The error indicates That one or more rows of data exceeds the pre-set column length.
What we see most often in support is Excel data was imported with long descriptive headers, questions, or long descriptions in the data. However long fields could exist in other data you're connected to as well. So there is no go-to table to fix the problem.
Fixing the problem
There are a couple of ways to go about fixing the problem.
- If the data is coming from Excel you can manually edit the data in the file prior to uploading by abbreviating and or truncating long headers or data fields, or if the data can be edited via some interface.
- If this is not an option then you'll need to track down the table with the column that is too small to contain the data and increase the column length. Once it's found you can run a simple script to increase the length. Similar to the script below. If it's a string then the data type could be varchar or nvarchar so adjust accordingly.
alter table TableName alter column ColumnName varchar(150);
- Note: It's always recommended you create a backup of the database you're modifying prior to making any changes.
- Just set the number in parentheses to something reasonable that you think will accommodate the column length. Also keep in mind if these might end up and X or Y axis labels, you might run the risk of cut-off or overlap.
- If these error is presenting itself in an ETL job. The Load task has a checkbox "Truncate Long String to Fit" that will do the work of shortening the string for you, but it probably won't look very elegant.
- Finally also consider if you even need this column in your data in the first place. Most of the charts are graphical. So unless you're using something like a details or tabular chart, you may not need it at all. In which case you can remove it in the chart designer or when you're creating your data set in the datahub.