Knowledgebase: Tutorials
[QODBC-ALL] Troubleshooting - Getting Error "Index was outside the bounds of the array." When using Import/Export tool in SQL Server
Posted by Jack - QODBC Support on 11 April 2016 11:55 AM

Troubleshooting - Getting Error "Index was outside the array bounds." When using the Import/Export tool in SQL Server

Problem Description 1:

I recently installed QODBC to get data out of a QuickBooks company file, but I get this error: "Index was outside the bounds of the array."

Problem Description 2:

We are attempting to import tables into SQL Server, which we use as a staging environment. We are not doing any transformations, simply trying to copy the data from QuickBooks into SQL Server using the Import Wizard. Below is the screenshot of the error we receive when attempting to do so. Details of the configuration are provided below.

Source data (QuickBooks): Microsoft .Net provider for ODBC - QODBC 32-bit configured DSN with default settings. Destination Data ( SQL Server): Microsoft OLEDB provider for SQL Server

We are attempting to import four tables for now.

- Account, Class, Entity, Transactions

The reported error below occurs for each table.

Error: Can not load the column attributes from the schema for the current provider descriptor.
- COLUMN_NAME
- TYPE_NAME
- COLUMN_SIZE
- DECIMAL_DIGITS
- COLUMN_SIZE

Solution:

Please follow the below steps to resolve this error:

1. Go to Import Export Wizard by Right click on your SQL Server database, Clicking on Task & Click on Import Data.



2. Choose ODBC Data Source & Enter DSN & Connection String, and click "Next."



3. Choose Destination and click on "Next."



4. Choose the second option (Write a query to specify the data to transfer) and click "Next."



5. Write the query and click on "Next." You can change the table name & question as per your requirement.
For Example:
Select * from the Account



6. Change the destination table name to your requirement and click "Edit Mapping."



7. You must verify the date type of all columns from the "Type" column.



You need to make sure that you are not getting 23 in Type. You will get 23 date-type data type columns.



You need to replace 23 to date for all columns whose Type is 23 and click on "OK."



8. Click on "next" until the finish.





Save and Run Package.



Complete the Wizard.





9. You can see table data imported to SQL Server's local database table.


Keywords: How to use DTS to Import QuickBooks Data into MS SQL Server

 

(2 vote(s))
Helpful
Not helpful

Comments (2)
Juscelino Alves de Carvalho
19 December 2018 03:03 PM
I need to apply it to 2 thousand tables! How can a do it for all!? ??
Rajendra Dewani
18 April 2019 03:15 PM
@Juscelino, Please try importing the QODBC/QuickBooks tables using SQL Server linked tables.
Please refer to http://qodbc.com/links/2814
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please complete the captcha below (we use this to prevent automated submissions).