Click here to Skip to main content
13,554,611 members
Rate this:
Please Sign up or sign in to vote.
I want to import data from access database to sql server 2008 using c#.
With some validation means,
In Access we have varchar(10) and sql we have varchar(11) then not allow to import data. like vise if name is not match of the column than also not allow to import.

Posted 30-Dec-12 22:01pm
Updated 30-Dec-12 22:04pm
Gordon-Beeming-Za 31-Dec-12 4:48am
You'd need to do a scheam compare and then setup the data sync only for tables/colums that match.
Rate this: bad
Please Sign up or sign in to vote.

Solution 1


Using SQL Server DTS you can do the above.

Execute SQL Server 2005 Integration Services package from C#[^]
Rate this: bad
Please Sign up or sign in to vote.

Solution 2

There is a tool provided by Microsoft for the same.
below are instructions i put-up for someone else.

1. Download link for the tool -[^]

2. Download the license key to enable the tool.[^]

3. Launch the downloaded tool and specify the location of the license key downloaded in step 2

4. follow the wizard to transfer the objects from Access to SQL Server#

I tried with a small MDB at my end and it was straight forward.
Hope this helps.


This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web01 | 2.8.180515.1 | Last Updated 31 Dec 2012
Copyright © CodeProject, 1999-2018
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100