Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Excel and Tab Delimited Files Question

I am encountering what I believe to be a strange issue with Excel (in this case, Excel 2007, but maybe also Excel 2003, but don't have access to it as I write this).

I can reliably convert some server data over into a tab-delimited format (been doing this for years) and then open it using Excel - no issue.

However, what seems to be happening is if I have an html <table> inside one of the fields, it looks like Excel 2007 thinks it should be converting the table into rows and columns inside Excel (not what I want). As you might imagine, this throws off the entire spreadsheet.

So question is, is there any way to set up excel to NOT do this (perhaps some setting in Excel that pertains to reading tab delimited files), or am I missing something?

Thanks.

like image 266
OneNerd Avatar asked Apr 16 '10 14:04

OneNerd


People also ask

What is a tab-delimited file in Excel?

A tab-delimited file contains rows of data. Each row of data contains one or more pieces of data. Each piece of data is called a field. Tab-delimited files to be read by the Data Integrator must contain the same number of fields in every row, although not every field necessarily needs a value.

What type of file is tab-delimited text?

A CSV (Comma Separated Values) or Tab-delimited Text (or Tab Separated Values) file is a text file in which one can identify rows and columns. Rows are represented by the lines in the file and the columns are created by separating the values on each line by a specific character, like a comma or a tab.

How do I import a tab-delimited file into Excel?

You can import data from a text file into an existing worksheet. Click the cell where you want to put the data from the text file. On the Data tab, in the Get External Data group, click From Text. In the Import Data dialog box, locate and double-click the text file that you want to import, and click Import.


2 Answers

Save your file as .txt

Now open the file in excel using Drag and Drop (rather than double clicking your hookey .xls)

Slightly more work to open the file, but your tab text formatting will now be respected.

like image 177
blissapp Avatar answered Oct 17 '22 05:10

blissapp


When you open the tab-delimited file, you are shown an import mapping dialog that lets you pick each columns' data type (date, text, currency, etc.). For the columns that have HTML data present, choose text. This will tell it basically to import as-is and not try to automatically parse the data into a derived format.

like image 33
JYelton Avatar answered Oct 17 '22 04:10

JYelton