Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# SQL Access Application Server , +
Hello
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.
 

 
Thanks
Posted 30-Dec-12 23:01pm
Edited 30-Dec-12 23:04pm
v2
Comments
B1n4ry D1g1t at 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
good
Please Sign up or sign in to vote.

Solution 1

Hi,
 
Using SQL Server DTS you can do the above.
 
Execute SQL Server 2005 Integration Services package from C#[^]
  Permalink  
Rate this: bad
good
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 -
http://www.microsoft.com/en-us/download/details.aspx?id=28763[^]

 
2. Download the license key to enable the tool.
http://www.microsoft.com/download/en/details.aspx?id=18589[^]
 
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.
 

Cheers
  Permalink  

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

  Print Answers RSS
0 OriginalGriff 505
1 Maciej Los 309
2 BillWoodruff 174
3 /\jmot 160
4 Suraj Sahoo | Coding Passion 160
0 OriginalGriff 8,484
1 Sergey Alexandrovich Kryukov 7,407
2 DamithSL 5,639
3 Maciej Los 5,159
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web02 | 2.8.1411023.1 | Last Updated 31 Dec 2012
Copyright © CodeProject, 1999-2014
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