Wednesday, August 18, 2010

How can I pull data from a csv file and input it into an excel spread sheet form?

I get a dump file in csv form and have to input some of the data into an excel spreadsheet. Not all of the data is used from the CSV. There must be a faster way to assign rows and columns and have that data pulled out of the csv, than copy and paste.


Any help would be appreciated.How can I pull data from a csv file and input it into an excel spread sheet form?
Make sure that you can easily find your CSV file on your hard drive or network drive. Open Microsoft Excel and open a blank spreadsheet.





Click on Data in the Menu Bar and click on Import External Data. Select Import Data. Find your CSV file and click on it.





Leave the first Step on the Original data type Delimited, since Fixed width requires every piece of data to be saved using the same number of characters. Click on Next.





On Step 2, change the Delimiters option from Tab to Comma. Your data will show in the Data preview window and will reflect the Delimiter method you choose. Since a CSV file is a Comma Separated Value file, the delimiter is the comma. Click on Next.





Step 3 focuses on the Data preview box. Each column can be highlighted and the Column data format can be selected. If you have dates in your data you need to select the column and change the Column data format to Date. You can then select the date format in the dropdown box.





This is an important step if you are using numbers that might have zeros at the beginning. Make sure you change any column containing numbers that start with zeros to the Column data format of Text. This is necessary when importing zip codes. After all of your columns are in the correct format, click Finish.





The Import Data dialog box will appear on the screen. You can either select the cell in the current worksheet that you want to be the starting cell for the imported data or click on New worksheet and the data will appear in a blank worksheet. Click Ok and the data will appear in the location you chose.

No comments:

Post a Comment