Deciding data type while importing data from CSV files in to Access

raghavcacs

Board Regular
Joined
Mar 13, 2009
Messages
84
Hi,

I have several CSV files i have to import in to Access and consolidate them in to Access. Few coloumns has numbers which are more than 16 digits. I want them to be uploaded in to access as text. Is there any way we can do this with the help of VBA?
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Is the question how to get those fields in Text instead of Numeric format? If go, VBA is not necessary. There are a few ways:

1. One way is to create a blank "shell" of table, where you have pre-defined all the field names and data types (where you can specify your data types). Then import that CSV file into that table shell.
2. The other way is to use the Import Wizard. and set the field-type to be Text in that. Right before you click "Finish", you can even save the Import Specification name, so you can re-use it with the other imports and not to have go through that whole process every time.
 
Upvote 0

Forum statistics

Threads
1,213,504
Messages
6,114,020
Members
448,543
Latest member
MartinLarkin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top