tab-delimited

What is the best mime-type and extension to use when exporting tab delimited?

I've come across the problem where Excel will not play nice with UTF-8 encoded CSV files. See this related question on Stack Overflow. I've followed the solution of exporting as UTF-16, however it seems that with UTF-16, the comma character doesn't work as a delimiter, only the tab character. However I can't find anywhere what the corr...

Vb6: Separating Tab Delimited Text

I have a file with several thousand rows and several columns separated with tabs What I'd like to do is loop through each individually, Drop the columns into an array so that I can place them in another application individually, then move onto the next line. Unfortunately I got about as far as this: Open mytextfile.txt For Input As #Fi...

Is there such a thing as TapeMACS data file formatting?

I'm trying to do an estimate for a data integration, and the client sent across some files for their current system that appear to be in TapeMACS format? It is not a comma-separated or tab-delimited format, and there appears to be a layout that maps to the file with "Field Name", "Description", "Format" and "Position" specified. Is this ...

How to parse a tab-separated line of text in Ruby?

I find Ruby's each function a bit confusing. If I have a line of text, an each loop will give me every space-delimited word rather than each individual character. So what's the best way of retrieving sections of the string which are delimited by a tab character. At the moment I have: line.split.each do |word| ... end but that is not ...

How do I know if a file is tab or space delimited in Perl?

I am uploading a file to a Perl program from from an HTML page. After the file has been uploaded I want to determine whether the file is either space or tab delimited and all the values are integers. If this is not the case then I want to output some message. I was thinking of reading every character of the file and checking if it's...

Unix Sort with Tab Delimiter

I have a data with the following format: foo<tab>1.00<space>1.33<space>2.00<tab>3 Now I tried to sort the file based on the last field decreasingly. I tried the following commands but it wasn't sorted as we expected. $ sort -k3nr file.txt # apparently this sort by space as delimiter $ sort -t"\t" -k3nr file.txt sort: multi-charac...

Best way of reading & processing a text file...

Hello all, Was wondering if anyone had any favourite methods/ useful libraries for processing a tab-delimited text file? This file is going to have on average 30,000 - 50,000 rows in it. Just need to read through each row and throw it into a database. However, i'd need to temporarily store all the data, the reason being that if the tabl...

String parsing in Java with delimeter tab "\t" using split

I have to parse a line which is tab delimited. I parse it using the split function, and it works in most situations. The problem occurs when some field is missing, so instead of getting null in that field I get next value. I was store parsed values in a string array. String[] columnDetail = new String[11]; columnDetail = column.split("\...

How do I correctly handle CR when reading text files with OleDB

I have text files that are Tab delimited. I created a Schema.ini like so: [MY_FILE.TAB] Format=TabDelimited ColNameHeader=False Col1=id Short Col2=data Text This is the code I use to read it (C#): using (var connection = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\FolderToData\;Extended Properties='text;FMT=...

Python - Nested List to Tab Delimited File?

Hi, I have a nested list comprising ~30,000 sub-lists, each with three entries, e.g., nested_list = [['x', 'y', 'z'], ['a', 'b', 'c']]. I wish to create a function in order to output this data construct into a tab delimited format, e.g., x y z a b c Any help greatly appreciated! Thanks in advance, Seafoid. ...

.NET & Tab-Delimited files.

How can I create and append to a tab-delimited file in C#? ...

Looking for a good text parsing library for C#

Has anyone run across a quality library that will parse, line by line, CSV, tab-delimited, and Excel files? I've started to do it manually but have noticed some of the intricacies in parsing a comma-delimited file. Such as situations where a cell has a comma in it as part of the data (blah,\"LastName, Jr.\",blah,blah). ...